public final class MutableAsciiBuffer extends org.agrona.concurrent.UnsafeBuffer implements AsciiBuffer
ALIGNMENT, DISABLE_BOUNDS_CHECKS_PROP_NAME, SHOULD_BOUNDS_CHECKDOT_LENGTH, LONGEST_FLOAT_LENGTH, LONGEST_INT_LENGTH, LONGEST_LONG_LENGTH, NEGATIVE, SEPARATOR, SEPARATOR_LENGTH, UNKNOWN_INDEX, YES, ZERO_LENGTH| Constructor and Description |
|---|
MutableAsciiBuffer() |
MutableAsciiBuffer(byte[] buffer) |
MutableAsciiBuffer(byte[] buffer,
int offset,
int length) |
MutableAsciiBuffer(java.nio.ByteBuffer buffer) |
MutableAsciiBuffer(java.nio.ByteBuffer buffer,
int offset,
int length) |
MutableAsciiBuffer(org.agrona.DirectBuffer buffer) |
MutableAsciiBuffer(org.agrona.DirectBuffer buffer,
int offset,
int length) |
MutableAsciiBuffer(long address,
int length) |
| Modifier and Type | Method and Description |
|---|---|
int |
computeChecksum(int startInclusive,
int endExclusive) |
java.lang.String |
getAscii(int offset,
int length)
Not at all a performant conversion: don't use this on a critical application path.
|
boolean |
getBoolean(int index) |
byte[] |
getBytes(byte[] oldBuffer,
int offset,
int length) |
char |
getChar(int index) |
char[] |
getChars(char[] oldBuffer,
int offset,
int length) |
int |
getDigit(int index) |
DecimalFloat |
getFloat(DecimalFloat number,
int offset,
int length) |
int |
getInt(int startInclusive,
int endExclusive) |
int |
getLocalMktDate(int offset,
int length) |
long |
getMessageType(int offset,
int length) |
int |
getNatural(int startInclusive,
int endExclusive) |
long |
getNaturalLong(int startInclusive,
int endExclusive) |
int |
getUtcDateOnly(int offset) |
long |
getUtcTimeOnly(int offset,
int length) |
long |
getUtcTimestamp(int offset,
int length) |
boolean |
isDigit(int index) |
static int |
lengthInAscii(int value) |
int |
putAscii(int index,
java.lang.String string) |
int |
putBooleanAscii(int offset,
boolean value) |
int |
putCharAscii(int index,
char value) |
int |
putFloatAscii(int offset,
long value,
int scale)
Put's a float value in an ascii encoding.
|
int |
putFloatAscii(int offset,
ReadOnlyDecimalFloat price) |
void |
putSeparator(int index) |
int |
scan(int startInclusive,
int endExclusive,
byte terminator) |
int |
scan(int startInclusive,
int endExclusive,
char terminatingCharacter) |
int |
scanBack(int startInclusive,
int endExclusive,
byte terminator) |
int |
scanBack(int startInclusive,
int endExclusive,
char terminatingCharacter) |
addIntOrdered, addLongOrdered, addressOffset, boundsCheck, byteArray, byteBuffer, capacity, checkLimit, compareAndSetInt, compareAndSetLong, compareTo, equals, getAndAddInt, getAndAddLong, getAndSetInt, getAndSetLong, getByte, getBytes, getBytes, getBytes, getBytes, getBytes, getByteVolatile, getChar, getCharVolatile, getDouble, getDouble, getFloat, getFloat, getInt, getInt, getIntVolatile, getLong, getLong, getLongVolatile, getShort, getShort, getShortVolatile, getStringAscii, getStringAscii, getStringAscii, getStringAscii, getStringAscii, getStringAscii, getStringUtf8, getStringUtf8, getStringUtf8, getStringWithoutLengthAscii, getStringWithoutLengthAscii, getStringWithoutLengthUtf8, hashCode, isExpandable, parseIntAscii, parseLongAscii, parseNaturalIntAscii, parseNaturalLongAscii, putByte, putBytes, putBytes, putBytes, putBytes, putBytes, putByteVolatile, putChar, putChar, putCharVolatile, putDouble, putDouble, putFloat, putFloat, putInt, putInt, putIntAscii, putIntOrdered, putIntVolatile, putLong, putLong, putLongAscii, putLongOrdered, putLongVolatile, putNaturalIntAscii, putNaturalIntAsciiFromEnd, putNaturalLongAscii, putNaturalPaddedIntAscii, putShort, putShort, putShortVolatile, putStringAscii, putStringAscii, putStringAscii, putStringAscii, putStringUtf8, putStringUtf8, putStringUtf8, putStringUtf8, putStringWithoutLengthAscii, putStringWithoutLengthAscii, putStringWithoutLengthAscii, putStringWithoutLengthAscii, putStringWithoutLengthUtf8, setMemory, toString, verifyAlignment, wrap, wrap, wrap, wrap, wrap, wrap, wrap, wrapAdjustmentclone, finalize, getClass, notify, notifyAll, wait, wait, waitgetByteaddressOffset, boundsCheck, byteArray, byteBuffer, capacity, checkLimit, getBytes, getBytes, getBytes, getBytes, getBytes, getChar, getDouble, getDouble, getFloat, getFloat, getInt, getInt, getLong, getLong, getShort, getShort, getStringAscii, getStringAscii, getStringAscii, getStringAscii, getStringAscii, getStringAscii, getStringUtf8, getStringUtf8, getStringUtf8, getStringWithoutLengthAscii, getStringWithoutLengthAscii, getStringWithoutLengthUtf8, parseIntAscii, parseLongAscii, parseNaturalIntAscii, parseNaturalLongAscii, wrap, wrap, wrap, wrap, wrap, wrap, wrap, wrapAdjustmentpublic MutableAsciiBuffer()
public MutableAsciiBuffer(byte[] buffer)
public MutableAsciiBuffer(byte[] buffer,
int offset,
int length)
public MutableAsciiBuffer(java.nio.ByteBuffer buffer)
public MutableAsciiBuffer(java.nio.ByteBuffer buffer,
int offset,
int length)
public MutableAsciiBuffer(org.agrona.DirectBuffer buffer)
public MutableAsciiBuffer(org.agrona.DirectBuffer buffer,
int offset,
int length)
public MutableAsciiBuffer(long address,
int length)
public int getNatural(int startInclusive,
int endExclusive)
getNatural in interface AsciiBufferpublic long getNaturalLong(int startInclusive,
int endExclusive)
getNaturalLong in interface AsciiBufferpublic int getInt(int startInclusive,
int endExclusive)
getInt in interface AsciiBufferpublic int getDigit(int index)
getDigit in interface AsciiBufferpublic boolean isDigit(int index)
isDigit in interface AsciiBufferpublic char getChar(int index)
getChar in interface org.agrona.DirectBuffergetChar in interface AsciiBuffergetChar in class org.agrona.concurrent.UnsafeBufferpublic boolean getBoolean(int index)
getBoolean in interface AsciiBufferpublic byte[] getBytes(byte[] oldBuffer,
int offset,
int length)
getBytes in interface AsciiBufferpublic char[] getChars(char[] oldBuffer,
int offset,
int length)
getChars in interface AsciiBufferpublic java.lang.String getAscii(int offset,
int length)
getAscii in interface AsciiBufferoffset - The offset within the buffer to start at.length - the length in bytes to convert to a Stringpublic long getMessageType(int offset,
int length)
getMessageType in interface AsciiBufferpublic DecimalFloat getFloat(DecimalFloat number, int offset, int length)
getFloat in interface AsciiBufferpublic int getLocalMktDate(int offset,
int length)
getLocalMktDate in interface AsciiBufferpublic long getUtcTimestamp(int offset,
int length)
getUtcTimestamp in interface AsciiBufferpublic long getUtcTimeOnly(int offset,
int length)
getUtcTimeOnly in interface AsciiBufferpublic int getUtcDateOnly(int offset)
getUtcDateOnly in interface AsciiBufferpublic int scanBack(int startInclusive,
int endExclusive,
char terminatingCharacter)
scanBack in interface AsciiBufferpublic int scanBack(int startInclusive,
int endExclusive,
byte terminator)
scanBack in interface AsciiBufferpublic int scan(int startInclusive,
int endExclusive,
char terminatingCharacter)
scan in interface AsciiBufferpublic int scan(int startInclusive,
int endExclusive,
byte terminator)
scan in interface AsciiBufferpublic int computeChecksum(int startInclusive,
int endExclusive)
computeChecksum in interface AsciiBufferpublic int putAscii(int index,
java.lang.String string)
public void putSeparator(int index)
public int putBooleanAscii(int offset,
boolean value)
public static int lengthInAscii(int value)
public int putCharAscii(int index,
char value)
public int putFloatAscii(int offset,
ReadOnlyDecimalFloat price)
public int putFloatAscii(int offset,
long value,
int scale)
offset - the position at which to start putting ascii encoded float.value - the value of the float to encode - see DecimalFloat for details.scale - the scale of the float to encode - see DecimalFloat for details.java.lang.IllegalArgumentException - if you try to encode NaN.Copyright © 2015-2022 Real Logic Limited. All Rights Reserved.