doobie.free

clob

object clob

Algebra and free monad for primitive operations over a java.sql.Clob. This is a low-level API that exposes lifecycle-managed JDBC objects directly and is intended mainly for library developers. End users will prefer a safer, higher-level API such as that provided in the doobie.hi package.

ClobIO is a free monad that must be run via an interpreter, most commonly via natural transformation of its underlying algebra ClobOp to another monad via Free#foldMap.

The library provides a natural transformation to Kleisli[M, Clob, A] for any exception-trapping (Catchable) and effect-capturing (Capture) monad M. Such evidence is provided for Task, IO, and stdlib Future; and transK[M] is provided as syntax.

// An action to run
val a: ClobIO[Foo] = ...

// A JDBC object
val s: Clob = ...

// Unfolding into a Task
val ta: Task[A] = a.transK[Task].run(s)
Source
clob.scala
Linear Supertypes
AnyRef, Any
Ordering
  1. Grouped
  2. Alphabetic
  3. By inheritance
Inherited
  1. clob
  2. AnyRef
  3. Any
  1. Hide All
  2. Show all
Learn more about member selection
Visibility
  1. Public
  2. All

Type Members

  1. type ClobIO[A] = Free[ClobOp, A]

    Free monad over a free functor of ClobOp; abstractly, a computation that consumes a java.sql.Clob and produces a value of type A.

  2. implicit class ClobIOOps[A] extends AnyRef

    Syntax for ClobIO.

  3. sealed trait ClobOp[A] extends AnyRef

    Sum type of primitive operations over a java.sql.Clob.

Value Members

  1. final def !=(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  2. final def !=(arg0: Any): Boolean

    Definition Classes
    Any
  3. final def ##(): Int

    Definition Classes
    AnyRef → Any
  4. final def ==(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  5. final def ==(arg0: Any): Boolean

    Definition Classes
    Any
  6. implicit val CaptureClobIO: Capture[ClobIO]

    Capture instance for ClobIO.

  7. implicit val CatchableClobIO: Catchable[ClobIO]

    Catchable instance for ClobIO.

  8. object ClobOp

    Module of constructors for ClobOp.

  9. final def asInstanceOf[T0]: T0

    Definition Classes
    Any
  10. def attempt[A](a: ClobIO[A]): ClobIO[\/[Throwable, A]]

    Lift a ClobIO[A] into an exception-capturing ClobIO[Throwable \/ A].

  11. def clone(): AnyRef

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  12. def delay[A](a: ⇒ A): ClobIO[A]

    Non-strict unit for capturing effects.

  13. final def eq(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  14. def equals(arg0: Any): Boolean

    Definition Classes
    AnyRef → Any
  15. def finalize(): Unit

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  16. val free: ClobIO[Unit]

  17. val getAsciiStream: ClobIO[InputStream]

  18. def getCharacterStream(a: Long, b: Long): ClobIO[Reader]

  19. val getCharacterStream: ClobIO[Reader]

  20. final def getClass(): Class[_]

    Definition Classes
    AnyRef → Any
  21. def getSubString(a: Long, b: Int): ClobIO[String]

  22. def hashCode(): Int

    Definition Classes
    AnyRef → Any
  23. def interpK[M[_]](implicit arg0: Monad[M], arg1: Catchable[M], arg2: Capture[M]): ~>[ClobOp, [γ]Kleisli[M, Clob, γ]]

    Natural transformation from ClobOp to Kleisli for the given M, consuming a java.sql.Clob.

  24. final def isInstanceOf[T0]: Boolean

    Definition Classes
    Any
  25. val length: ClobIO[Long]

  26. def lift[Op[_], A, J](j: J, action: Free[Op, A])(implicit mod: Aux[Op, J]): ClobIO[A]

    Lift a different type of program that has a default Kleisli interpreter.

  27. final def ne(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  28. final def notify(): Unit

    Definition Classes
    AnyRef
  29. final def notifyAll(): Unit

    Definition Classes
    AnyRef
  30. def position(a: String, b: Long): ClobIO[Long]

  31. def position(a: Clob, b: Long): ClobIO[Long]

  32. def raw[A](f: (Clob) ⇒ A): ClobIO[A]

    Backdoor for arbitrary computations on the underlying Clob.

  33. def setAsciiStream(a: Long): ClobIO[OutputStream]

  34. def setCharacterStream(a: Long): ClobIO[Writer]

  35. def setString(a: Long, b: String): ClobIO[Int]

  36. def setString(a: Long, b: String, c: Int, d: Int): ClobIO[Int]

  37. final def synchronized[T0](arg0: ⇒ T0): T0

    Definition Classes
    AnyRef
  38. def toString(): String

    Definition Classes
    AnyRef → Any
  39. def trans[M[_]](c: Clob)(implicit arg0: Monad[M], arg1: Catchable[M], arg2: Capture[M]): ~>[ClobIO, M]

    Natural transformation from ClobIO to M, given a java.sql.Clob.

  40. def transK[M[_]](implicit arg0: Monad[M], arg1: Catchable[M], arg2: Capture[M]): ~>[ClobIO, [γ]Kleisli[M, Clob, γ]]

    Natural transformation from ClobIO to Kleisli for the given M, consuming a java.sql.Clob.

  41. def truncate(a: Long): ClobIO[Unit]

  42. final def wait(): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  43. final def wait(arg0: Long, arg1: Int): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  44. final def wait(arg0: Long): Unit

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )

Inherited from AnyRef

Inherited from Any

Algebra

Constructors (Lifting)

Constructors (Primitives)

Typeclass Instances

Ungrouped