MBrace.Runtime


Atom<'T>

Namespace: MBrace.Runtime.Utils

Thread-safe value container with optimistic update semantics

Constructors

ConstructorDescription
new(value)
Signature: value:'T -> Atom<'T>

CompiledName: .ctor

Instance members

Instance memberDescription
Force(value)
Signature: value:'T -> unit

Force a new value on container.

Swap(updater)
Signature: (updater:('T -> 'T)) -> unit

Atomically updates the container.

SwapAsync(updater)
Signature: (updater:('T -> Async<'T>)) -> Async<unit>

Asynchronously updates the container.

Transact(transactionF)
Signature: (transactionF:('T -> 'T * 'R)) -> 'R

Perform atomic transaction on container.

TransactAsync(transactionF)
Signature: (transactionF:('T -> Async<'T * 'R>)) -> Async<'R>

Asynchronously transacts container.

Value
Signature: 'T

Get Current Value

CompiledName: get_Value

Fork me on GitHub