public abstract class ExecutingDistributedPrimitive extends DelegatingDistributedPrimitive
Executor.| Modifier | Constructor and Description |
|---|---|
protected |
ExecutingDistributedPrimitive(org.onosproject.store.service.DistributedPrimitive primitive,
Executor orderedExecutor,
Executor threadPoolExecutor) |
| Modifier and Type | Method and Description |
|---|---|
void |
addStatusChangeListener(Consumer<org.onosproject.store.service.DistributedPrimitive.Status> listener) |
protected <T> CompletableFuture<T> |
asyncFuture(CompletableFuture<T> future)
Creates a future to be completed asynchronously on the provided ordered and thread pool executors.
|
CompletableFuture<Void> |
destroy() |
void |
removeStatusChangeListener(Consumer<org.onosproject.store.service.DistributedPrimitive.Status> listener) |
applicationId, equals, hashCode, name, primitiveType, statusChangeListeners, toStringprotected <T> CompletableFuture<T> asyncFuture(CompletableFuture<T> future)
T - future result typefuture - the future to be completed asynchronouslyCompletableFuture to be completed asynchronously using the primitive thread modelpublic CompletableFuture<Void> destroy()
destroy in interface org.onosproject.store.service.DistributedPrimitivedestroy in class DelegatingDistributedPrimitivepublic void addStatusChangeListener(Consumer<org.onosproject.store.service.DistributedPrimitive.Status> listener)
addStatusChangeListener in interface org.onosproject.store.service.DistributedPrimitiveaddStatusChangeListener in class DelegatingDistributedPrimitivepublic void removeStatusChangeListener(Consumer<org.onosproject.store.service.DistributedPrimitive.Status> listener)
removeStatusChangeListener in interface org.onosproject.store.service.DistributedPrimitiveremoveStatusChangeListener in class DelegatingDistributedPrimitive