com.lmax.disruptor
Interface EventHandler<T>
- Type Parameters:
T - event implementation storing the data for sharing during exchange or parallel coordination of an event.
- All Known Subinterfaces:
- SequenceReportingEventHandler<T>
- All Known Implementing Classes:
- AggregateEventHandler
public interface EventHandler<T>
Callback interface to be implemented for processing events as they become available in the RingBuffer
- See Also:
if you want to handle exceptions propigated out of the handler.
|
Method Summary |
void |
onEvent(T event,
long sequence,
boolean endOfBatch)
Called when a publisher has published an event to the RingBuffer |
onEvent
void onEvent(T event,
long sequence,
boolean endOfBatch)
throws java.lang.Exception
- Called when a publisher has published an event to the
RingBuffer
- Parameters:
event - published to the RingBuffersequence - of the event being processedendOfBatch - flag to indicate if this is the last event in a batch from the RingBuffer
- Throws:
java.lang.Exception - if the EventHandler would like the exception handled further up the chain.
Copyright © 2011 LMAX Ltd. All Rights Reserved.