Cached

zio.Cached
See theCached companion trait
object Cached

Attributes

Companion
trait
Graph
Supertypes
trait Sum
trait Mirror
class Object
trait Matchable
class Any
Self type
Cached.type

Members list

Type members

Inherited and Abstract types

The names of the product elements

The names of the product elements

Attributes

Inherited from:
Mirror

The name of the type

The name of the type

Attributes

Inherited from:
Mirror

Value members

Concrete methods

def auto[R, Error, Resource](acquire: ZIO[R, Error, Resource], policy: Schedule[Any, Any, Any])(implicit trace: Trace): ZIO[R & Scope, Nothing, Cached[Error, Resource]]

Creates a new Cached value that is automatically refreshed according to the specified policy. Note that error retrying is not performed automatically, so if you want to retry on errors, you should first apply retry policies to the acquisition effect before passing it to this constructor.

Creates a new Cached value that is automatically refreshed according to the specified policy. Note that error retrying is not performed automatically, so if you want to retry on errors, you should first apply retry policies to the acquisition effect before passing it to this constructor.

Attributes

def manual[R, Error, Resource](acquire: ZIO[R, Error, Resource])(implicit trace: Trace): ZIO[R & Scope, Nothing, Cached[Error, Resource]]

Creates a new Cached value that must be manually refreshed by calling the refresh method. Note that error retrying is not performed automatically, so if you want to retry on errors, you should first apply retry policies to the acquisition effect before passing it to this constructor.

Creates a new Cached value that must be manually refreshed by calling the refresh method. Note that error retrying is not performed automatically, so if you want to retry on errors, you should first apply retry policies to the acquisition effect before passing it to this constructor.

Attributes