public abstract class AbstractTokenListener extends Object implements TokenListener
TokenListener that can be extended when not all callback methods are required.
By extending this class their is a possibility for the optimizer to elide unused methods otherwise
requiring polymorphic dispatch.| Constructor and Description |
|---|
AbstractTokenListener() |
| Modifier and Type | Method and Description |
|---|---|
void |
onBeginComposite(Token fieldToken,
List<Token> tokens,
int fromIndex,
int toIndex)
Beginning of Composite encoded type encountered.
|
void |
onBeginGroup(Token token,
int groupIndex,
int numInGroup)
Beginning of group encoded type encountered.
|
void |
onBeginMessage(Token token)
Called on beginning the decoding of a message.
|
void |
onBitSet(Token fieldToken,
DirectBuffer buffer,
int bufferIndex,
List<Token> tokens,
int fromIndex,
int toIndex,
int actingVersion)
BitSet encoded type encountered.
|
void |
onEncoding(Token fieldToken,
DirectBuffer buffer,
int bufferIndex,
Token typeToken,
int actingVersion)
Primitive encoded type encountered.
|
void |
onEndComposite(Token fieldToken,
List<Token> tokens,
int fromIndex,
int toIndex)
End of Composite encoded type encountered.
|
void |
onEndGroup(Token token,
int groupIndex,
int numInGroup)
End of group encoded type encountered.
|
void |
onEndMessage(Token token)
Called on end of decoding of a message.
|
void |
onEnum(Token fieldToken,
DirectBuffer buffer,
int bufferIndex,
List<Token> tokens,
int fromIndex,
int toIndex,
int actingVersion)
Enum encoded type encountered.
|
void |
onGroupHeader(Token token,
int numInGroup)
Group encountered.
|
void |
onVarData(Token fieldToken,
DirectBuffer buffer,
int bufferIndex,
int length,
Token typeToken)
Var data field encountered.
|
public void onBeginMessage(Token token)
TokenListeneronBeginMessage in interface TokenListenertoken - representing the IR for message including meta data.public void onEndMessage(Token token)
TokenListeneronEndMessage in interface TokenListenertoken - representing the IR for message including meta data.public void onEncoding(Token fieldToken, DirectBuffer buffer, int bufferIndex, Token typeToken, int actingVersion)
TokenListeneronEncoding in interface TokenListenerfieldToken - in the IR representing the field of the message root or group.buffer - containing the encoded message.bufferIndex - at which the encoded field begins.typeToken - of the encoded primitive value.actingVersion - of the encoded message for determining validity of extension fields.public void onEnum(Token fieldToken, DirectBuffer buffer, int bufferIndex, List<Token> tokens, int fromIndex, int toIndex, int actingVersion)
TokenListeneronEnum in interface TokenListenerfieldToken - in the IR representing the field of the message root or group.buffer - containing the encoded message.bufferIndex - at which the encoded field begins.tokens - describing the message.fromIndex - at which the enum metadata begins.toIndex - at which the enum metadata ends.actingVersion - of the encoded message for determining validity of extension fields.public void onBitSet(Token fieldToken, DirectBuffer buffer, int bufferIndex, List<Token> tokens, int fromIndex, int toIndex, int actingVersion)
TokenListeneronBitSet in interface TokenListenerfieldToken - in the IR representing the field of the message root or group.buffer - containing the encoded message.bufferIndex - at which the encoded field begins.tokens - describing the message.fromIndex - at which the bit set metadata begins.toIndex - at which the bit set metadata ends.actingVersion - of the encoded message for determining validity of extension fields.public void onBeginComposite(Token fieldToken, List<Token> tokens, int fromIndex, int toIndex)
TokenListeneronBeginComposite in interface TokenListenerfieldToken - in the IR representing the field of the message root or group.tokens - describing the message.fromIndex - at which the composite metadata begins.toIndex - at which the composite metadata ends.public void onEndComposite(Token fieldToken, List<Token> tokens, int fromIndex, int toIndex)
TokenListeneronEndComposite in interface TokenListenerfieldToken - in the IR representing the field of the message root or group.tokens - describing the message.fromIndex - at which the composite metadata begins.toIndex - at which the composite metadata ends.public void onGroupHeader(Token token, int numInGroup)
TokenListeneronGroupHeader in interface TokenListenertoken - describing the group.numInGroup - number of times the group will be repeated.public void onBeginGroup(Token token, int groupIndex, int numInGroup)
TokenListeneronBeginGroup in interface TokenListenertoken - describing the group.groupIndex - index for the repeat count of the group.numInGroup - number of times the group will be repeated.public void onEndGroup(Token token, int groupIndex, int numInGroup)
TokenListeneronEndGroup in interface TokenListenertoken - describing the group.groupIndex - index for the repeat count of the group.numInGroup - number of times the group will be repeated.public void onVarData(Token fieldToken, DirectBuffer buffer, int bufferIndex, int length, Token typeToken)
TokenListeneronVarData in interface TokenListenerfieldToken - in the IR representing the var data field.buffer - containing the encoded message.bufferIndex - at which the variable data begins.length - of the variable data in bytes.typeToken - of the variable data. Specifically needed to determine character encoding of the variable data.Copyright © 2013 Real Logic Ltd. All Rights Reserved.