public interface NexusBlockHandler
NexusEventReader
each time an according block BEGIN or END command is read.
Application developers implementing support for custom Nexus blocks can implement this interface
for their block is necessary. In most cases it will be useful to inherit such implementations from
AbstractNexusBlockHandler.
AbstractNexusBlockHandler,
NexusEventReader| Modifier and Type | Method and Description |
|---|---|
void |
beforeCommand(NexusReaderStreamDataProvider streamDataProvider,
java.lang.String commandName,
NexusCommandEventReader commandReader)
This method is called before a command found in a block handled by this handler is processed,
by calling the according command reader.
|
java.util.Collection<java.lang.String> |
getBlockNames()
Returns a collection of the block names this handler supports.
|
void |
handleBegin(NexusReaderStreamDataProvider streamDataProvider)
This method will be called by
NexusEventReader each time a BEGIN command for
a block listed in getBlockNames() is read. |
void |
handleEnd(NexusReaderStreamDataProvider streamDataProvider)
This method will be called by
NexusEventReader each time an END command for
a block listed in getBlockNames() is read. |
java.util.Collection<java.lang.String> getBlockNames()
void handleBegin(NexusReaderStreamDataProvider streamDataProvider)
NexusEventReader each time a BEGIN command for
a block listed in getBlockNames() is read.streamDataProvider - the stream data provider of the calling NexusEventReaderAbstractEventReader.getStreamDataProvider()void handleEnd(NexusReaderStreamDataProvider streamDataProvider)
NexusEventReader each time an END command for
a block listed in getBlockNames() is read.streamDataProvider - the stream data provider of the calling NexusEventReaderAbstractEventReader.getStreamDataProvider()void beforeCommand(NexusReaderStreamDataProvider streamDataProvider, java.lang.String commandName, NexusCommandEventReader commandReader)
streamDataProvider - the stream data provider of the calling NexusEventReadercommandName - the name of the Nexus command, that will be processed nextcommandReader - the reader that will be used to process this command or null if
no according reader was foundAbstractEventReader.getStreamDataProvider()