public abstract class ConcurrentService extends InitializeObject
| Modifier and Type | Field and Description |
|---|---|
protected Map<Object,Object> |
barriers |
protected Object |
defaultMutex |
mutex| Constructor and Description |
|---|
ConcurrentService() |
| Modifier and Type | Method and Description |
|---|---|
ConcurrentService |
addBarrier(Object barrierId) |
<V> V |
execute(Object barrierId,
Callable<V> task) |
<V> V |
execute(Object barrierId,
Callable<V> task,
long timeout,
TimeUnit unit) |
abstract ExecutorService |
getExecutorService() |
protected Object |
getMutex(Object barrierId) |
assertNotInitialized, destroy, init, initializeprotected final Object defaultMutex
public abstract ExecutorService getExecutorService()
public <V> V execute(Object barrierId, Callable<V> task, long timeout, TimeUnit unit) throws Exception
Exceptionpublic ConcurrentService addBarrier(Object barrierId)
Copyright © 2018. All rights reserved.