Class Runner
java.lang.Object
java.util.concurrent.AbstractExecutorService
org.cojen.tupl.util.Runner
- All Implemented Interfaces:
AutoCloseable
,Executor
,ExecutorService
Implements an unbounded pool of daemon threads which automatically exit when idle. Intended
as a faster alternative to launching new threads, but not as fast as a work stealing pool.
-
Method Summary
Modifier and TypeMethodDescriptionboolean
awaitTermination
(long timeout, TimeUnit unit) static Runner
current()
Return an executor for the current thread's group.void
boolean
boolean
void
shutdown()
Does nothing.Does nothing.static void
static void
Methods inherited from class java.util.concurrent.AbstractExecutorService
invokeAll, invokeAll, invokeAny, invokeAny, newTaskFor, newTaskFor, submit, submit, submit
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface java.util.concurrent.ExecutorService
close
-
Method Details
-
start
-
start
-
current
Return an executor for the current thread's group. -
execute
-
shutdown
public void shutdown()Does nothing. -
shutdownNow
-
isShutdown
public boolean isShutdown()- Returns:
- false
-
isTerminated
public boolean isTerminated()- Returns:
- false
-
awaitTermination
- Returns:
- false
- Throws:
InterruptedException
-