Package: effect
Module: SynchronizedRef
Applies a partial update and returns the resulting current value.
Option.some stores and returns the new value; Option.none returns the
unchanged value.
When to use
Use to apply a pure conditional SynchronizedRef update and return the
resulting current value.
See
updateSome for conditional updates without returning a valueupdateAndGet for always applying a pure update and returning the new valueSignature
declare const updateSomeAndGet: { <A>(pf: (a: A) => Option.Option<A>): (self: SynchronizedRef<A>) => Effect.Effect<A>; <A>(self: SynchronizedRef<A>, pf: (a: A) => Option.Option<A>): Effect.Effect<A>; }
Since v2.0.0