A blocking get.
A blocking get. It won't cause a deadlock if the IVar is already defined because it does not attempt to defer getting a defined value.
Provide an IVar that is chained to this one.
Provide an IVar that is chained to this one. This provides a happens-before relationship vis-a-vis *this* IVar. That is: an ordering that is visible to the consumer of this IVar (wrt. gets) is preserved via chaining.
That is, to use in a manner that guarantees strict ordering of invocation, use the following pattern:
val ivar: IVar[A] val next = ivar.chained ivar.get { _ => /* first action */} next.get { _ => /* second action */}
Pass a block, 'k' which will be invoked when the value is available.
Pass a block, 'k' which will be invoked when the value is available. Note that 'get' does not preserve ordering, that is: {{a.get(k); a.get(k')}} does not imply {{k}} happens-before {{k'}}.
true if the value has been set.
Merge other
into this IVar.
Merge other
into this IVar. This does two things:
this
assumes waiters and chainers of other
.
2. the state of other
is changed to Linked(this).Note that two Done IVars can only be merged if their values are equal. An InvalidArgumentException is thrown, otherwise.
Set the value - only the first call will be successful.
Set the value - only the first call will be successful.
true if the value was set successfully.
Remove the given closure {{k}} from the waiter list by object identity.
Remove the given closure {{k}} from the waiter list by object identity.