Class Consumers<V>
- java.lang.Object
-
- org.apache.hugegraph.computer.core.util.Consumers<V>
-
public final class Consumers<V> extends java.lang.Object
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classConsumers.StopExecution
-
Field Summary
Fields Modifier and Type Field Description static longCONSUMER_WAKE_PERIODstatic intQUEUE_WORKER_SIZEstatic intTHREADS
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description voidawait()java.util.concurrent.ExecutorServiceexecutor()voidprovide(V v)voidstart(java.lang.String name)static java.lang.RuntimeExceptionwrapException(java.lang.Throwable e)
-
-
-
Field Detail
-
THREADS
public static final int THREADS
- See Also:
- Constant Field Values
-
QUEUE_WORKER_SIZE
public static final int QUEUE_WORKER_SIZE
- See Also:
- Constant Field Values
-
CONSUMER_WAKE_PERIOD
public static final long CONSUMER_WAKE_PERIOD
- See Also:
- Constant Field Values
-
-
Method Detail
-
start
public void start(java.lang.String name)
-
provide
public void provide(V v) throws java.lang.Throwable
- Throws:
java.lang.Throwable
-
await
public void await() throws java.lang.Throwable- Throws:
java.lang.Throwable
-
executor
public java.util.concurrent.ExecutorService executor()
-
wrapException
public static java.lang.RuntimeException wrapException(java.lang.Throwable e)
-
-