public abstract class AbstractDispatchLayer<ConfigurationType> extends Object implements DispatchLayer<ConfigurationType>
Modifier and Type | Field and Description |
---|---|
protected static int |
CLEANUP_DELAY_MS |
protected static Timer |
cleanupTimer |
protected DispatchStack |
dispatchStack |
Constructor and Description |
---|
AbstractDispatchLayer() |
Modifier and Type | Method and Description |
---|---|
void |
finishedWith(String owningProcess)
Called when there will be no more events with the specified process
identifier, can be used to purge cached state from layers within the
stack
|
protected DispatchLayer<?> |
getAbove() |
protected DispatchLayer<?> |
getBelow() |
Processor |
getProcessor() |
void |
receiveError(DispatchErrorEvent errorEvent)
Receive a single error reference from the layer below
|
void |
receiveJob(DispatchJobEvent jobEvent)
Receive a single job and associated set of activities from the layer
above
|
void |
receiveJobQueue(DispatchJobQueueEvent jobQueueEvent)
Receive a pointer to the job queue along with a set of activities, this
is received from the layer above in the dispatch stack or from the
DispatchStackImpl object itself if this is the top layer.
|
void |
receiveResult(DispatchResultEvent resultEvent)
Receive a result from the layer below
|
void |
receiveResultCompletion(DispatchCompletionEvent completionEvent)
Receive a (possibly partial) completion event from the layer below.
|
void |
setDispatchStack(DispatchStack parentStack)
Set the parent dispatch stack of this layer, this is called when a layer
is added to the dispatch stack and can be safely ignored by end users of
this API
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
configure, getConfiguration
protected static Timer cleanupTimer
protected static final int CLEANUP_DELAY_MS
protected DispatchStack dispatchStack
public void setDispatchStack(DispatchStack parentStack)
DispatchLayer
setDispatchStack
in interface DispatchLayer<ConfigurationType>
protected final DispatchLayer<?> getAbove()
protected final DispatchLayer<?> getBelow()
public void receiveError(DispatchErrorEvent errorEvent)
DispatchLayer
receiveError
in interface DispatchLayer<ConfigurationType>
public void receiveJob(DispatchJobEvent jobEvent)
DispatchLayer
receiveJob
in interface DispatchLayer<ConfigurationType>
public void receiveJobQueue(DispatchJobQueueEvent jobQueueEvent)
DispatchLayer
receiveJobQueue
in interface DispatchLayer<ConfigurationType>
public void receiveResult(DispatchResultEvent resultEvent)
DispatchLayer
receiveResult
in interface DispatchLayer<ConfigurationType>
public void receiveResultCompletion(DispatchCompletionEvent completionEvent)
DispatchLayer
receiveResultCompletion
in interface DispatchLayer<ConfigurationType>
public void finishedWith(String owningProcess)
DispatchLayer
finishedWith
in interface DispatchLayer<ConfigurationType>
public Processor getProcessor()
Copyright © 2015–2016 The Apache Software Foundation. All rights reserved.