- CommuteRef <A>
- Value
- ToString ()
- GetHashCode ()
- Equals (object obj)
- Equals (A other)
- Swap (Func<A, A> f)
- Swap <X> (X x, Func<X, A, A> f)
- Swap <X, Y> (X x, Y y, Func<X, Y, A, A> f)
- Commute (Func<A, A> f)
- Commute <X> (X x, Func<X, A, A> f)
- Commute <X, Y> (X x, Y y, Func<X, Y, A, A> f)
- Isolation
- Ref <A>
- Value
- ToString ()
- GetHashCode ()
- Equals (object obj)
- Equals (A other)
- Swap (Func<A, A> f)
- SwapAsync (Func<A, ValueTask<A>> f)
- SwapAff (Func<A, Aff<A>> f)
- SwapEff (Func<A, Eff<A>> f)
- SwapAff <RT> (Func<A, Aff<RT, A>> f)
- SwapEff <RT> (Func<A, Eff<RT, A>> f)
- Swap <X> (X x, Func<X, A, A> f)
- SwapAsync <X, Y> (X x, Y y, Func<X, Y, A, ValueTask<A>> f)
- SwapAff <X, Y> (X x, Y y, Func<X, Y, A, Aff<A>> f)
- SwapEff <X, Y> (X x, Y y, Func<X, Y, A, Eff<A>> f)
- SwapAff <X, Y, RT> (X x, Y y, Func<X, Y, A, Aff<RT, A>> f)
- SwapEff <X, Y, RT> (X x, Y y, Func<X, Y, A, Eff<RT, A>> f)
- Swap <X, Y> (X x, Y y, Func<X, Y, A, A> f)
- SwapAsync <X> (X x, Func<X, A, ValueTask<A>> f)
- SwapAff <X> (X x, Func<X, A, Aff<A>> f)
- SwapEff <X> (X x, Func<X, A, Eff<A>> f)
- SwapAff <X, RT> (X x, Func<X, A, Aff<RT, A>> f)
- SwapEff <X, RT> (X x, Func<X, A, Eff<RT, A>> f)
- Commute (Func<A, A> f)
- Commute <X> (X x, Func<X, A, A> f)
- Commute <X, Y> (X x, Y y, Func<X, Y, A, A> f)
- STM
struct CommuteRef <A> Source #
A proxy for Ref
, returned by commute
. This allows the transaction system to know that the
result is a commutative and therefore give you a result based on the live state rather than
the transaction.
See the concurrency section of the wiki for more info.
method int GetHashCode () Source #
sync
transaction isolation level. Used to enforce ACI properties
of ACID on Ref
s.
See the concurrency section of the wiki for more info.
Refs ensure safe shared use of mutable storage locations via a software transactional memory (STM) system. Refs are bound to a single storage location for their lifetime, and only allow mutation of that location to occur within a transaction.
See the concurrency section of the wiki for more info.
method int GetHashCode () Source #
Hash code of the bound value
method A Swap (Func<A, A> f) Source #
Swap the old value for the new returned by f
Must be run within a sync
transaction
param | f | Swap function |
returns | The value returned from |
method ValueTask<A> SwapAsync (Func<A, ValueTask<A>> f) Source #
Swap the old value for the new returned by f
Must be run within a sync
transaction
param | f | Swap function |
returns | The value returned from |
method Aff<A> SwapAff (Func<A, Aff<A>> f) Source #
Swap the old value for the new returned by f
Must be run within a sync
transaction
param | f | Swap function |
returns | The value returned from |
method Eff<A> SwapEff (Func<A, Eff<A>> f) Source #
Swap the old value for the new returned by f
Must be run within a sync
transaction
param | f | Swap function |
returns | The value returned from |
method Aff<RT, A> SwapAff <RT> (Func<A, Aff<RT, A>> f) Source #
Swap the old value for the new returned by f
Must be run within a sync
transaction
param | f | Swap function |
returns | The value returned from |
method Eff<RT, A> SwapEff <RT> (Func<A, Eff<RT, A>> f) Source #
Swap the old value for the new returned by f
Must be run within a sync
transaction
param | f | Swap function |
returns | The value returned from |
method A Swap <X> (X x, Func<X, A, A> f) Source #
Swap the old value for the new returned by f
Must be run within a sync
transaction
param | f | Swap function |
returns | The value returned from |
method ValueTask<A> SwapAsync <X, Y> (X x, Y y, Func<X, Y, A, ValueTask<A>> f) Source #
Swap the old value for the new returned by f
Must be run within a sync
transaction
param | f | Swap function |
returns | The value returned from |
method Aff<A> SwapAff <X, Y> (X x, Y y, Func<X, Y, A, Aff<A>> f) Source #
Swap the old value for the new returned by f
Must be run within a sync
transaction
param | f | Swap function |
returns | The value returned from |
method Eff<A> SwapEff <X, Y> (X x, Y y, Func<X, Y, A, Eff<A>> f) Source #
Swap the old value for the new returned by f
Must be run within a sync
transaction
param | f | Swap function |
returns | The value returned from |
method Aff<RT, A> SwapAff <X, Y, RT> (X x, Y y, Func<X, Y, A, Aff<RT, A>> f) Source #
Swap the old value for the new returned by f
Must be run within a sync
transaction
param | f | Swap function |
returns | The value returned from |
method Eff<RT, A> SwapEff <X, Y, RT> (X x, Y y, Func<X, Y, A, Eff<RT, A>> f) Source #
Swap the old value for the new returned by f
Must be run within a sync
transaction
param | f | Swap function |
returns | The value returned from |
method A Swap <X, Y> (X x, Y y, Func<X, Y, A, A> f) Source #
Swap the old value for the new returned by f
Must be run within a sync
transaction
param | f | Swap function |
returns | The value returned from |
method ValueTask<A> SwapAsync <X> (X x, Func<X, A, ValueTask<A>> f) Source #
Swap the old value for the new returned by f
Must be run within a sync
transaction
param | f | Swap function |
returns | The value returned from |
method Aff<A> SwapAff <X> (X x, Func<X, A, Aff<A>> f) Source #
Swap the old value for the new returned by f
Must be run within a sync
transaction
param | f | Swap function |
returns | The value returned from |
method Eff<A> SwapEff <X> (X x, Func<X, A, Eff<A>> f) Source #
Swap the old value for the new returned by f
Must be run within a sync
transaction
param | f | Swap function |
returns | The value returned from |
method Aff<RT, A> SwapAff <X, RT> (X x, Func<X, A, Aff<RT, A>> f) Source #
Swap the old value for the new returned by f
Must be run within a sync
transaction
param | f | Swap function |
returns | The value returned from |
method Eff<RT, A> SwapEff <X, RT> (X x, Func<X, A, Eff<RT, A>> f) Source #
Swap the old value for the new returned by f
Must be run within a sync
transaction
param | f | Swap function |
returns | The value returned from |
method CommuteRef<A> Commute (Func<A, A> f) Source #
Must be called in a transaction. Sets the in-transaction-value of ref to:
`f(in-transaction-value-of-ref)`
and returns the in-transaction-value when complete.
At the commit point of the transaction, f
is run AGAIN with the
most recently committed value:
`f(most-recently-committed-value-of-ref)`
Thus f
should be commutative, or, failing that, you must accept
last-one-in-wins behavior.
Commute allows for more concurrency than just setting the Ref's value
method CommuteRef<A> Commute <X> (X x, Func<X, A, A> f) Source #
Must be called in a transaction. Sets the in-transaction-value of ref to:
`f(in-transaction-value-of-ref)`
and returns the in-transaction-value when complete.
At the commit point of the transaction, f
is run AGAIN with the
most recently committed value:
`f(most-recently-committed-value-of-ref)`
Thus f
should be commutative, or, failing that, you must accept
last-one-in-wins behavior.
Commute allows for more concurrency than just setting the Ref's value
method CommuteRef<A> Commute <X, Y> (X x, Y y, Func<X, Y, A, A> f) Source #
Must be called in a transaction. Sets the in-transaction-value of ref to:
`f(in-transaction-value-of-ref)`
and returns the in-transaction-value when complete.
At the commit point of the transaction, f
is run AGAIN with the
most recently committed value:
`f(most-recently-committed-value-of-ref)`
Thus f
should be commutative, or, failing that, you must accept
last-one-in-wins behavior.
Commute allows for more concurrency than just setting the Ref's value
Software transactional memory using Multi-Version Concurrency Control (MVCC)
See the concurrency section of the wiki for more info.
property long TransactionId Source #
Get the currently running TransactionId