com.voytechs.jnetstream.codec.event
Class DecoderHeaderEvent

java.lang.Object
  extended by com.voytechs.jnetstream.codec.event.DecoderEvent
      extended by com.voytechs.jnetstream.codec.event.DecoderInternals
          extended by com.voytechs.jnetstream.codec.event.DecoderHeaderEvent

public class DecoderHeaderEvent
extends DecoderInternals

Decoder event for new headers. When a new header is created by the decoder this event is dispatched. Event is dispatched after the header has been fully processed and assesed. You can retrieve the following information from this event.


Field Summary
static java.lang.String NAME
           
static java.lang.String TYPE
           
 
Constructor Summary
DecoderHeaderEvent(Header header, Packet packet, Decoder decoder, SymTable symTable, Context context)
          New Header has been created event.
 
Method Summary
 Header getHeader()
          Returns the header that caused this event to be dispatched.
static void main(java.lang.String[] args)
          Test function for DecoderHeaderEvent
 java.lang.String toString()
          Returns nicely formated representation of this object.
 
Methods inherited from class com.voytechs.jnetstream.codec.event.DecoderInternals
getContext, getDecoder, getSymTable
 
Methods inherited from class com.voytechs.jnetstream.codec.event.DecoderEvent
getSubType, getType
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

TYPE

public static final java.lang.String TYPE
See Also:
Constant Field Values

NAME

public static final java.lang.String NAME
See Also:
Constant Field Values
Constructor Detail

DecoderHeaderEvent

public DecoderHeaderEvent(Header header,
                          Packet packet,
                          Decoder decoder,
                          SymTable symTable,
                          Context context)
New Header has been created event. The event is initialized with a number of internal structures of the Decoder to aid in handling and allowing advanced processing to occur.

Parameters:
header - The Header that was constructed that caused the dispatch.
symTable - Symbolic table of the internal structure this event is for.
context - Runtime context which holds all of the variables and references.
decoder - The decoder that is the parent of all of the internal structures.
packet - This is the packet that the structure being constructed belongs to.
Method Detail

getHeader

public Header getHeader()
Returns the header that caused this event to be dispatched.

Returns:
Header structure.

toString

public java.lang.String toString()
Returns nicely formated representation of this object.

Overrides:
toString in class DecoderInternals
Returns:
String representation of this object.

main

public static void main(java.lang.String[] args)
Test function for DecoderHeaderEvent

Parameters:
args - command line arguments