uk.co.real_logic.artio.messages.ManageSessionEncoder Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of artio-codecs Show documentation
Show all versions of artio-codecs Show documentation
High-Performance FIX Gateway
/* Generated SBE (Simple Binary Encoding) message codec. */
package uk.co.real_logic.artio.messages;
import org.agrona.MutableDirectBuffer;
import org.agrona.DirectBuffer;
/**
* Any event to manage a session from gateway to library
*/
@SuppressWarnings("all")
public final class ManageSessionEncoder
{
public static final int BLOCK_LENGTH = 104;
public static final int TEMPLATE_ID = 8;
public static final int SCHEMA_ID = 666;
public static final int SCHEMA_VERSION = 25;
public static final String SEMANTIC_VERSION = "0.2";
public static final java.nio.ByteOrder BYTE_ORDER = java.nio.ByteOrder.LITTLE_ENDIAN;
private final ManageSessionEncoder parentMessage = this;
private MutableDirectBuffer buffer;
private int offset;
private int limit;
public int sbeBlockLength()
{
return BLOCK_LENGTH;
}
public int sbeTemplateId()
{
return TEMPLATE_ID;
}
public int sbeSchemaId()
{
return SCHEMA_ID;
}
public int sbeSchemaVersion()
{
return SCHEMA_VERSION;
}
public String sbeSemanticType()
{
return "";
}
public MutableDirectBuffer buffer()
{
return buffer;
}
public int offset()
{
return offset;
}
public ManageSessionEncoder wrap(final MutableDirectBuffer buffer, final int offset)
{
if (buffer != this.buffer)
{
this.buffer = buffer;
}
this.offset = offset;
limit(offset + BLOCK_LENGTH);
return this;
}
public ManageSessionEncoder wrapAndApplyHeader(
final MutableDirectBuffer buffer, final int offset, final MessageHeaderEncoder headerEncoder)
{
headerEncoder
.wrap(buffer, offset)
.blockLength(BLOCK_LENGTH)
.templateId(TEMPLATE_ID)
.schemaId(SCHEMA_ID)
.version(SCHEMA_VERSION);
return wrap(buffer, offset + MessageHeaderEncoder.ENCODED_LENGTH);
}
public int encodedLength()
{
return limit - offset;
}
public int limit()
{
return limit;
}
public void limit(final int limit)
{
this.limit = limit;
}
public static int libraryIdId()
{
return 1;
}
public static int libraryIdSinceVersion()
{
return 0;
}
public static int libraryIdEncodingOffset()
{
return 0;
}
public static int libraryIdEncodingLength()
{
return 4;
}
public static String libraryIdMetaAttribute(final MetaAttribute metaAttribute)
{
if (MetaAttribute.PRESENCE == metaAttribute)
{
return "required";
}
return "";
}
public static int libraryIdNullValue()
{
return -2147483648;
}
public static int libraryIdMinValue()
{
return -2147483647;
}
public static int libraryIdMaxValue()
{
return 2147483647;
}
public ManageSessionEncoder libraryId(final int value)
{
buffer.putInt(offset + 0, value, BYTE_ORDER);
return this;
}
public static int connectionId()
{
return 2;
}
public static int connectionSinceVersion()
{
return 0;
}
public static int connectionEncodingOffset()
{
return 4;
}
public static int connectionEncodingLength()
{
return 8;
}
public static String connectionMetaAttribute(final MetaAttribute metaAttribute)
{
if (MetaAttribute.PRESENCE == metaAttribute)
{
return "required";
}
return "";
}
public static long connectionNullValue()
{
return -9223372036854775808L;
}
public static long connectionMinValue()
{
return -9223372036854775807L;
}
public static long connectionMaxValue()
{
return 9223372036854775807L;
}
public ManageSessionEncoder connection(final long value)
{
buffer.putLong(offset + 4, value, BYTE_ORDER);
return this;
}
public static int sessionId()
{
return 3;
}
public static int sessionSinceVersion()
{
return 0;
}
public static int sessionEncodingOffset()
{
return 12;
}
public static int sessionEncodingLength()
{
return 8;
}
public static String sessionMetaAttribute(final MetaAttribute metaAttribute)
{
if (MetaAttribute.PRESENCE == metaAttribute)
{
return "required";
}
return "";
}
public static long sessionNullValue()
{
return -9223372036854775808L;
}
public static long sessionMinValue()
{
return -9223372036854775807L;
}
public static long sessionMaxValue()
{
return 9223372036854775807L;
}
public ManageSessionEncoder session(final long value)
{
buffer.putLong(offset + 12, value, BYTE_ORDER);
return this;
}
public static int lastSentSequenceNumberId()
{
return 4;
}
public static int lastSentSequenceNumberSinceVersion()
{
return 0;
}
public static int lastSentSequenceNumberEncodingOffset()
{
return 20;
}
public static int lastSentSequenceNumberEncodingLength()
{
return 4;
}
public static String lastSentSequenceNumberMetaAttribute(final MetaAttribute metaAttribute)
{
if (MetaAttribute.PRESENCE == metaAttribute)
{
return "required";
}
return "";
}
public static int lastSentSequenceNumberNullValue()
{
return -2147483648;
}
public static int lastSentSequenceNumberMinValue()
{
return -2147483647;
}
public static int lastSentSequenceNumberMaxValue()
{
return 2147483647;
}
public ManageSessionEncoder lastSentSequenceNumber(final int value)
{
buffer.putInt(offset + 20, value, BYTE_ORDER);
return this;
}
public static int lastReceivedSequenceNumberId()
{
return 5;
}
public static int lastReceivedSequenceNumberSinceVersion()
{
return 0;
}
public static int lastReceivedSequenceNumberEncodingOffset()
{
return 24;
}
public static int lastReceivedSequenceNumberEncodingLength()
{
return 4;
}
public static String lastReceivedSequenceNumberMetaAttribute(final MetaAttribute metaAttribute)
{
if (MetaAttribute.PRESENCE == metaAttribute)
{
return "required";
}
return "";
}
public static int lastReceivedSequenceNumberNullValue()
{
return -2147483648;
}
public static int lastReceivedSequenceNumberMinValue()
{
return -2147483647;
}
public static int lastReceivedSequenceNumberMaxValue()
{
return 2147483647;
}
public ManageSessionEncoder lastReceivedSequenceNumber(final int value)
{
buffer.putInt(offset + 24, value, BYTE_ORDER);
return this;
}
public static int sessionStatusId()
{
return 7;
}
public static int sessionStatusSinceVersion()
{
return 0;
}
public static int sessionStatusEncodingOffset()
{
return 28;
}
public static int sessionStatusEncodingLength()
{
return 1;
}
public static String sessionStatusMetaAttribute(final MetaAttribute metaAttribute)
{
if (MetaAttribute.PRESENCE == metaAttribute)
{
return "required";
}
return "";
}
public ManageSessionEncoder sessionStatus(final SessionStatus value)
{
buffer.putByte(offset + 28, (byte)value.value());
return this;
}
public static int slowStatusId()
{
return 8;
}
public static int slowStatusSinceVersion()
{
return 0;
}
public static int slowStatusEncodingOffset()
{
return 29;
}
public static int slowStatusEncodingLength()
{
return 1;
}
public static String slowStatusMetaAttribute(final MetaAttribute metaAttribute)
{
if (MetaAttribute.PRESENCE == metaAttribute)
{
return "required";
}
return "";
}
public ManageSessionEncoder slowStatus(final SlowStatus value)
{
buffer.putByte(offset + 29, (byte)value.value());
return this;
}
public static int connectionTypeId()
{
return 9;
}
public static int connectionTypeSinceVersion()
{
return 0;
}
public static int connectionTypeEncodingOffset()
{
return 30;
}
public static int connectionTypeEncodingLength()
{
return 1;
}
public static String connectionTypeMetaAttribute(final MetaAttribute metaAttribute)
{
if (MetaAttribute.PRESENCE == metaAttribute)
{
return "required";
}
return "";
}
public ManageSessionEncoder connectionType(final ConnectionType value)
{
buffer.putByte(offset + 30, (byte)value.value());
return this;
}
public static int sessionStateId()
{
return 10;
}
public static int sessionStateSinceVersion()
{
return 0;
}
public static int sessionStateEncodingOffset()
{
return 31;
}
public static int sessionStateEncodingLength()
{
return 1;
}
public static String sessionStateMetaAttribute(final MetaAttribute metaAttribute)
{
if (MetaAttribute.PRESENCE == metaAttribute)
{
return "required";
}
return "";
}
public ManageSessionEncoder sessionState(final SessionState value)
{
buffer.putByte(offset + 31, (byte)value.value());
return this;
}
public static int heartbeatIntervalInSId()
{
return 11;
}
public static int heartbeatIntervalInSSinceVersion()
{
return 0;
}
public static int heartbeatIntervalInSEncodingOffset()
{
return 32;
}
public static int heartbeatIntervalInSEncodingLength()
{
return 4;
}
public static String heartbeatIntervalInSMetaAttribute(final MetaAttribute metaAttribute)
{
if (MetaAttribute.PRESENCE == metaAttribute)
{
return "required";
}
return "";
}
public static int heartbeatIntervalInSNullValue()
{
return -2147483648;
}
public static int heartbeatIntervalInSMinValue()
{
return -2147483647;
}
public static int heartbeatIntervalInSMaxValue()
{
return 2147483647;
}
public ManageSessionEncoder heartbeatIntervalInS(final int value)
{
buffer.putInt(offset + 32, value, BYTE_ORDER);
return this;
}
public static int replyToIdId()
{
return 12;
}
public static int replyToIdSinceVersion()
{
return 0;
}
public static int replyToIdEncodingOffset()
{
return 36;
}
public static int replyToIdEncodingLength()
{
return 8;
}
public static String replyToIdMetaAttribute(final MetaAttribute metaAttribute)
{
if (MetaAttribute.PRESENCE == metaAttribute)
{
return "required";
}
return "";
}
public static long replyToIdNullValue()
{
return -9223372036854775808L;
}
public static long replyToIdMinValue()
{
return -9223372036854775807L;
}
public static long replyToIdMaxValue()
{
return 9223372036854775807L;
}
public ManageSessionEncoder replyToId(final long value)
{
buffer.putLong(offset + 36, value, BYTE_ORDER);
return this;
}
public static int sequenceIndexId()
{
return 13;
}
public static int sequenceIndexSinceVersion()
{
return 0;
}
public static int sequenceIndexEncodingOffset()
{
return 44;
}
public static int sequenceIndexEncodingLength()
{
return 4;
}
public static String sequenceIndexMetaAttribute(final MetaAttribute metaAttribute)
{
if (MetaAttribute.PRESENCE == metaAttribute)
{
return "required";
}
return "";
}
public static int sequenceIndexNullValue()
{
return -2147483648;
}
public static int sequenceIndexMinValue()
{
return -2147483647;
}
public static int sequenceIndexMaxValue()
{
return 2147483647;
}
public ManageSessionEncoder sequenceIndex(final int value)
{
buffer.putInt(offset + 44, value, BYTE_ORDER);
return this;
}
public static int closedResendIntervalId()
{
return 22;
}
public static int closedResendIntervalSinceVersion()
{
return 0;
}
public static int closedResendIntervalEncodingOffset()
{
return 48;
}
public static int closedResendIntervalEncodingLength()
{
return 1;
}
public static String closedResendIntervalMetaAttribute(final MetaAttribute metaAttribute)
{
if (MetaAttribute.PRESENCE == metaAttribute)
{
return "required";
}
return "";
}
public ManageSessionEncoder closedResendInterval(final Bool value)
{
buffer.putByte(offset + 48, (byte)value.value());
return this;
}
public static int resendRequestChunkSizeId()
{
return 23;
}
public static int resendRequestChunkSizeSinceVersion()
{
return 0;
}
public static int resendRequestChunkSizeEncodingOffset()
{
return 49;
}
public static int resendRequestChunkSizeEncodingLength()
{
return 4;
}
public static String resendRequestChunkSizeMetaAttribute(final MetaAttribute metaAttribute)
{
if (MetaAttribute.PRESENCE == metaAttribute)
{
return "required";
}
return "";
}
public static int resendRequestChunkSizeNullValue()
{
return -2147483648;
}
public static int resendRequestChunkSizeMinValue()
{
return -2147483647;
}
public static int resendRequestChunkSizeMaxValue()
{
return 2147483647;
}
public ManageSessionEncoder resendRequestChunkSize(final int value)
{
buffer.putInt(offset + 49, value, BYTE_ORDER);
return this;
}
public static int sendRedundantResendRequestsId()
{
return 24;
}
public static int sendRedundantResendRequestsSinceVersion()
{
return 0;
}
public static int sendRedundantResendRequestsEncodingOffset()
{
return 53;
}
public static int sendRedundantResendRequestsEncodingLength()
{
return 1;
}
public static String sendRedundantResendRequestsMetaAttribute(final MetaAttribute metaAttribute)
{
if (MetaAttribute.PRESENCE == metaAttribute)
{
return "required";
}
return "";
}
public ManageSessionEncoder sendRedundantResendRequests(final Bool value)
{
buffer.putByte(offset + 53, (byte)value.value());
return this;
}
public static int enableLastMsgSeqNumProcessedId()
{
return 25;
}
public static int enableLastMsgSeqNumProcessedSinceVersion()
{
return 0;
}
public static int enableLastMsgSeqNumProcessedEncodingOffset()
{
return 54;
}
public static int enableLastMsgSeqNumProcessedEncodingLength()
{
return 1;
}
public static String enableLastMsgSeqNumProcessedMetaAttribute(final MetaAttribute metaAttribute)
{
if (MetaAttribute.PRESENCE == metaAttribute)
{
return "required";
}
return "";
}
public ManageSessionEncoder enableLastMsgSeqNumProcessed(final Bool value)
{
buffer.putByte(offset + 54, (byte)value.value());
return this;
}
public static int logonReceivedSequenceNumberId()
{
return 33;
}
public static int logonReceivedSequenceNumberSinceVersion()
{
return 4;
}
public static int logonReceivedSequenceNumberEncodingOffset()
{
return 55;
}
public static int logonReceivedSequenceNumberEncodingLength()
{
return 4;
}
public static String logonReceivedSequenceNumberMetaAttribute(final MetaAttribute metaAttribute)
{
if (MetaAttribute.PRESENCE == metaAttribute)
{
return "required";
}
return "";
}
public static int logonReceivedSequenceNumberNullValue()
{
return -2147483648;
}
public static int logonReceivedSequenceNumberMinValue()
{
return -2147483647;
}
public static int logonReceivedSequenceNumberMaxValue()
{
return 2147483647;
}
public ManageSessionEncoder logonReceivedSequenceNumber(final int value)
{
buffer.putInt(offset + 55, value, BYTE_ORDER);
return this;
}
public static int logonSequenceIndexId()
{
return 34;
}
public static int logonSequenceIndexSinceVersion()
{
return 4;
}
public static int logonSequenceIndexEncodingOffset()
{
return 59;
}
public static int logonSequenceIndexEncodingLength()
{
return 4;
}
public static String logonSequenceIndexMetaAttribute(final MetaAttribute metaAttribute)
{
if (MetaAttribute.PRESENCE == metaAttribute)
{
return "required";
}
return "";
}
public static int logonSequenceIndexNullValue()
{
return -2147483648;
}
public static int logonSequenceIndexMinValue()
{
return -2147483647;
}
public static int logonSequenceIndexMaxValue()
{
return 2147483647;
}
public ManageSessionEncoder logonSequenceIndex(final int value)
{
buffer.putInt(offset + 59, value, BYTE_ORDER);
return this;
}
public static int metaDataStatusId()
{
return 35;
}
public static int metaDataStatusSinceVersion()
{
return 5;
}
public static int metaDataStatusEncodingOffset()
{
return 63;
}
public static int metaDataStatusEncodingLength()
{
return 1;
}
public static String metaDataStatusMetaAttribute(final MetaAttribute metaAttribute)
{
if (MetaAttribute.PRESENCE == metaAttribute)
{
return "required";
}
return "";
}
public ManageSessionEncoder metaDataStatus(final MetaDataStatus value)
{
buffer.putByte(offset + 63, (byte)value.value());
return this;
}
public static int cancelOnDisconnectOptionId()
{
return 38;
}
public static int cancelOnDisconnectOptionSinceVersion()
{
return 16;
}
public static int cancelOnDisconnectOptionEncodingOffset()
{
return 64;
}
public static int cancelOnDisconnectOptionEncodingLength()
{
return 2;
}
public static String cancelOnDisconnectOptionMetaAttribute(final MetaAttribute metaAttribute)
{
if (MetaAttribute.PRESENCE == metaAttribute)
{
return "required";
}
return "";
}
public ManageSessionEncoder cancelOnDisconnectOption(final CancelOnDisconnectOption value)
{
buffer.putShort(offset + 64, (short)value.value(), BYTE_ORDER);
return this;
}
public static int cancelOnDisconnectTimeoutInNsId()
{
return 39;
}
public static int cancelOnDisconnectTimeoutInNsSinceVersion()
{
return 16;
}
public static int cancelOnDisconnectTimeoutInNsEncodingOffset()
{
return 66;
}
public static int cancelOnDisconnectTimeoutInNsEncodingLength()
{
return 8;
}
public static String cancelOnDisconnectTimeoutInNsMetaAttribute(final MetaAttribute metaAttribute)
{
if (MetaAttribute.PRESENCE == metaAttribute)
{
return "required";
}
return "";
}
public static long cancelOnDisconnectTimeoutInNsNullValue()
{
return -9223372036854775808L;
}
public static long cancelOnDisconnectTimeoutInNsMinValue()
{
return -9223372036854775807L;
}
public static long cancelOnDisconnectTimeoutInNsMaxValue()
{
return 9223372036854775807L;
}
public ManageSessionEncoder cancelOnDisconnectTimeoutInNs(final long value)
{
buffer.putLong(offset + 66, value, BYTE_ORDER);
return this;
}
public static int awaitingResendId()
{
return 21;
}
public static int awaitingResendSinceVersion()
{
return 0;
}
public static int awaitingResendEncodingOffset()
{
return 74;
}
public static int awaitingResendEncodingLength()
{
return 1;
}
public static String awaitingResendMetaAttribute(final MetaAttribute metaAttribute)
{
if (MetaAttribute.PRESENCE == metaAttribute)
{
return "required";
}
return "";
}
public ManageSessionEncoder awaitingResend(final AwaitingResend value)
{
buffer.putByte(offset + 74, (byte)value.value());
return this;
}
public static int lastResentMsgSeqNoId()
{
return 28;
}
public static int lastResentMsgSeqNoSinceVersion()
{
return 1;
}
public static int lastResentMsgSeqNoEncodingOffset()
{
return 75;
}
public static int lastResentMsgSeqNoEncodingLength()
{
return 4;
}
public static String lastResentMsgSeqNoMetaAttribute(final MetaAttribute metaAttribute)
{
if (MetaAttribute.PRESENCE == metaAttribute)
{
return "optional";
}
return "";
}
public static int lastResentMsgSeqNoNullValue()
{
return -2147483648;
}
public static int lastResentMsgSeqNoMinValue()
{
return -2147483647;
}
public static int lastResentMsgSeqNoMaxValue()
{
return 2147483647;
}
public ManageSessionEncoder lastResentMsgSeqNo(final int value)
{
buffer.putInt(offset + 75, value, BYTE_ORDER);
return this;
}
public static int lastResendChunkMsgSeqNumId()
{
return 29;
}
public static int lastResendChunkMsgSeqNumSinceVersion()
{
return 1;
}
public static int lastResendChunkMsgSeqNumEncodingOffset()
{
return 79;
}
public static int lastResendChunkMsgSeqNumEncodingLength()
{
return 4;
}
public static String lastResendChunkMsgSeqNumMetaAttribute(final MetaAttribute metaAttribute)
{
if (MetaAttribute.PRESENCE == metaAttribute)
{
return "optional";
}
return "";
}
public static int lastResendChunkMsgSeqNumNullValue()
{
return -2147483648;
}
public static int lastResendChunkMsgSeqNumMinValue()
{
return -2147483647;
}
public static int lastResendChunkMsgSeqNumMaxValue()
{
return 2147483647;
}
public ManageSessionEncoder lastResendChunkMsgSeqNum(final int value)
{
buffer.putInt(offset + 79, value, BYTE_ORDER);
return this;
}
public static int endOfResendRequestRangeId()
{
return 30;
}
public static int endOfResendRequestRangeSinceVersion()
{
return 1;
}
public static int endOfResendRequestRangeEncodingOffset()
{
return 83;
}
public static int endOfResendRequestRangeEncodingLength()
{
return 4;
}
public static String endOfResendRequestRangeMetaAttribute(final MetaAttribute metaAttribute)
{
if (MetaAttribute.PRESENCE == metaAttribute)
{
return "optional";
}
return "";
}
public static int endOfResendRequestRangeNullValue()
{
return -2147483648;
}
public static int endOfResendRequestRangeMinValue()
{
return -2147483647;
}
public static int endOfResendRequestRangeMaxValue()
{
return 2147483647;
}
public ManageSessionEncoder endOfResendRequestRange(final int value)
{
buffer.putInt(offset + 83, value, BYTE_ORDER);
return this;
}
public static int awaitingHeartbeatId()
{
return 31;
}
public static int awaitingHeartbeatSinceVersion()
{
return 1;
}
public static int awaitingHeartbeatEncodingOffset()
{
return 87;
}
public static int awaitingHeartbeatEncodingLength()
{
return 1;
}
public static String awaitingHeartbeatMetaAttribute(final MetaAttribute metaAttribute)
{
if (MetaAttribute.PRESENCE == metaAttribute)
{
return "optional";
}
return "";
}
public ManageSessionEncoder awaitingHeartbeat(final Bool value)
{
buffer.putByte(offset + 87, (byte)value.value());
return this;
}
public static int lastLogonTimeId()
{
return 6;
}
public static int lastLogonTimeSinceVersion()
{
return 0;
}
public static int lastLogonTimeEncodingOffset()
{
return 88;
}
public static int lastLogonTimeEncodingLength()
{
return 8;
}
public static String lastLogonTimeMetaAttribute(final MetaAttribute metaAttribute)
{
if (MetaAttribute.PRESENCE == metaAttribute)
{
return "required";
}
return "";
}
public static long lastLogonTimeNullValue()
{
return -9223372036854775808L;
}
public static long lastLogonTimeMinValue()
{
return -9223372036854775807L;
}
public static long lastLogonTimeMaxValue()
{
return 9223372036854775807L;
}
public ManageSessionEncoder lastLogonTime(final long value)
{
buffer.putLong(offset + 88, value, BYTE_ORDER);
return this;
}
public static int lastSequenceResetTimeId()
{
return 37;
}
public static int lastSequenceResetTimeSinceVersion()
{
return 7;
}
public static int lastSequenceResetTimeEncodingOffset()
{
return 96;
}
public static int lastSequenceResetTimeEncodingLength()
{
return 8;
}
public static String lastSequenceResetTimeMetaAttribute(final MetaAttribute metaAttribute)
{
if (MetaAttribute.PRESENCE == metaAttribute)
{
return "optional";
}
return "";
}
public static long lastSequenceResetTimeNullValue()
{
return -9223372036854775808L;
}
public static long lastSequenceResetTimeMinValue()
{
return -9223372036854775807L;
}
public static long lastSequenceResetTimeMaxValue()
{
return 9223372036854775807L;
}
public ManageSessionEncoder lastSequenceResetTime(final long value)
{
buffer.putLong(offset + 96, value, BYTE_ORDER);
return this;
}
public static int localCompIdId()
{
return 14;
}
public static String localCompIdCharacterEncoding()
{
return java.nio.charset.StandardCharsets.UTF_8.name();
}
public static String localCompIdMetaAttribute(final MetaAttribute metaAttribute)
{
if (MetaAttribute.PRESENCE == metaAttribute)
{
return "required";
}
return "";
}
public static int localCompIdHeaderLength()
{
return 2;
}
public ManageSessionEncoder putLocalCompId(final DirectBuffer src, final int srcOffset, final int length)
{
if (length > 65534)
{
throw new IllegalStateException("length > maxValue for type: " + length);
}
final int headerLength = 2;
final int limit = parentMessage.limit();
parentMessage.limit(limit + headerLength + length);
buffer.putShort(limit, (short)length, BYTE_ORDER);
buffer.putBytes(limit + headerLength, src, srcOffset, length);
return this;
}
public ManageSessionEncoder putLocalCompId(final byte[] src, final int srcOffset, final int length)
{
if (length > 65534)
{
throw new IllegalStateException("length > maxValue for type: " + length);
}
final int headerLength = 2;
final int limit = parentMessage.limit();
parentMessage.limit(limit + headerLength + length);
buffer.putShort(limit, (short)length, BYTE_ORDER);
buffer.putBytes(limit + headerLength, src, srcOffset, length);
return this;
}
public ManageSessionEncoder localCompId(final String value)
{
final byte[] bytes = (null == value || value.isEmpty()) ? org.agrona.collections.ArrayUtil.EMPTY_BYTE_ARRAY : value.getBytes(java.nio.charset.StandardCharsets.UTF_8);
final int length = bytes.length;
if (length > 65534)
{
throw new IllegalStateException("length > maxValue for type: " + length);
}
final int headerLength = 2;
final int limit = parentMessage.limit();
parentMessage.limit(limit + headerLength + length);
buffer.putShort(limit, (short)length, BYTE_ORDER);
buffer.putBytes(limit + headerLength, bytes, 0, length);
return this;
}
public static int localSubIdId()
{
return 15;
}
public static String localSubIdCharacterEncoding()
{
return java.nio.charset.StandardCharsets.UTF_8.name();
}
public static String localSubIdMetaAttribute(final MetaAttribute metaAttribute)
{
if (MetaAttribute.PRESENCE == metaAttribute)
{
return "required";
}
return "";
}
public static int localSubIdHeaderLength()
{
return 2;
}
public ManageSessionEncoder putLocalSubId(final DirectBuffer src, final int srcOffset, final int length)
{
if (length > 65534)
{
throw new IllegalStateException("length > maxValue for type: " + length);
}
final int headerLength = 2;
final int limit = parentMessage.limit();
parentMessage.limit(limit + headerLength + length);
buffer.putShort(limit, (short)length, BYTE_ORDER);
buffer.putBytes(limit + headerLength, src, srcOffset, length);
return this;
}
public ManageSessionEncoder putLocalSubId(final byte[] src, final int srcOffset, final int length)
{
if (length > 65534)
{
throw new IllegalStateException("length > maxValue for type: " + length);
}
final int headerLength = 2;
final int limit = parentMessage.limit();
parentMessage.limit(limit + headerLength + length);
buffer.putShort(limit, (short)length, BYTE_ORDER);
buffer.putBytes(limit + headerLength, src, srcOffset, length);
return this;
}
public ManageSessionEncoder localSubId(final String value)
{
final byte[] bytes = (null == value || value.isEmpty()) ? org.agrona.collections.ArrayUtil.EMPTY_BYTE_ARRAY : value.getBytes(java.nio.charset.StandardCharsets.UTF_8);
final int length = bytes.length;
if (length > 65534)
{
throw new IllegalStateException("length > maxValue for type: " + length);
}
final int headerLength = 2;
final int limit = parentMessage.limit();
parentMessage.limit(limit + headerLength + length);
buffer.putShort(limit, (short)length, BYTE_ORDER);
buffer.putBytes(limit + headerLength, bytes, 0, length);
return this;
}
public static int localLocationIdId()
{
return 16;
}
public static String localLocationIdCharacterEncoding()
{
return java.nio.charset.StandardCharsets.UTF_8.name();
}
public static String localLocationIdMetaAttribute(final MetaAttribute metaAttribute)
{
if (MetaAttribute.PRESENCE == metaAttribute)
{
return "required";
}
return "";
}
public static int localLocationIdHeaderLength()
{
return 2;
}
public ManageSessionEncoder putLocalLocationId(final DirectBuffer src, final int srcOffset, final int length)
{
if (length > 65534)
{
throw new IllegalStateException("length > maxValue for type: " + length);
}
final int headerLength = 2;
final int limit = parentMessage.limit();
parentMessage.limit(limit + headerLength + length);
buffer.putShort(limit, (short)length, BYTE_ORDER);
buffer.putBytes(limit + headerLength, src, srcOffset, length);
return this;
}
public ManageSessionEncoder putLocalLocationId(final byte[] src, final int srcOffset, final int length)
{
if (length > 65534)
{
throw new IllegalStateException("length > maxValue for type: " + length);
}
final int headerLength = 2;
final int limit = parentMessage.limit();
parentMessage.limit(limit + headerLength + length);
buffer.putShort(limit, (short)length, BYTE_ORDER);
buffer.putBytes(limit + headerLength, src, srcOffset, length);
return this;
}
public ManageSessionEncoder localLocationId(final String value)
{
final byte[] bytes = (null == value || value.isEmpty()) ? org.agrona.collections.ArrayUtil.EMPTY_BYTE_ARRAY : value.getBytes(java.nio.charset.StandardCharsets.UTF_8);
final int length = bytes.length;
if (length > 65534)
{
throw new IllegalStateException("length > maxValue for type: " + length);
}
final int headerLength = 2;
final int limit = parentMessage.limit();
parentMessage.limit(limit + headerLength + length);
buffer.putShort(limit, (short)length, BYTE_ORDER);
buffer.putBytes(limit + headerLength, bytes, 0, length);
return this;
}
public static int remoteCompIdId()
{
return 17;
}
public static String remoteCompIdCharacterEncoding()
{
return java.nio.charset.StandardCharsets.UTF_8.name();
}
public static String remoteCompIdMetaAttribute(final MetaAttribute metaAttribute)
{
if (MetaAttribute.PRESENCE == metaAttribute)
{
return "required";
}
return "";
}
public static int remoteCompIdHeaderLength()
{
return 2;
}
public ManageSessionEncoder putRemoteCompId(final DirectBuffer src, final int srcOffset, final int length)
{
if (length > 65534)
{
throw new IllegalStateException("length > maxValue for type: " + length);
}
final int headerLength = 2;
final int limit = parentMessage.limit();
parentMessage.limit(limit + headerLength + length);
buffer.putShort(limit, (short)length, BYTE_ORDER);
buffer.putBytes(limit + headerLength, src, srcOffset, length);
return this;
}
public ManageSessionEncoder putRemoteCompId(final byte[] src, final int srcOffset, final int length)
{
if (length > 65534)
{
throw new IllegalStateException("length > maxValue for type: " + length);
}
final int headerLength = 2;
final int limit = parentMessage.limit();
parentMessage.limit(limit + headerLength + length);
buffer.putShort(limit, (short)length, BYTE_ORDER);
buffer.putBytes(limit + headerLength, src, srcOffset, length);
return this;
}
public ManageSessionEncoder remoteCompId(final String value)
{
final byte[] bytes = (null == value || value.isEmpty()) ? org.agrona.collections.ArrayUtil.EMPTY_BYTE_ARRAY : value.getBytes(java.nio.charset.StandardCharsets.UTF_8);
final int length = bytes.length;
if (length > 65534)
{
throw new IllegalStateException("length > maxValue for type: " + length);
}
final int headerLength = 2;
final int limit = parentMessage.limit();
parentMessage.limit(limit + headerLength + length);
buffer.putShort(limit, (short)length, BYTE_ORDER);
buffer.putBytes(limit + headerLength, bytes, 0, length);
return this;
}
public static int remoteSubIdId()
{
return 18;
}
public static String remoteSubIdCharacterEncoding()
{
return java.nio.charset.StandardCharsets.UTF_8.name();
}
public static String remoteSubIdMetaAttribute(final MetaAttribute metaAttribute)
{
if (MetaAttribute.PRESENCE == metaAttribute)
{
return "required";
}
return "";
}
public static int remoteSubIdHeaderLength()
{
return 2;
}
public ManageSessionEncoder putRemoteSubId(final DirectBuffer src, final int srcOffset, final int length)
{
if (length > 65534)
{
throw new IllegalStateException("length > maxValue for type: " + length);
}
final int headerLength = 2;
final int limit = parentMessage.limit();
parentMessage.limit(limit + headerLength + length);
buffer.putShort(limit, (short)length, BYTE_ORDER);
buffer.putBytes(limit + headerLength, src, srcOffset, length);
return this;
}
public ManageSessionEncoder putRemoteSubId(final byte[] src, final int srcOffset, final int length)
{
if (length > 65534)
{
throw new IllegalStateException("length > maxValue for type: " + length);
}
final int headerLength = 2;
final int limit = parentMessage.limit();
parentMessage.limit(limit + headerLength + length);
buffer.putShort(limit, (short)length, BYTE_ORDER);
buffer.putBytes(limit + headerLength, src, srcOffset, length);
return this;
}
public ManageSessionEncoder remoteSubId(final String value)
{
final byte[] bytes = (null == value || value.isEmpty()) ? org.agrona.collections.ArrayUtil.EMPTY_BYTE_ARRAY : value.getBytes(java.nio.charset.StandardCharsets.UTF_8);
final int length = bytes.length;
if (length > 65534)
{
throw new IllegalStateException("length > maxValue for type: " + length);
}
final int headerLength = 2;
final int limit = parentMessage.limit();
parentMessage.limit(limit + headerLength + length);
buffer.putShort(limit, (short)length, BYTE_ORDER);
buffer.putBytes(limit + headerLength, bytes, 0, length);
return this;
}
public static int remoteLocationIdId()
{
return 19;
}
public static String remoteLocationIdCharacterEncoding()
{
return java.nio.charset.StandardCharsets.UTF_8.name();
}
public static String remoteLocationIdMetaAttribute(final MetaAttribute metaAttribute)
{
if (MetaAttribute.PRESENCE == metaAttribute)
{
return "required";
}
return "";
}
public static int remoteLocationIdHeaderLength()
{
return 2;
}
public ManageSessionEncoder putRemoteLocationId(final DirectBuffer src, final int srcOffset, final int length)
{
if (length > 65534)
{
throw new IllegalStateException("length > maxValue for type: " + length);
}
final int headerLength = 2;
final int limit = parentMessage.limit();
parentMessage.limit(limit + headerLength + length);
buffer.putShort(limit, (short)length, BYTE_ORDER);
buffer.putBytes(limit + headerLength, src, srcOffset, length);
return this;
}
public ManageSessionEncoder putRemoteLocationId(final byte[] src, final int srcOffset, final int length)
{
if (length > 65534)
{
throw new IllegalStateException("length > maxValue for type: " + length);
}
final int headerLength = 2;
final int limit = parentMessage.limit();
parentMessage.limit(limit + headerLength + length);
buffer.putShort(limit, (short)length, BYTE_ORDER);
buffer.putBytes(limit + headerLength, src, srcOffset, length);
return this;
}
public ManageSessionEncoder remoteLocationId(final String value)
{
final byte[] bytes = (null == value || value.isEmpty()) ? org.agrona.collections.ArrayUtil.EMPTY_BYTE_ARRAY : value.getBytes(java.nio.charset.StandardCharsets.UTF_8);
final int length = bytes.length;
if (length > 65534)
{
throw new IllegalStateException("length > maxValue for type: " + length);
}
final int headerLength = 2;
final int limit = parentMessage.limit();
parentMessage.limit(limit + headerLength + length);
buffer.putShort(limit, (short)length, BYTE_ORDER);
buffer.putBytes(limit + headerLength, bytes, 0, length);
return this;
}
public static int addressId()
{
return 20;
}
public static String addressCharacterEncoding()
{
return java.nio.charset.StandardCharsets.UTF_8.name();
}
public static String addressMetaAttribute(final MetaAttribute metaAttribute)
{
if (MetaAttribute.PRESENCE == metaAttribute)
{
return "required";
}
return "";
}
public static int addressHeaderLength()
{
return 2;
}
public ManageSessionEncoder putAddress(final DirectBuffer src, final int srcOffset, final int length)
{
if (length > 65534)
{
throw new IllegalStateException("length > maxValue for type: " + length);
}
final int headerLength = 2;
final int limit = parentMessage.limit();
parentMessage.limit(limit + headerLength + length);
buffer.putShort(limit, (short)length, BYTE_ORDER);
buffer.putBytes(limit + headerLength, src, srcOffset, length);
return this;
}
public ManageSessionEncoder putAddress(final byte[] src, final int srcOffset, final int length)
{
if (length > 65534)
{
throw new IllegalStateException("length > maxValue for type: " + length);
}
final int headerLength = 2;
final int limit = parentMessage.limit();
parentMessage.limit(limit + headerLength + length);
buffer.putShort(limit, (short)length, BYTE_ORDER);
buffer.putBytes(limit + headerLength, src, srcOffset, length);
return this;
}
public ManageSessionEncoder address(final String value)
{
final byte[] bytes = (null == value || value.isEmpty()) ? org.agrona.collections.ArrayUtil.EMPTY_BYTE_ARRAY : value.getBytes(java.nio.charset.StandardCharsets.UTF_8);
final int length = bytes.length;
if (length > 65534)
{
throw new IllegalStateException("length > maxValue for type: " + length);
}
final int headerLength = 2;
final int limit = parentMessage.limit();
parentMessage.limit(limit + headerLength + length);
buffer.putShort(limit, (short)length, BYTE_ORDER);
buffer.putBytes(limit + headerLength, bytes, 0, length);
return this;
}
public static int usernameId()
{
return 26;
}
public static String usernameCharacterEncoding()
{
return java.nio.charset.StandardCharsets.UTF_8.name();
}
public static String usernameMetaAttribute(final MetaAttribute metaAttribute)
{
if (MetaAttribute.PRESENCE == metaAttribute)
{
return "required";
}
return "";
}
public static int usernameHeaderLength()
{
return 2;
}
public ManageSessionEncoder putUsername(final DirectBuffer src, final int srcOffset, final int length)
{
if (length > 65534)
{
throw new IllegalStateException("length > maxValue for type: " + length);
}
final int headerLength = 2;
final int limit = parentMessage.limit();
parentMessage.limit(limit + headerLength + length);
buffer.putShort(limit, (short)length, BYTE_ORDER);
buffer.putBytes(limit + headerLength, src, srcOffset, length);
return this;
}
public ManageSessionEncoder putUsername(final byte[] src, final int srcOffset, final int length)
{
if (length > 65534)
{
throw new IllegalStateException("length > maxValue for type: " + length);
}
final int headerLength = 2;
final int limit = parentMessage.limit();
parentMessage.limit(limit + headerLength + length);
buffer.putShort(limit, (short)length, BYTE_ORDER);
buffer.putBytes(limit + headerLength, src, srcOffset, length);
return this;
}
public ManageSessionEncoder username(final String value)
{
final byte[] bytes = (null == value || value.isEmpty()) ? org.agrona.collections.ArrayUtil.EMPTY_BYTE_ARRAY : value.getBytes(java.nio.charset.StandardCharsets.UTF_8);
final int length = bytes.length;
if (length > 65534)
{
throw new IllegalStateException("length > maxValue for type: " + length);
}
final int headerLength = 2;
final int limit = parentMessage.limit();
parentMessage.limit(limit + headerLength + length);
buffer.putShort(limit, (short)length, BYTE_ORDER);
buffer.putBytes(limit + headerLength, bytes, 0, length);
return this;
}
public static int passwordId()
{
return 27;
}
public static String passwordCharacterEncoding()
{
return java.nio.charset.StandardCharsets.UTF_8.name();
}
public static String passwordMetaAttribute(final MetaAttribute metaAttribute)
{
if (MetaAttribute.PRESENCE == metaAttribute)
{
return "required";
}
return "";
}
public static int passwordHeaderLength()
{
return 2;
}
public ManageSessionEncoder putPassword(final DirectBuffer src, final int srcOffset, final int length)
{
if (length > 65534)
{
throw new IllegalStateException("length > maxValue for type: " + length);
}
final int headerLength = 2;
final int limit = parentMessage.limit();
parentMessage.limit(limit + headerLength + length);
buffer.putShort(limit, (short)length, BYTE_ORDER);
buffer.putBytes(limit + headerLength, src, srcOffset, length);
return this;
}
public ManageSessionEncoder putPassword(final byte[] src, final int srcOffset, final int length)
{
if (length > 65534)
{
throw new IllegalStateException("length > maxValue for type: " + length);
}
final int headerLength = 2;
final int limit = parentMessage.limit();
parentMessage.limit(limit + headerLength + length);
buffer.putShort(limit, (short)length, BYTE_ORDER);
buffer.putBytes(limit + headerLength, src, srcOffset, length);
return this;
}
public ManageSessionEncoder password(final String value)
{
final byte[] bytes = (null == value || value.isEmpty()) ? org.agrona.collections.ArrayUtil.EMPTY_BYTE_ARRAY : value.getBytes(java.nio.charset.StandardCharsets.UTF_8);
final int length = bytes.length;
if (length > 65534)
{
throw new IllegalStateException("length > maxValue for type: " + length);
}
final int headerLength = 2;
final int limit = parentMessage.limit();
parentMessage.limit(limit + headerLength + length);
buffer.putShort(limit, (short)length, BYTE_ORDER);
buffer.putBytes(limit + headerLength, bytes, 0, length);
return this;
}
public static int fixDictionaryId()
{
return 32;
}
public static String fixDictionaryCharacterEncoding()
{
return java.nio.charset.StandardCharsets.UTF_8.name();
}
public static String fixDictionaryMetaAttribute(final MetaAttribute metaAttribute)
{
if (MetaAttribute.PRESENCE == metaAttribute)
{
return "required";
}
return "";
}
public static int fixDictionaryHeaderLength()
{
return 2;
}
public ManageSessionEncoder putFixDictionary(final DirectBuffer src, final int srcOffset, final int length)
{
if (length > 65534)
{
throw new IllegalStateException("length > maxValue for type: " + length);
}
final int headerLength = 2;
final int limit = parentMessage.limit();
parentMessage.limit(limit + headerLength + length);
buffer.putShort(limit, (short)length, BYTE_ORDER);
buffer.putBytes(limit + headerLength, src, srcOffset, length);
return this;
}
public ManageSessionEncoder putFixDictionary(final byte[] src, final int srcOffset, final int length)
{
if (length > 65534)
{
throw new IllegalStateException("length > maxValue for type: " + length);
}
final int headerLength = 2;
final int limit = parentMessage.limit();
parentMessage.limit(limit + headerLength + length);
buffer.putShort(limit, (short)length, BYTE_ORDER);
buffer.putBytes(limit + headerLength, src, srcOffset, length);
return this;
}
public ManageSessionEncoder fixDictionary(final String value)
{
final byte[] bytes = (null == value || value.isEmpty()) ? org.agrona.collections.ArrayUtil.EMPTY_BYTE_ARRAY : value.getBytes(java.nio.charset.StandardCharsets.UTF_8);
final int length = bytes.length;
if (length > 65534)
{
throw new IllegalStateException("length > maxValue for type: " + length);
}
final int headerLength = 2;
final int limit = parentMessage.limit();
parentMessage.limit(limit + headerLength + length);
buffer.putShort(limit, (short)length, BYTE_ORDER);
buffer.putBytes(limit + headerLength, bytes, 0, length);
return this;
}
public static int metaDataId()
{
return 36;
}
public static String metaDataCharacterEncoding()
{
return java.nio.charset.StandardCharsets.UTF_8.name();
}
public static String metaDataMetaAttribute(final MetaAttribute metaAttribute)
{
if (MetaAttribute.PRESENCE == metaAttribute)
{
return "required";
}
return "";
}
public static int metaDataHeaderLength()
{
return 2;
}
public ManageSessionEncoder putMetaData(final DirectBuffer src, final int srcOffset, final int length)
{
if (length > 65534)
{
throw new IllegalStateException("length > maxValue for type: " + length);
}
final int headerLength = 2;
final int limit = parentMessage.limit();
parentMessage.limit(limit + headerLength + length);
buffer.putShort(limit, (short)length, BYTE_ORDER);
buffer.putBytes(limit + headerLength, src, srcOffset, length);
return this;
}
public ManageSessionEncoder putMetaData(final byte[] src, final int srcOffset, final int length)
{
if (length > 65534)
{
throw new IllegalStateException("length > maxValue for type: " + length);
}
final int headerLength = 2;
final int limit = parentMessage.limit();
parentMessage.limit(limit + headerLength + length);
buffer.putShort(limit, (short)length, BYTE_ORDER);
buffer.putBytes(limit + headerLength, src, srcOffset, length);
return this;
}
public ManageSessionEncoder metaData(final String value)
{
final byte[] bytes = (null == value || value.isEmpty()) ? org.agrona.collections.ArrayUtil.EMPTY_BYTE_ARRAY : value.getBytes(java.nio.charset.StandardCharsets.UTF_8);
final int length = bytes.length;
if (length > 65534)
{
throw new IllegalStateException("length > maxValue for type: " + length);
}
final int headerLength = 2;
final int limit = parentMessage.limit();
parentMessage.limit(limit + headerLength + length);
buffer.putShort(limit, (short)length, BYTE_ORDER);
buffer.putBytes(limit + headerLength, bytes, 0, length);
return this;
}
public String toString()
{
if (null == buffer)
{
return "";
}
return appendTo(new StringBuilder()).toString();
}
public StringBuilder appendTo(final StringBuilder builder)
{
if (null == buffer)
{
return builder;
}
final ManageSessionDecoder decoder = new ManageSessionDecoder();
decoder.wrap(buffer, offset, BLOCK_LENGTH, SCHEMA_VERSION);
return decoder.appendTo(builder);
}
}