public class ExecutorWorkSerializer extends Lifecycle implements IWorkSerializer
ILifecycle.DeferrableActivation
Constructor and Description |
---|
ExecutorWorkSerializer() |
ExecutorWorkSerializer(Executor executor) |
Modifier and Type | Method and Description |
---|---|
boolean |
addWork(Runnable runnable) |
void |
dispose() |
protected void |
doActivate() |
protected void |
doBeforeActivate() |
protected void |
doDeactivate() |
Executor |
getExecutor() |
protected void |
handleException(Runnable runnable,
Throwable ex) |
protected void |
noWork() |
void |
setExecutor(Executor executor) |
String |
toString() |
activate, checkActive, checkArg, checkArg, checkInactive, checkNull, checkState, checkState, deactivate, deferredActivate, doAfterActivate, doBeforeDeactivate, dump, getLifecycleState, isActive, isDeferredActivation
addListener, fireEvent, fireEvent, fireEvent, fireThrowable, firstListenerAdded, getListeners, getNotificationService, hasListeners, lastListenerRemoved, removeListener
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
addListener, getListeners, hasListeners, removeListener
public ExecutorWorkSerializer()
public ExecutorWorkSerializer(Executor executor)
public Executor getExecutor()
public void setExecutor(Executor executor)
public boolean addWork(Runnable runnable)
addWork
in interface IWorkSerializer
public void dispose()
dispose
in interface IWorkSerializer
protected void noWork()
protected void doBeforeActivate() throws Exception
doBeforeActivate
in class Lifecycle
Exception
protected void doActivate() throws Exception
doActivate
in class Lifecycle
Exception
protected void doDeactivate() throws Exception
doDeactivate
in class Lifecycle
Exception
Copyright (c) 2011-2015 Eike Stepper (Berlin, Germany) and others.