class Make_[+F[_], A] extends Make[F, A]

Class-based variant of make_:

class IntRes extends Lifecycle.Make_(IO(1000))(IO.unit)

For binding resources using class syntax in ModuleDef:

val module = new ModuleDef {
  make[Int].fromResource[IntRes]
}
Annotations
@open()
Linear Supertypes
Make[F, A], Basic[F, A], Lifecycle[F, A], AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. Make_
  2. Make
  3. Basic
  4. Lifecycle
  5. AnyRef
  6. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. Protected

Instance Constructors

  1. new Make_(acquire: => F[A])(release: => F[Unit])

Type Members

  1. final type InnerResource = A
    Definition Classes
    BasicLifecycle

Value Members

  1. final def !=(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  2. final def ##: Int
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean
    Definition Classes
    AnyRef → Any
  4. final def acquire: F[A]

    The action in F used to acquire the resource.

    The action in F used to acquire the resource.

    Definition Classes
    MakeBasicLifecycle
    Note

    the acquire action is performed *uninterruptibly*, when F is an effect type that supports interruption/cancellation.

  5. final def asInstanceOf[T0]: T0
    Definition Classes
    Any
  6. final def beforeAcquire[G[x] >: F[x]](f: => G[Unit])(implicit arg0: QuasiApplicative[G]): Lifecycle[G, A]
    Definition Classes
    Lifecycle
  7. final def beforeRelease[G[x] >: F[x]](f: (InnerResource) => G[Unit])(implicit arg0: QuasiApplicative[G]): Lifecycle[G, A]
    Definition Classes
    Lifecycle
  8. def clone(): AnyRef
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.CloneNotSupportedException]) @native()
  9. final def eq(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  10. def equals(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef → Any
  11. final def evalMap[G[x] >: F[x], B](f: (A) => G[B])(implicit arg0: QuasiIO[G]): Lifecycle[G, B]
    Definition Classes
    Lifecycle
  12. final def evalTap[G[x] >: F[x]](f: (A) => G[Unit])(implicit arg0: QuasiIO[G]): Lifecycle[G, A]
    Definition Classes
    Lifecycle
  13. final def extract[B >: A](resource: A): Right[Nothing, A]

    Either an action in F or a pure function used to extract the OuterResource from the InnerResource

    Either an action in F or a pure function used to extract the OuterResource from the InnerResource

    The effect in the Left branch will be performed *interruptibly*, it is not afforded the same kind of safety as acquire and release actions when F is an effect type that supports interruption/cancellation.

    When F is Identity, it doesn't matter whether the output is a Left or Right branch.

    When consuming the output of extract you can use _.fold(identity, F.pure) to convert the Either to F[B]

    Definition Classes
    BasicLifecycle
    See also

    Lifecycle.Basic extract doesn't have to be defined when inheriting from Lifecycle.Basic

  14. def finalize(): Unit
    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.Throwable])
  15. final def flatMap[G[x] >: F[x], B](f: (A) => Lifecycle[G, B])(implicit arg0: QuasiIO[G]): Lifecycle[G, B]
    Definition Classes
    Lifecycle
  16. final def getClass(): Class[_ <: AnyRef]
    Definition Classes
    AnyRef → Any
    Annotations
    @native()
  17. def hashCode(): Int
    Definition Classes
    AnyRef → Any
    Annotations
    @native()
  18. final def isInstanceOf[T0]: Boolean
    Definition Classes
    Any
  19. final def map[G[x] >: F[x], B](f: (A) => B)(implicit arg0: QuasiFunctor[G]): Lifecycle[G, B]
    Definition Classes
    Lifecycle
  20. final def ne(arg0: AnyRef): Boolean
    Definition Classes
    AnyRef
  21. final def notify(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  22. final def notifyAll(): Unit
    Definition Classes
    AnyRef
    Annotations
    @native()
  23. final def release(resource: A): F[Unit]

    The action in F used to release, close or deallocate the resource after it has been acquired and used through izumi.distage.model.definition.Lifecycle.SyntaxUse#use.

    The action in F used to release, close or deallocate the resource after it has been acquired and used through izumi.distage.model.definition.Lifecycle.SyntaxUse#use.

    Definition Classes
    MakeBasicLifecycle
    Note

    the release action is performed *uninterruptibly*, when F is an effect type that supports interruption/cancellation.

  24. final def synchronized[T0](arg0: => T0): T0
    Definition Classes
    AnyRef
  25. def toString(): String
    Definition Classes
    AnyRef → Any
  26. final def void[G[x] >: F[x]](implicit arg0: QuasiFunctor[G]): Lifecycle[G, Unit]
    Definition Classes
    Lifecycle
  27. final def wait(): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  28. final def wait(arg0: Long, arg1: Int): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException])
  29. final def wait(arg0: Long): Unit
    Definition Classes
    AnyRef
    Annotations
    @throws(classOf[java.lang.InterruptedException]) @native()
  30. final def widen[B >: A]: Lifecycle[F, B]
    Definition Classes
    Lifecycle
    Annotations
    @inline()
  31. final def widenF[G[x] >: F[x]]: Lifecycle[G, A]
    Definition Classes
    Lifecycle
    Annotations
    @inline()
  32. final def wrapAcquire[G[x] >: F[x]](f: (=> G[InnerResource]) => G[InnerResource]): Lifecycle[G, A]

    Wrap acquire action of this resource in another effect, e.g.

    Wrap acquire action of this resource in another effect, e.g. for logging purposes

    Definition Classes
    Lifecycle
  33. final def wrapRelease[G[x] >: F[x]](f: ((InnerResource) => G[Unit], InnerResource) => G[Unit]): Lifecycle[G, A]

    Wrap release action of this resource in another effect, e.g.

    Wrap release action of this resource in another effect, e.g. for logging purposes

    Definition Classes
    Lifecycle

Inherited from Make[F, A]

Inherited from Basic[F, A]

Inherited from Lifecycle[F, A]

Inherited from AnyRef

Inherited from Any

Ungrouped