MapRef

cats.effect.std.MapRef
See theMapRef companion object
trait MapRef[F[_], K, V] extends K => Ref[F, V]

This is a total map from K to Ref[F, V]. This allows us to use the Ref API backed by a ConcurrentHashMap or similar.

Attributes

Companion:
object
Source:
MapRef.scala
Graph
Supertypes
trait K => Ref[F, V]
class Object
trait Matchable
class Any

Members list

Concise view

Value members

Abstract methods

def apply(k: K): Ref[F, V]

Access the reference for this Key

Access the reference for this Key

Attributes

Source:
MapRef.scala

Concrete methods

def getAndSetKeyValue(k: K, v: V): F[Option[V]]
Implicitly added by mapRefOptionSyntax

Attributes

Source:
MapRef.scala
def modifyKeyValueIfSet[B](k: K, f: V => (V, B)): F[Option[B]]
Implicitly added by mapRefOptionSyntax

Attributes

Source:
MapRef.scala
def setKeyValue(k: K, v: V): F[Unit]
Implicitly added by mapRefOptionSyntax

Attributes

Source:
MapRef.scala
def unsetKey(k: K): F[Unit]
Implicitly added by mapRefOptionSyntax

Attributes

Source:
MapRef.scala
def updateKeyValueIfSet(k: K, f: V => V): F[Unit]
Implicitly added by mapRefOptionSyntax

Attributes

Source:
MapRef.scala

Inherited methods

def andThen[A](g: Ref[F, V] => A): T1 => A

Attributes

Inherited from:
Function1
def compose[A](g: A => K): A => R

Attributes

Inherited from:
Function1
override def toString(): String

Returns a string representation of the object.

Returns a string representation of the object.

The default representation is platform dependent.

Attributes

Returns:

a string representation of the object.

Definition Classes
Function1 -> Any
Inherited from:
Function1