Class EntityEventHandler
java.lang.Object
com.sportradar.livedata.sdk.dispatch.livescout.EntityEventHandler
- All Implemented Interfaces:
com.lmax.disruptor.EventHandler<LiveScoutDispatcherContainer>
- Direct Known Subclasses:
LoggingEntityEventHandler
public abstract class EntityEventHandler
extends Object
implements com.lmax.disruptor.EventHandler<LiveScoutDispatcherContainer>
A
EventHandler implementation used to dispatch live-scout related entities to the user.-
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedEntityEventHandler(int id, int dispatcherCount, LiveScoutFeedListener listener, LiveScoutFeed feed) Initializes a new instance of theEntityEventHandlerclass -
Method Summary
Modifier and TypeMethodDescriptionprotected voiddispatchFullMatchUpdateReceived(MatchUpdateEntity matchUpdate) protected voidprotected voiddispatchLineups(LineupsEntity entity) protected voidprotected voiddispatchMatchData(MatchDataEntity entity) protected voiddispatchMatchList(MatchListEntity entity) protected voidprotected voiddispatchMatchStop(MatchStopEntity entity) protected voiddispatchMatchUpdate(MatchUpdateEntity matchUpdate) protected voiddispatchOnMatchDeltaUpdateDeltaReceived(MatchUpdateEntity matchUpdate) protected voiddispatchOnMatchDeltaUpdateReceived(MatchUpdateEntity matchUpdate) protected voiddispatchServerTime(ServerTimeEntity entity) voidonEvent(LiveScoutDispatcherContainer entityContainer, long sequenceNumber, boolean isEndOfBatch) Invoked by the disruptor when a message is ready to be processed by the current handler.
-
Constructor Details
-
EntityEventHandler
protected EntityEventHandler(int id, int dispatcherCount, LiveScoutFeedListener listener, LiveScoutFeed feed) Initializes a new instance of theEntityEventHandlerclass- Parameters:
id- The id of the currentEntityEventHandlerused to determine which messages will be processed by the current instance.dispatcherCount- The number ofEntityEventHandlerinstances handling user eventslistener- TheLiveScoutFeedListenerinstance used to inform the user about incoming messagesfeed- TheLiveScoutFeedwhich will be passed to method calls on the user provided listener
-
-
Method Details
-
onEvent
public void onEvent(LiveScoutDispatcherContainer entityContainer, long sequenceNumber, boolean isEndOfBatch) Invoked by the disruptor when a message is ready to be processed by the current handler.- Specified by:
onEventin interfacecom.lmax.disruptor.EventHandler<LiveScoutDispatcherContainer>- Parameters:
entityContainer- TheJaxbLiveScoutEntityFactorycontaining the information about the message to be raised.sequenceNumber- The ring buffer's sequence number of the current item.isEndOfBatch- Specifies whether the current item is the last of the available item batch.
-
dispatchLineups
-
dispatchMatchBooking
-
dispatchMatchData
-
dispatchMatchList
-
dispatchMatchListUpdate
-
dispatchMatchStop
-
dispatchMatchUpdate
-
dispatchFullMatchUpdateReceived
-
dispatchFullPaginatedMatchUpdateReceived
-
dispatchOnMatchDeltaUpdateDeltaReceived
-
dispatchOnMatchDeltaUpdateReceived
-
dispatchServerTime
-