Many resources are needed to download a project. Please understand that we have to compensate our server costs. Thank you in advance. Project price only 1 $
You can buy this project and download/modify it how often you want.
/* Generated SBE (Simple Binary Encoding) message codec. */
package b3.entrypoint.fixp.sbe;
import org.agrona.MutableDirectBuffer;
import org.agrona.DirectBuffer;
import org.agrona.sbe.*;
/**
* OrderMassActionReport message is used to acknowledge an OrderMassActionRequest message.
*/
@SuppressWarnings("all")
public final class OrderMassActionReportDecoder implements MessageDecoderFlyweight
{
public static final int BLOCK_LENGTH = 42;
public static final int TEMPLATE_ID = 702;
public static final int SCHEMA_ID = 1;
public static final int SCHEMA_VERSION = 5;
public static final String SEMANTIC_VERSION = "5.6";
public static final java.nio.ByteOrder BYTE_ORDER = java.nio.ByteOrder.LITTLE_ENDIAN;
private final OrderMassActionReportDecoder parentMessage = this;
private DirectBuffer buffer;
private int offset;
private int limit;
int actingBlockLength;
int actingVersion;
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 DirectBuffer buffer()
{
return buffer;
}
public int offset()
{
return offset;
}
public OrderMassActionReportDecoder wrap(
final DirectBuffer buffer,
final int offset,
final int actingBlockLength,
final int actingVersion)
{
if (buffer != this.buffer)
{
this.buffer = buffer;
}
this.offset = offset;
this.actingBlockLength = actingBlockLength;
this.actingVersion = actingVersion;
limit(offset + actingBlockLength);
return this;
}
public OrderMassActionReportDecoder wrapAndApplyHeader(
final DirectBuffer buffer,
final int offset,
final MessageHeaderDecoder headerDecoder)
{
headerDecoder.wrap(buffer, offset);
final int templateId = headerDecoder.templateId();
if (TEMPLATE_ID != templateId)
{
throw new IllegalStateException("Invalid TEMPLATE_ID: " + templateId);
}
return wrap(
buffer,
offset + MessageHeaderDecoder.ENCODED_LENGTH,
headerDecoder.blockLength(),
headerDecoder.version());
}
public OrderMassActionReportDecoder sbeRewind()
{
return wrap(buffer, offset, actingBlockLength, actingVersion);
}
public int sbeDecodedLength()
{
final int currentLimit = limit();
sbeSkip();
final int decodedLength = encodedLength();
limit(currentLimit);
return decodedLength;
}
public int actingVersion()
{
return actingVersion;
}
public int encodedLength()
{
return limit - offset;
}
public int limit()
{
return limit;
}
public void limit(final int limit)
{
this.limit = limit;
}
public static int messageTypeId()
{
return 35;
}
public static int messageTypeSinceVersion()
{
return 0;
}
public static int messageTypeEncodingOffset()
{
return 0;
}
public static int messageTypeEncodingLength()
{
return 1;
}
public static String messageTypeMetaAttribute(final MetaAttribute metaAttribute)
{
if (MetaAttribute.PRESENCE == metaAttribute)
{
return "constant";
}
return "";
}
public short messageTypeRaw()
{
return MessageType.OrderMassActionReport.value();
}
public MessageType messageType()
{
return MessageType.OrderMassActionReport;
}
public static int massActionReportIDId()
{
return 1369;
}
public static int massActionReportIDSinceVersion()
{
return 0;
}
public static int massActionReportIDEncodingOffset()
{
return 0;
}
public static int massActionReportIDEncodingLength()
{
return 8;
}
public static String massActionReportIDMetaAttribute(final MetaAttribute metaAttribute)
{
if (MetaAttribute.PRESENCE == metaAttribute)
{
return "required";
}
return "";
}
public static long massActionReportIDNullValue()
{
return 0xffffffffffffffffL;
}
public static long massActionReportIDMinValue()
{
return 0x0L;
}
public static long massActionReportIDMaxValue()
{
return 0xfffffffffffffffeL;
}
public long massActionReportID()
{
return buffer.getLong(offset + 0, BYTE_ORDER);
}
public static int clOrdIDId()
{
return 11;
}
public static int clOrdIDSinceVersion()
{
return 0;
}
public static int clOrdIDEncodingOffset()
{
return 8;
}
public static int clOrdIDEncodingLength()
{
return 8;
}
public static String clOrdIDMetaAttribute(final MetaAttribute metaAttribute)
{
if (MetaAttribute.PRESENCE == metaAttribute)
{
return "required";
}
return "";
}
public static long clOrdIDNullValue()
{
return 0xffffffffffffffffL;
}
public static long clOrdIDMinValue()
{
return 0x0L;
}
public static long clOrdIDMaxValue()
{
return 0xfffffffffffffffeL;
}
public long clOrdID()
{
return buffer.getLong(offset + 8, BYTE_ORDER);
}
public static int transactTimeId()
{
return 60;
}
public static int transactTimeSinceVersion()
{
return 0;
}
public static int transactTimeEncodingOffset()
{
return 16;
}
public static int transactTimeEncodingLength()
{
return 8;
}
public static String transactTimeMetaAttribute(final MetaAttribute metaAttribute)
{
if (MetaAttribute.PRESENCE == metaAttribute)
{
return "required";
}
return "";
}
private final UTCTimestampNanosDecoder transactTime = new UTCTimestampNanosDecoder();
/**
* Time of execution/order creation; expressed in UTC.
*
* @return UTCTimestampNanosDecoder : Time of execution/order creation; expressed in UTC.
*/
public UTCTimestampNanosDecoder transactTime()
{
transactTime.wrap(buffer, offset + 16);
return transactTime;
}
public static int massActionResponseId()
{
return 1375;
}
public static int massActionResponseSinceVersion()
{
return 0;
}
public static int massActionResponseEncodingOffset()
{
return 24;
}
public static int massActionResponseEncodingLength()
{
return 1;
}
public static String massActionResponseMetaAttribute(final MetaAttribute metaAttribute)
{
if (MetaAttribute.PRESENCE == metaAttribute)
{
return "required";
}
return "";
}
public short massActionResponseRaw()
{
return ((short)(buffer.getByte(offset + 24) & 0xFF));
}
public MassActionResponse massActionResponse()
{
return MassActionResponse.get(((short)(buffer.getByte(offset + 24) & 0xFF)));
}
public static int massActionScopeId()
{
return 1374;
}
public static int massActionScopeSinceVersion()
{
return 0;
}
public static int massActionScopeEncodingOffset()
{
return 25;
}
public static int massActionScopeEncodingLength()
{
return 1;
}
public static String massActionScopeMetaAttribute(final MetaAttribute metaAttribute)
{
if (MetaAttribute.PRESENCE == metaAttribute)
{
return "required";
}
return "";
}
public short massActionScopeRaw()
{
return ((short)(buffer.getByte(offset + 25) & 0xFF));
}
public MassActionScope massActionScope()
{
return MassActionScope.get(((short)(buffer.getByte(offset + 25) & 0xFF)));
}
public static int massActionTypeId()
{
return 1373;
}
public static int massActionTypeSinceVersion()
{
return 0;
}
public static int massActionTypeEncodingOffset()
{
return 26;
}
public static int massActionTypeEncodingLength()
{
return 1;
}
public static String massActionTypeMetaAttribute(final MetaAttribute metaAttribute)
{
if (MetaAttribute.PRESENCE == metaAttribute)
{
return "constant";
}
return "";
}
public short massActionTypeRaw()
{
return MassActionType.CANCEL_ORDERS.value();
}
public MassActionType massActionType()
{
return MassActionType.CANCEL_ORDERS;
}
public static int execRestatementReasonId()
{
return 378;
}
public static int execRestatementReasonSinceVersion()
{
return 0;
}
public static int execRestatementReasonEncodingOffset()
{
return 26;
}
public static int execRestatementReasonEncodingLength()
{
return 1;
}
public static String execRestatementReasonMetaAttribute(final MetaAttribute metaAttribute)
{
if (MetaAttribute.PRESENCE == metaAttribute)
{
return "required";
}
return "";
}
public short execRestatementReasonRaw()
{
return ((short)(buffer.getByte(offset + 26) & 0xFF));
}
public ExecRestatementReason execRestatementReason()
{
return ExecRestatementReason.get(((short)(buffer.getByte(offset + 26) & 0xFF)));
}
public static int massActionRejectReasonId()
{
return 1376;
}
public static int massActionRejectReasonSinceVersion()
{
return 0;
}
public static int massActionRejectReasonEncodingOffset()
{
return 27;
}
public static int massActionRejectReasonEncodingLength()
{
return 1;
}
public static String massActionRejectReasonMetaAttribute(final MetaAttribute metaAttribute)
{
if (MetaAttribute.PRESENCE == metaAttribute)
{
return "optional";
}
return "";
}
public short massActionRejectReasonRaw()
{
return ((short)(buffer.getByte(offset + 27) & 0xFF));
}
public MassActionRejectReason massActionRejectReason()
{
return MassActionRejectReason.get(((short)(buffer.getByte(offset + 27) & 0xFF)));
}
public static int ordTagIDId()
{
return 35505;
}
public static int ordTagIDSinceVersion()
{
return 0;
}
public static int ordTagIDEncodingOffset()
{
return 28;
}
public static int ordTagIDEncodingLength()
{
return 1;
}
public static String ordTagIDMetaAttribute(final MetaAttribute metaAttribute)
{
if (MetaAttribute.PRESENCE == metaAttribute)
{
return "optional";
}
return "";
}
public static short ordTagIDNullValue()
{
return (short)0;
}
public static short ordTagIDMinValue()
{
return (short)0;
}
public static short ordTagIDMaxValue()
{
return (short)254;
}
public short ordTagID()
{
return ((short)(buffer.getByte(offset + 28) & 0xFF));
}
public static int sideId()
{
return 54;
}
public static int sideSinceVersion()
{
return 0;
}
public static int sideEncodingOffset()
{
return 29;
}
public static int sideEncodingLength()
{
return 1;
}
public static String sideMetaAttribute(final MetaAttribute metaAttribute)
{
if (MetaAttribute.PRESENCE == metaAttribute)
{
return "optional";
}
return "";
}
public byte sideRaw()
{
return buffer.getByte(offset + 29);
}
public Side side()
{
return Side.get(buffer.getByte(offset + 29));
}
public static int securityIDId()
{
return 48;
}
public static int securityIDSinceVersion()
{
return 0;
}
public static int securityIDEncodingOffset()
{
return 30;
}
public static int securityIDEncodingLength()
{
return 8;
}
public static String securityIDMetaAttribute(final MetaAttribute metaAttribute)
{
if (MetaAttribute.PRESENCE == metaAttribute)
{
return "optional";
}
return "";
}
public static long securityIDNullValue()
{
return 0x0L;
}
public static long securityIDMinValue()
{
return 0x0L;
}
public static long securityIDMaxValue()
{
return 0xfffffffffffffffeL;
}
public long securityID()
{
return buffer.getLong(offset + 30, BYTE_ORDER);
}
public static int securityIDSourceId()
{
return 22;
}
public static int securityIDSourceSinceVersion()
{
return 0;
}
public static int securityIDSourceEncodingOffset()
{
return 38;
}
public static int securityIDSourceEncodingLength()
{
return 0;
}
public static String securityIDSourceMetaAttribute(final MetaAttribute metaAttribute)
{
if (MetaAttribute.PRESENCE == metaAttribute)
{
return "constant";
}
return "";
}
public static byte securityIDSourceNullValue()
{
return (byte)0;
}
public static byte securityIDSourceMinValue()
{
return (byte)32;
}
public static byte securityIDSourceMaxValue()
{
return (byte)126;
}
private static final byte[] SECURITYIDSOURCE_VALUE = { 56 };
public static int securityIDSourceLength()
{
return 1;
}
public byte securityIDSource(final int index)
{
return SECURITYIDSOURCE_VALUE[index];
}
public int getSecurityIDSource(final byte[] dst, final int offset, final int length)
{
final int bytesCopied = Math.min(length, 1);
System.arraycopy(SECURITYIDSOURCE_VALUE, 0, dst, offset, bytesCopied);
return bytesCopied;
}
public byte securityIDSource()
{
return (byte)56;
}
public static int securityExchangeId()
{
return 207;
}
public static int securityExchangeSinceVersion()
{
return 0;
}
public static int securityExchangeEncodingOffset()
{
return 38;
}
public static int securityExchangeEncodingLength()
{
return 0;
}
public static String securityExchangeMetaAttribute(final MetaAttribute metaAttribute)
{
if (MetaAttribute.PRESENCE == metaAttribute)
{
return "constant";
}
return "";
}
public static byte securityExchangeNullValue()
{
return (byte)0;
}
public static byte securityExchangeMinValue()
{
return (byte)32;
}
public static byte securityExchangeMaxValue()
{
return (byte)126;
}
private static final byte[] SECURITYEXCHANGE_VALUE = { 66, 86, 77, 70 };
public static int securityExchangeLength()
{
return 4;
}
public byte securityExchange(final int index)
{
return SECURITYEXCHANGE_VALUE[index];
}
public int getSecurityExchange(final byte[] dst, final int offset, final int length)
{
final int bytesCopied = Math.min(length, 4);
System.arraycopy(SECURITYEXCHANGE_VALUE, 0, dst, offset, bytesCopied);
return bytesCopied;
}
public String securityExchange()
{
return "BVMF";
}
public static int securityGroupId()
{
return 1151;
}
public static int securityGroupSinceVersion()
{
return 0;
}
public static int securityGroupEncodingOffset()
{
return 38;
}
public static int securityGroupEncodingLength()
{
return 3;
}
public static String securityGroupMetaAttribute(final MetaAttribute metaAttribute)
{
if (MetaAttribute.PRESENCE == metaAttribute)
{
return "optional";
}
return "";
}
public static byte securityGroupNullValue()
{
return (byte)0;
}
public static byte securityGroupMinValue()
{
return (byte)32;
}
public static byte securityGroupMaxValue()
{
return (byte)126;
}
public static int securityGroupLength()
{
return 3;
}
public byte securityGroup(final int index)
{
if (index < 0 || index >= 3)
{
throw new IndexOutOfBoundsException("index out of range: index=" + index);
}
final int pos = offset + 38 + (index * 1);
return buffer.getByte(pos);
}
public static String securityGroupCharacterEncoding()
{
return java.nio.charset.StandardCharsets.US_ASCII.name();
}
public int getSecurityGroup(final byte[] dst, final int dstOffset)
{
final int length = 3;
if (dstOffset < 0 || dstOffset > (dst.length - length))
{
throw new IndexOutOfBoundsException("Copy will go out of range: offset=" + dstOffset);
}
buffer.getBytes(offset + 38, dst, dstOffset, length);
return length;
}
public String securityGroup()
{
final byte[] dst = new byte[3];
buffer.getBytes(offset + 38, dst, 0, 3);
int end = 0;
for (; end < 3 && dst[end] != 0; ++end);
return new String(dst, 0, end, java.nio.charset.StandardCharsets.US_ASCII);
}
public int getSecurityGroup(final Appendable value)
{
for (int i = 0; i < 3; ++i)
{
final int c = buffer.getByte(offset + 38 + i) & 0xFF;
if (c == 0)
{
return i;
}
try
{
value.append(c > 127 ? '?' : (char)c);
}
catch (final java.io.IOException ex)
{
throw new java.io.UncheckedIOException(ex);
}
}
return 3;
}
public static int possResendId()
{
return 97;
}
public static int possResendSinceVersion()
{
return 0;
}
public static int possResendEncodingOffset()
{
return 41;
}
public static int possResendEncodingLength()
{
return 1;
}
public static String possResendMetaAttribute(final MetaAttribute metaAttribute)
{
if (MetaAttribute.PRESENCE == metaAttribute)
{
return "required";
}
return "";
}
public short possResendRaw()
{
return ((short)(buffer.getByte(offset + 41) & 0xFF));
}
public Boolean possResend()
{
return Boolean.get(((short)(buffer.getByte(offset + 41) & 0xFF)));
}
public static int textId()
{
return 58;
}
public static int textSinceVersion()
{
return 0;
}
public static String textCharacterEncoding()
{
return java.nio.charset.StandardCharsets.US_ASCII.name();
}
public static String textMetaAttribute(final MetaAttribute metaAttribute)
{
if (MetaAttribute.PRESENCE == metaAttribute)
{
return "required";
}
if (MetaAttribute.SEMANTIC_TYPE == metaAttribute)
{
return "String";
}
return "";
}
public static int textHeaderLength()
{
return 1;
}
public int textLength()
{
final int limit = parentMessage.limit();
return ((short)(buffer.getByte(limit) & 0xFF));
}
public int skipText()
{
final int headerLength = 1;
final int limit = parentMessage.limit();
final int dataLength = ((short)(buffer.getByte(limit) & 0xFF));
final int dataOffset = limit + headerLength;
parentMessage.limit(dataOffset + dataLength);
return dataLength;
}
public int getText(final MutableDirectBuffer dst, final int dstOffset, final int length)
{
final int headerLength = 1;
final int limit = parentMessage.limit();
final int dataLength = ((short)(buffer.getByte(limit) & 0xFF));
final int bytesCopied = Math.min(length, dataLength);
parentMessage.limit(limit + headerLength + dataLength);
buffer.getBytes(limit + headerLength, dst, dstOffset, bytesCopied);
return bytesCopied;
}
public int getText(final byte[] dst, final int dstOffset, final int length)
{
final int headerLength = 1;
final int limit = parentMessage.limit();
final int dataLength = ((short)(buffer.getByte(limit) & 0xFF));
final int bytesCopied = Math.min(length, dataLength);
parentMessage.limit(limit + headerLength + dataLength);
buffer.getBytes(limit + headerLength, dst, dstOffset, bytesCopied);
return bytesCopied;
}
public void wrapText(final DirectBuffer wrapBuffer)
{
final int headerLength = 1;
final int limit = parentMessage.limit();
final int dataLength = ((short)(buffer.getByte(limit) & 0xFF));
parentMessage.limit(limit + headerLength + dataLength);
wrapBuffer.wrap(buffer, limit + headerLength, dataLength);
}
public String text()
{
final int headerLength = 1;
final int limit = parentMessage.limit();
final int dataLength = ((short)(buffer.getByte(limit) & 0xFF));
parentMessage.limit(limit + headerLength + dataLength);
if (0 == dataLength)
{
return "";
}
final byte[] tmp = new byte[dataLength];
buffer.getBytes(limit + headerLength, tmp, 0, dataLength);
return new String(tmp, java.nio.charset.StandardCharsets.US_ASCII);
}
public int getText(final Appendable appendable)
{
final int headerLength = 1;
final int limit = parentMessage.limit();
final int dataLength = ((short)(buffer.getByte(limit) & 0xFF));
final int dataOffset = limit + headerLength;
parentMessage.limit(dataOffset + dataLength);
buffer.getStringWithoutLengthAscii(dataOffset, dataLength, appendable);
return dataLength;
}
public String toString()
{
if (null == buffer)
{
return "";
}
final OrderMassActionReportDecoder decoder = new OrderMassActionReportDecoder();
decoder.wrap(buffer, offset, actingBlockLength, actingVersion);
return decoder.appendTo(new StringBuilder()).toString();
}
public StringBuilder appendTo(final StringBuilder builder)
{
if (null == buffer)
{
return builder;
}
final int originalLimit = limit();
limit(offset + actingBlockLength);
builder.append("[OrderMassActionReport](sbeTemplateId=");
builder.append(TEMPLATE_ID);
builder.append("|sbeSchemaId=");
builder.append(SCHEMA_ID);
builder.append("|sbeSchemaVersion=");
if (parentMessage.actingVersion != SCHEMA_VERSION)
{
builder.append(parentMessage.actingVersion);
builder.append('/');
}
builder.append(SCHEMA_VERSION);
builder.append("|sbeBlockLength=");
if (actingBlockLength != BLOCK_LENGTH)
{
builder.append(actingBlockLength);
builder.append('/');
}
builder.append(BLOCK_LENGTH);
builder.append("):");
builder.append("messageType=");
builder.append(this.messageType());
builder.append('|');
builder.append("massActionReportID=");
builder.append(this.massActionReportID());
builder.append('|');
builder.append("clOrdID=");
builder.append(this.clOrdID());
builder.append('|');
builder.append("transactTime=");
final UTCTimestampNanosDecoder transactTime = this.transactTime();
if (null != transactTime)
{
transactTime.appendTo(builder);
}
else
{
builder.append("null");
}
builder.append('|');
builder.append("massActionResponse=");
builder.append(this.massActionResponse());
builder.append('|');
builder.append("massActionScope=");
builder.append(this.massActionScope());
builder.append('|');
builder.append("massActionType=");
builder.append(this.massActionType());
builder.append('|');
builder.append("execRestatementReason=");
builder.append(this.execRestatementReason());
builder.append('|');
builder.append("massActionRejectReason=");
builder.append(this.massActionRejectReason());
builder.append('|');
builder.append("ordTagID=");
builder.append(this.ordTagID());
builder.append('|');
builder.append("side=");
builder.append(this.side());
builder.append('|');
builder.append("securityID=");
builder.append(this.securityID());
builder.append('|');
builder.append("securityGroup=");
for (int i = 0; i < securityGroupLength() && this.securityGroup(i) > 0; i++)
{
builder.append((char)this.securityGroup(i));
}
builder.append('|');
builder.append("possResend=");
builder.append(this.possResend());
builder.append('|');
builder.append("text=");
builder.append('\'');
getText(builder);
builder.append('\'');
limit(originalLimit);
return builder;
}
public OrderMassActionReportDecoder sbeSkip()
{
sbeRewind();
skipText();
return this;
}
}