Package com.atlassian.bamboo.concurrent
Class CalculatingBlockingReference<T>
java.lang.Object
com.atlassian.bamboo.concurrent.CalculatingBlockingReference<T>
Retrieves a reference from a supplier. If
Supplier.get()
method is currently NOT being executed,
it is called to provide a value to return.
Otherwise, instead of running parallel computations, the calling threads will wait until the current computation is completed.
Then, they'll all get the same value from the originally running calculation.-
Constructor Summary
-
Method Summary
-
Constructor Details
-
CalculatingBlockingReference
-
-
Method Details
-
get
- Throws:
InterruptedException
-
make
-