Add a task to run after the current transaction has committed.
Add a task to run after the current transaction has committed.
the Runnable
task to run after transaction commit
if called from outside a transaction
Add a task to run after the current transaction has either rolled back or committed.
Add a task to run after the current transaction has either rolled back or committed.
the Runnable
task to run after transaction completion
if called from outside a transaction
Add a task to run after the current transaction has rolled back.
Add a task to run after the current transaction has rolled back.
the Runnable
task to run after transaction rollback
if called from outside a transaction
Atomic block that takes a Callable
.
Atomic block that takes a Callable
.
the Callable
to run within a transaction
the value returned by the Callable
Atomic block that takes a Runnable
.
Atomic block that takes a Runnable
.
the Runnable
to run within a transaction
Transform the value stored by ref
by applying the function f
and
return the old value.
Transform the value stored by ref
by applying the function f
and
return the old value.
the Ref.View
to be transformed
the function to be applied
the old value of ref
Increment the java.lang.Long
value of a Ref.View
.
Increment the java.lang.Long
value of a Ref.View
.
the Ref.View<Long>
to be incremented
the amount to increment
Increment the java.lang.Integer
value of a Ref.View
.
Increment the java.lang.Integer
value of a Ref.View
.
the Ref.View<Integer>
to be incremented
the amount to increment
Create an empty TArray.
Create an empty TArray. Return a java.util.List
view of this Array.
the length of the TArray.View
to be created
a new, empty TArray.View
wrapped as a java.util.List
.
Create an empty TMap.
Create an empty TMap. Return a java.util.Map
view of this TMap.
a new, empty TMap.View
wrapped as a java.util.Map
.
Create a Ref with an initial value.
Create a Ref with an initial value. Return a Ref.View
, which does not
require implicit transactions.
the initial value for the newly created Ref.View
a new Ref.View
Create an empty TSet.
Create an empty TSet. Return a java.util.Set
view of this TSet.
a new, empty TSet.View
wrapped as a java.util.Set
.
Create a TArray containing length
elements.
Create a TArray containing length
elements. Return a TArray.View
,
which does not require implicit transactions. See newList for included
java conversion.
the length of the TArray.View
to be created
a new TArray.View
containing length
elements (initially null)
Create an empty TMap.
Create an empty TMap. Return a TMap.View
, which does not require
implicit transactions. See newMap for included java conversion.
a new, empty TMap.View
Create an empty TSet.
Create an empty TSet. Return a TSet.View
, which does not require
implicit transactions. See newSet for included java conversion.
a new, empty TSet.View
Causes the enclosing transaction to back up and wait until one
of the Ref
s touched by this transaction has changed.
Causes the enclosing transaction to back up and wait until one
of the Ref
s touched by this transaction has changed.
if not in a transaction
Like retry
, but limits the total amount of blocking.
Like retry
, but limits the total amount of blocking. This method
only returns normally when the timeout has expired.
Transform the value stored by ref
by applying the function f
.
Transform the value stored by ref
by applying the function f
.
the Ref.View
to be transformed
the function to be applied
Transform the value stored by ref
by applying the function f
and
return the new value.
Transform the value stored by ref
by applying the function f
and
return the new value.
the Ref.View
to be transformed
the function to be applied
the new value of ref
Java-friendly API for ScalaSTM. These methods can also be statically imported.