Class FIXTypes
-
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptionstatic byte[]formatBackupStorageTimestamp(byte[] buffer, Calendar calendar, long additionalFractions, TimestampPrecision precision) static byte[]formatBackupStorageTimestamp(Calendar calendar) Deprecated.static byte[]formatBoolean(boolean value) Formats the booleanvalue.static byte[]formatCheckSum(int checkSum) Formats the check sum.static byte[]formatDate(Calendar calendar) Formats the value ofcalendarto theDateformat.static byte[]formatDouble(double value) Deprecated.DoubleFormat.formatstatic voidformatDouble(double value, int precision, byte[] buff, int offset) Deprecated.static intformatDoubleLength(double value, int precision) Deprecated.static voidformatDoubleWithPadding(double value, int precision, int padLength, byte[] buffer, int offset) static byte[]formatInt(long value) Formats the integer value.static intformatInt(long value, byte[] buffer) static intformatInt(long value, byte[] buffer, int offset) static intformatIntLength(long value) static intformatIntLengthWithPadding(long value, int padLength) static intformatIntWithPadding(long value, int padLength, byte[] buffer, int offset) static byte[]formatLocalMktDate(Calendar calendar) Formats the value ofcalendarto theLocalMktDateformat.static byte[]formatMonthYear(Calendar calendar) Formats the value ofcalendarto theMonthYearformat.static byte[]formatMonthYear44(Calendar calendar) Formats theMonthYear44value fromcalendar.static byte[]formatStorageTimestamp(byte[] buffer, int offset, Calendar calendar, long additionalFractions, TimestampPrecision precision) static byte[]formatStorageTimestamp(Calendar calendar, byte[] buffer, int offset) Deprecated.static byte[]formatTime(Calendar calendar) Formats the value ofcalendarto theTimeformat.static byte[]formatTimestamp(byte[] buffer, int offset, Calendar calendar, long additionalFractions, TimestampPrecision precision) static byte[]formatTZTimeOnly(Calendar calendar) Formats the value ofcalendarto theTZTimeOnlyformat.static byte[]formatTZTimestamp(Calendar calendar) Formats the value ofcalendarto theTZTimestampformat.static byte[]formatUInt(long value) Formats the integer value.static byte[]formatUTCDate(Calendar calendar) Formats the value ofcalendarto theUTCDateformat.static byte[]formatUTCTimeOnly(Calendar calendar) Formats the value ofcalendarto theUTCTimeOnlyformat.static byte[]formatUTCTimestamp(Calendar calendar) Formats the value ofcalendarto theUTCTimestampformat.static byte[]formatUTCTimestamp40(Calendar calendar) Formats the value ofcalendarto theUTCTimestamp40format.static voidformatUTCTimestampWithMs(Calendar calendar, byte[] sendingTimeBufMs) Format UTC timestamp with include millisecondsstatic voidformatUTCTimestampWithoutMs(Calendar calendar, byte[] sendingTimeBufNoMs) Format UTC timestamp with include millisecondsstatic booleanisInvalidBoolean(byte[] buffer) Returns true, ifbuffercontains the invalidbooleanvalue.static booleanisInvalidBoolean(byte[] buffer, int offset, int count) Returns true, if subarray contains the invalidbooleanvalue.static booleanisInvalidDate(byte[] buffer) Returns true, if subarray contains the invalidDatevalue.static booleanisInvalidDate(byte[] buffer, int offset, int count) Returns true, if subarray contains the invalidDatevalue.static booleanisInvalidFloat(byte[] buffer) Returns false, ifbuffercontains the invalid float value.static booleanisInvalidFloat(byte[] buffer, int offset, int count) Returns true, if subarray contains the invalid float value.static booleanisInvalidInt(byte[] buffer) Returns true, if subarray contains the invalidintegervalue.static booleanisInvalidInt(byte[] buf, int off, int len) Check if buffer has invalid integer numberstatic booleanisInvalidLocalMktTime(byte[] buffer) Returns true, ifbuffercontains the invalidLocalMktTimevalue.static booleanisInvalidLocalMktTime(byte[] buffer, int offset, int count) Returns true, if subarray contains the invalidLocalMktTimevalue.static booleanisInvalidMonthYear(byte[] buffer) Returns true, if subarray contains the invalidMonthYearvalue.static booleanisInvalidMonthYear(byte[] buffer, int offset, int count) Returns true, if subarray contains the invalidMonthYearvalue.static booleanisInvalidMonthYear44(byte[] buffer) Returns true, if subarray contains the invalidMonthYear44value.static booleanisInvalidMonthYear44(byte[] buffer, int offset, int count) Returns true, if subarray contains the invalidMonthYear44value.static booleanisInvalidTenor(byte[] buffer) Returns true, ifbuffercontains the invalidTenorvalue.static booleanisInvalidTenor(byte[] buffer, int offset, int count) Returns true, if subarray contains the invalidTenorvalue.static booleanisInvalidTime(byte[] buffer) Returns true, if subarray contains the invalidTimevalue.static booleanisInvalidTime(byte[] buffer, int offset, int count) Returns true, if subarray contains the invalidTimevalue.static booleanisInvalidTimeOnly(byte[] buffer) Returns true, ifbuffercontains the invalidTimeOnlyvalue.static booleanisInvalidTimeOnly(byte[] buffer, int offset, int count) Returns true, if subarray contains the invalidTimeOnlyvalue.static booleanisInvalidTimestamp(byte[] buffer) static booleanisInvalidTimestamp(byte[] buffer, int offset, int count) Returns true, if subarray contains the invalidTimestampvalue.static booleanisInvalidTimestamp40(byte[] buf) static booleanisInvalidTimestamp40(byte[] buf, int off, int len) static booleanisInvalidTZTimeOnly(byte[] buffer) Returns true, if subarray contains the invalidTZTimeOnlyvalue.static booleanisInvalidTZTimeOnly(byte[] buffer, int offset, int count) Returns true, if subarray contains the invalidTZTimeOnlyvalue.static booleanisInvalidTZTimestamp(byte[] buffer) Returns true, if subarray contains the invalidTZTimestampvalue.static booleanisInvalidTZTimestamp(byte[] buffer, int offset, int count) Returns true, if subarray contains the invalidTZTimestampvalue.static booleanparseBoolean(byte[] buffer) Parses thebooleanvalue from bytes.static booleanparseBoolean(byte[] buffer, int offset, int count) Parses thebooleanvalue from subarray.static CalendarparseDate(byte[] buffer) Parses theDatevalue frombuffer.static CalendarParses theDatevalue frombuffer.static CalendarParses theDatevalue frombuffer.protected static intparseDatePart(byte[] buffer, int year, int month) protected static intparseDatePart(byte[] buffer, int offset, int year, int month) static doubleparseFloat(byte[] value) Parses the float value from bytes.static doubleparseFloat(byte[] buffer, int offset, int count) Garbage-free method for converting string to doublestatic longparseInt(byte[] buffer) Parses theintegervalue frombuffer.static longparseInt(byte[] buffer, int offset, int count) Parses theintegervalue frombuffer.static longParses theintegervalue fromstr.static CalendarparseLocalMktDate(byte[] buffer) Parses theLocalMktDatevalue frombuffer.static CalendarparseLocalMktTime(byte[] buffer, int offset, int length, Calendar calendar) Parses theLocalMktTimevalue frombuffer.protected static intparseMonthPart(byte[] block) protected static intparseMonthPart(byte[] block, int offset) static CalendarparseMonthYear(byte[] buffer) Parses theMonthYearvalue frombuffer.static CalendarparseMonthYear(byte[] buffer, int offset, int length, Calendar calendar) Parses theMonthYearvalue frombuffer.static CalendarparseMonthYear(byte[] buffer, Calendar calendar) Parses theMonthYearvalue frombuffer.static CalendarparseMonthYear44(byte[] buffer) Parses theMonthYear44value frombuffer.static CalendarparseMonthYear44(byte[] buffer, int offset, int length, Calendar calendar) Parses theMonthYear44value frombuffer.static CalendarparseMonthYear44(byte[] buffer, Calendar calendar) Parses theMonthYear44value frombuffer.protected static intparseNumberPart(byte[] block, int off, int limit) static CalendarparseShortTime(byte[] buffer, Calendar calendar) Parses theTimevalue frombuffer.static PeriodparseTenor(byte[] buffer, int offset, int count) Parses theTenorvalue frombuffer.static CalendarparseTime(byte[] buffer) Parses theTimevalue frombuffer.static CalendarParses theTimevalue frombuffer.static CalendarparseTimeOnly(byte[] buffer, int offset, int length, Calendar calendar) Parses theTimeOnlyvalue frombuffer.static CalendarparseTimeOnly(byte[] buffer, Calendar calendar) Parses theTimeOnlyvalue frombuffer.static CalendarparseTimestamp(byte[] buffer, int offset, int length, Calendar calendar) Parses theTimestampvalue frombuffertocalendar.static CalendarparseTimestamp(byte[] buffer, Calendar calendar) Parses theTimestampvalue frombuffertocalendar.static CalendarparseTimestamp40(byte[] buffer, Calendar calendar) Parses theTimestamp40value frombuffer.static CalendarparseTZTimeOnly(byte[] buffer) Parses theTZTimeOnlyvalue frombuffer.static CalendarparseTZTimeOnly(byte[] buffer, int offset, int length, Calendar calendar) static CalendarparseTZTimestamp(byte[] buffer) Parses theTZTimestampvalue frombuffer.static voidparseTZTimestamp(byte[] buffer, int offset, int length, Calendar calendar) Parses theTZTimestampvalue frombuffer.static CalendarparseUTCDate(byte[] buffer) Parses theUTCDatevalue frombuffer.static CalendarparseUTCTimeOnly(byte[] buffer) Parses theUTCTimeOnlyvalue frombuffer.static CalendarparseUTCTimeOnly(byte[] buffer, int offset, int length, Calendar cal) Parses theUTCTimeOnlyvalue frombuffer.static CalendarparseUTCTimestamp(byte[] buffer) Parses theUTCTimestampvalue frombuffer.static CalendarparseUTCTimestamp40(byte[] buffer) Parses theUTCTimestamp40value frombuffer.protected static intparseYearPart(byte[] block) protected static intparseYearPart(byte[] block, int offset)
-
Field Details
-
MAX_LONG_LAST_DIGIT
public static final long MAX_LONG_LAST_DIGIT- See Also:
-
MAX_LONG_DIV_10
public static final long MAX_LONG_DIV_10- See Also:
-
UTC_TIMEZONE
-
LOCAL_TIMEZONE
-
DEF_LOCALE
-
MAX_PRECISION
public static final int MAX_PRECISION- See Also:
-
-
Method Details
-
parseFloat
public static double parseFloat(byte[] value) Parses the float value from bytes.- Parameters:
value- the buffer of bytes- Throws:
IllegalArgumentException
-
parseFloat
public static double parseFloat(byte[] buffer, int offset, int count) Garbage-free method for converting string to double -
formatDouble
Deprecated.DoubleFormat.formatFormats thefloatvalue.- Parameters:
value- the value
-
formatDouble
Deprecated. -
formatDoubleLength
Deprecated. -
isInvalidFloat
public static boolean isInvalidFloat(byte[] buffer) Returns false, ifbuffercontains the invalid float value.- Parameters:
buffer- the buffer of bytes
-
isInvalidFloat
public static boolean isInvalidFloat(byte[] buffer, int offset, int count) Returns true, if subarray contains the invalid float value.The
offsetargument is the index of the first byte of the subarray and thecountargument specifies the length of the subarray.- Parameters:
buffer- the buffer of bytesoffset- the initial offsetcount- the length
-
parseBoolean
public static boolean parseBoolean(byte[] buffer, int offset, int count) Parses thebooleanvalue from subarray.The
offsetargument is the index of the first byte of the subarray and thecountargument specifies the length of the subarray.- Parameters:
buffer- the buffer of bytesoffset- the initial offsetcount- the length- Throws:
IllegalArgumentException
-
parseBoolean
public static boolean parseBoolean(byte[] buffer) Parses thebooleanvalue from bytes.- Parameters:
buffer- the buffer of bytes- Throws:
IllegalArgumentException
-
formatBoolean
public static byte[] formatBoolean(boolean value) Formats the booleanvalue.- Parameters:
value- the value
-
isInvalidBoolean
public static boolean isInvalidBoolean(byte[] buffer, int offset, int count) Returns true, if subarray contains the invalidbooleanvalue.The
offsetargument is the index of the first byte of the subarray and thecountargument specifies the length of the subarray.- Parameters:
buffer- the buffer of bytesoffset- the initial offsetcount- the length
-
isInvalidBoolean
public static boolean isInvalidBoolean(byte[] buffer) Returns true, ifbuffercontains the invalidbooleanvalue.- Parameters:
buffer- the buffer of bytes
-
parseNumberPart
protected static int parseNumberPart(byte[] block, int off, int limit) -
isInvalidTimestamp
public static boolean isInvalidTimestamp(byte[] buffer) -
isInvalidTimestamp40
public static boolean isInvalidTimestamp40(byte[] buf) -
isInvalidTimestamp40
public static boolean isInvalidTimestamp40(byte[] buf, int off, int len) -
isInvalidTimestamp
public static boolean isInvalidTimestamp(byte[] buffer, int offset, int count) Returns true, if subarray contains the invalidTimestampvalue.The
offsetargument is the index of the first byte of the subarray and thecountargument specifies the length of the subarray.- Parameters:
buffer- the buffer of bytesoffset- the initial offsetcount- the length
-
isInvalidTZTimestamp
public static boolean isInvalidTZTimestamp(byte[] buffer) Returns true, if subarray contains the invalidTZTimestampvalue.- Parameters:
buffer- the buffer of bytes
-
isInvalidTZTimestamp
public static boolean isInvalidTZTimestamp(byte[] buffer, int offset, int count) Returns true, if subarray contains the invalidTZTimestampvalue.The
offsetargument is the index of the first byte of the subarray and thecountargument specifies the length of the subarray.The format for
TZTimestampis YYYYMMDD-HH:MM[:SS[.sss][sss][sss]][Z | [ + | - hh[:mm]]].- Parameters:
buffer- the buffer of bytesoffset- the initial offsetcount- the length
-
isInvalidTimeOnly
public static boolean isInvalidTimeOnly(byte[] buffer) Returns true, ifbuffercontains the invalidTimeOnlyvalue.The format for
TimeOnlyis HH:MM:SS[.sss][sss][sss]- Parameters:
buffer- the buffer of bytes
-
isInvalidTimeOnly
public static boolean isInvalidTimeOnly(byte[] buffer, int offset, int count) Returns true, if subarray contains the invalidTimeOnlyvalue.The
offsetargument is the index of the first byte of the subarray and thecountargument specifies the length of the subarray.The format for
TimeOnlyis HH:MM:SS[.sss]- Parameters:
buffer- the buffer of bytesoffset- the initial offsetcount- the length
-
isInvalidLocalMktTime
public static boolean isInvalidLocalMktTime(byte[] buffer) Returns true, ifbuffercontains the invalidLocalMktTimevalue.The format for
LocalMktTimeis HH:MM:SS- Parameters:
buffer- the buffer of bytes
-
isInvalidLocalMktTime
public static boolean isInvalidLocalMktTime(byte[] buffer, int offset, int count) Returns true, if subarray contains the invalidLocalMktTimevalue.The
offsetargument is the index of the first byte of the subarray and thecountargument specifies the length of the subarray.The format for
LocalMktTimeis HH:MM:SS- Parameters:
buffer- the buffer of bytesoffset- the initial offsetcount- the length
-
isInvalidTenor
public static boolean isInvalidTenor(byte[] buffer) Returns true, ifbuffercontains the invalidTenorvalue.The format for
Tenoris Dx = tenor expression for “days”, e.g. “D5”, where “x” is any integer > 0 Mx = tenor expression for “months”, e.g. “M3”, where “x” is any integer > 0 Wx = tenor expression for “weeks”, e.g. “W13”, where “x” is any integer > 0 Yx = tenor expression for “years”, e.g. “Y1”, where “x” is any integer > 0- Parameters:
buffer- the buffer of bytes
-
isInvalidTenor
public static boolean isInvalidTenor(byte[] buffer, int offset, int count) Returns true, if subarray contains the invalidTenorvalue.The
offsetargument is the index of the first byte of the subarray and thecountargument specifies the length of the subarray.The format for
Tenoris Dx = tenor expression for “days”, e.g. “D5”, where “x” is any integer > 0 Mx = tenor expression for “months”, e.g. “M3”, where “x” is any integer > 0 Wx = tenor expression for “weeks”, e.g. “W13”, where “x” is any integer > 0 Yx = tenor expression for “years”, e.g. “Y1”, where “x” is any integer > 0- Parameters:
buffer- the buffer of bytesoffset- the initial offsetcount- the length
-
isInvalidTZTimeOnly
public static boolean isInvalidTZTimeOnly(byte[] buffer) Returns true, if subarray contains the invalidTZTimeOnlyvalue.The format for
TZTimeOnlyis HH:MM[:SS][.sss][Z | [ + | - hh[:mm]]].- Parameters:
buffer- the buffer of bytes
-
isInvalidTZTimeOnly
public static boolean isInvalidTZTimeOnly(byte[] buffer, int offset, int count) Returns true, if subarray contains the invalidTZTimeOnlyvalue.The
offsetargument is the index of the first byte of the subarray and thecountargument specifies the length of the subarray.The format for
TZTimeOnlyis HH:MM[:SS][.sss][sss][sss][Z | [ + | - hh[:mm]]].- Parameters:
buffer- the buffer of bytesoffset- the initial offsetcount- the length
-
isInvalidDate
public static boolean isInvalidDate(byte[] buffer) Returns true, if subarray contains the invalidDatevalue.The format for
Dateis yyyymmdd.- Parameters:
buffer- the buffer of bytes
-
isInvalidDate
public static boolean isInvalidDate(byte[] buffer, int offset, int count) Returns true, if subarray contains the invalidDatevalue.The
offsetargument is the index of the first byte of the subarray and thecountargument specifies the length of the subarray.The format for
Dateis yyyymmdd.- Parameters:
buffer- the buffer of bytesoffset- the initial offsetcount- the length
-
isInvalidMonthYear
public static boolean isInvalidMonthYear(byte[] buffer) Returns true, if subarray contains the invalidMonthYearvalue.The format for
MonthYearis YYYYMM.- Parameters:
buffer- the buffer of bytes
-
isInvalidMonthYear
public static boolean isInvalidMonthYear(byte[] buffer, int offset, int count) Returns true, if subarray contains the invalidMonthYearvalue.The
offsetargument is the index of the first byte of the subarray and thecountargument specifies the length of the subarray.The format for
MonthYearis YYYYMM.- Parameters:
buffer- the buffer of bytesoffset- the initial offsetcount- the length
-
isInvalidMonthYear44
public static boolean isInvalidMonthYear44(byte[] buffer) Returns true, if subarray contains the invalidMonthYear44value.The format for
MonthYearare YYYYMM,YYYYMMDD and YYYYMMWW.- Parameters:
buffer- the buffer of bytes
-
isInvalidMonthYear44
public static boolean isInvalidMonthYear44(byte[] buffer, int offset, int count) Returns true, if subarray contains the invalidMonthYear44value.The
offsetargument is the index of the first byte of the subarray and thecountargument specifies the length of the subarray.The format for
MonthYearare YYYYMM,YYYYMMDD and YYYYMMWW.- Parameters:
buffer- the buffer of bytesoffset- the initial offsetcount- the length
-
parseMonthYear44
Parses theMonthYear44value frombuffer.- Parameters:
buffer- the buffer of bytesThe format for
MonthYear44are YYYYMM, YYYYMMDD and YYYYMMWW.- Throws:
IllegalArgumentException
-
parseMonthYear44
Parses theMonthYear44value frombuffer.- Parameters:
buffer- the buffer of bytesThe format for
MonthYear44are YYYYMM, YYYYMMDD and YYYYMMWW.- Throws:
IllegalArgumentException
-
parseMonthYear44
Parses theMonthYear44value frombuffer.- Parameters:
buffer- the buffer of bytesThe format for
MonthYear44are YYYYMM, YYYYMMDD and YYYYMMWW.- Throws:
IllegalArgumentException
-
formatMonthYear44
Formats theMonthYear44value fromcalendar.- Parameters:
calendar- the calendarThe format for
MonthYear44are YYYYMM, YYYYMMDD and YYYYMMWW.- Throws:
IllegalArgumentException
-
isInvalidTime
public static boolean isInvalidTime(byte[] buffer) Returns true, if subarray contains the invalidTimevalue.The format for
Timeis YYYYMMDD-HH:MM:SS.- Parameters:
buffer- the buffer of bytes
-
isInvalidTime
public static boolean isInvalidTime(byte[] buffer, int offset, int count) Returns true, if subarray contains the invalidTimevalue.The
offsetargument is the index of the first byte of the subarray and thecountargument specifies the length of the subarray.The format for
Timeis YYYYMMDD-HH:MM:SS.- Parameters:
buffer- the buffer of bytesoffset- the initial offsetcount- the length
-
parseTimestamp40
Parses theTimestamp40value frombuffer.- Parameters:
buffer- the buffer of bytescalendar- the calendarThe format for
Timestamp40is YYYYMMDD-HH:MM:SS- Throws:
IllegalArgumentException
-
parseTimestamp
Parses theTimestampvalue frombuffertocalendar.- Parameters:
buffer- the buffer of bytescalendar- the calendarThe format for
Timestampis YYYYMMDD-HH:MM:SS[.sss]- Throws:
IllegalArgumentException
-
parseTimestamp
Parses theTimestampvalue frombuffertocalendar.- Parameters:
buffer- the buffer of bytescalendar- the calendarThe format for
Timestampis YYYYMMDD-HH:MM:SS[.sss]- Throws:
IllegalArgumentException
-
parseUTCTimestamp
Parses theUTCTimestampvalue frombuffer.- Parameters:
buffer- the buffer of bytesThe format for
UTCTimestampis YYYYMMDD-HH:MM:SS[.sss]- Throws:
IllegalArgumentException
-
parseUTCTimestamp40
Parses theUTCTimestamp40value frombuffer.- Parameters:
buffer- the buffer of bytesThe format for
UTCTimestamp40is YYYYMMDD-HH:MM:SS- Throws:
IllegalArgumentException
-
parseTimeOnly
Parses theTimeOnlyvalue frombuffer.- Parameters:
buffer- the buffer of bytescalendar- the calendarThe format for
TimeOnlyis HH:MM:SS[.sss]- Throws:
IllegalArgumentException
-
parseTimeOnly
Parses theTimeOnlyvalue frombuffer.- Parameters:
buffer- the buffer of bytescalendar- the calendarThe format for
TimeOnlyis HH:MM:SS[.sss]- Throws:
IllegalArgumentException
-
parseLocalMktTime
Parses theLocalMktTimevalue frombuffer.- Parameters:
buffer- the buffer of bytescalendar- the calendarThe format for
LocalMktTimeis HH:MM:SS- Throws:
IllegalArgumentException
-
parseTZTimeOnly
Parses theTZTimeOnlyvalue frombuffer.- Parameters:
buffer- the buffer of bytesThe format for
TZTimeOnlyis HH:MM[:SS][.sss][Z | [ + | - hh[:mm]]]- Throws:
IllegalArgumentException
-
parseTZTimeOnly
-
parseTZTimestamp
Parses theTZTimestampvalue frombuffer.- Parameters:
buffer- the buffer of bytesThe format for
TZTimeOnlyis YYYYMMDD-HH:MM[:SS][Z | [ + | - hh[:mm]]].- Throws:
IllegalArgumentException
-
parseTZTimestamp
Parses theTZTimestampvalue frombuffer.- Parameters:
buffer- the buffer of bytesThe format for
TZTimestampis YYYYMMDD-HH:MM[:SS][Z | [ + | - hh[:mm]]].- Throws:
IllegalArgumentException
-
parseUTCTimeOnly
Parses theUTCTimeOnlyvalue frombuffer.- Parameters:
buffer- the buffer of bytesThe format for
UTCTimeOnlyis HH:MM:SS[.sss].- Throws:
IllegalArgumentException
-
parseUTCTimeOnly
Parses theUTCTimeOnlyvalue frombuffer.- Parameters:
buffer- the buffer of bytesThe format for
UTCTimeOnlyis HH:MM:SS[.sss].- Throws:
IllegalArgumentException
-
parseDate
Parses theDatevalue frombuffer.- Parameters:
buffer- the buffer of bytesThe format for
Dateis YYYYMMDD.- Throws:
IllegalArgumentException
-
parseDate
Parses theDatevalue frombuffer.- Parameters:
buffer- the buffer of bytesThe format for
Dateis YYYYMMDD.- Throws:
IllegalArgumentException
-
parseDate
Parses theDatevalue frombuffer.- Parameters:
buffer- the buffer of bytesThe format for
Dateis YYYYMMDD.- Throws:
IllegalArgumentException
-
parseDatePart
protected static int parseDatePart(byte[] buffer, int year, int month) -
parseDatePart
protected static int parseDatePart(byte[] buffer, int offset, int year, int month) -
parseMonthPart
protected static int parseMonthPart(byte[] block) -
parseMonthPart
protected static int parseMonthPart(byte[] block, int offset) -
parseYearPart
protected static int parseYearPart(byte[] block) -
parseYearPart
protected static int parseYearPart(byte[] block, int offset) -
parseUTCDate
Parses theUTCDatevalue frombuffer.- Parameters:
buffer- the buffer of bytesThe format for
UTCDateis YYYYMMDD.- Throws:
IllegalArgumentException
-
parseLocalMktDate
Parses theLocalMktDatevalue frombuffer.- Parameters:
buffer- the buffer of bytesThe format for
LocalMktDateis YYYYMMDD.- Throws:
IllegalArgumentException
-
parseMonthYear
Parses theMonthYearvalue frombuffer.- Parameters:
buffer- the buffer of bytescalendar- the calendarThe format for
MonthYearis YYYYMM.- Throws:
IllegalArgumentException
-
parseMonthYear
Parses theMonthYearvalue frombuffer.- Parameters:
buffer- the buffer of bytescalendar- the calendarThe format for
MonthYearis YYYYMM.- Throws:
IllegalArgumentException
-
parseMonthYear
Parses theMonthYearvalue frombuffer.- Parameters:
buffer- the buffer of bytesThe format for
MonthYearis YYYYMM.- Throws:
IllegalArgumentException
-
parseTime
Parses theTimevalue frombuffer.- Parameters:
buffer- the buffer of bytescalendar- the calendarThe format for
Timeis YYYYMMDD-HH:MM:SS.- Throws:
IllegalArgumentException
-
parseShortTime
Parses theTimevalue frombuffer.- Parameters:
buffer- the buffer of bytescalendar- the calendarThe format for
Timeis HH:MM:SS.- Throws:
IllegalArgumentException
-
parseTime
Parses theTimevalue frombuffer.- Parameters:
buffer- the buffer of bytesThe format for
Timeis YYYYMMDD-HH:MM:SS.- Returns:
- the calendar
- Throws:
IllegalArgumentException
-
parseTenor
Parses theTenorvalue frombuffer. The format forTenoris ('Dx','Mx','Wx','Yx' where 'x' is any int)- Parameters:
buffer- the buffer of bytesoffset- the initial offset- Returns:
- the local time structured from the given buffer
- Throws:
IllegalArgumentException
-
formatUTCTimestamp40
Formats the value ofcalendarto theUTCTimestamp40format.The format for
UTCTimestamp40is YYYYMMDD-HH:MM:SS.- Parameters:
calendar- the value
-
formatUTCTimestamp
Formats the value ofcalendarto theUTCTimestampformat.The format for
UTCTimestampis YYYYMMDD-HH:MM:SS[.sss].- Parameters:
calendar- the value
-
formatUTCTimestampWithMs
Format UTC timestamp with include milliseconds- Parameters:
calendar- timestampsendingTimeBufMs- buffer size must be 21
-
formatUTCTimestampWithoutMs
Format UTC timestamp with include milliseconds- Parameters:
calendar- timestampsendingTimeBufNoMs- buffer size must be 17
-
formatUTCTimeOnly
Formats the value ofcalendarto theUTCTimeOnlyformat.The format for
UTCTimeOnlyis HH:MM:SS[.sss].- Parameters:
calendar- the value
-
formatTZTimeOnly
Formats the value ofcalendarto theTZTimeOnlyformat.The format for
TZTimeOnlyis HH:MM[:SS][.sss][Z | [ + | - hh[:mm]]].- Parameters:
calendar- the value
-
formatTZTimestamp
Formats the value ofcalendarto theTZTimestampformat.The format for
TZTimestampis YYYYMMDD-HH:MM[:SS[.sss]][Z | [ + | - hh[:mm]]].- Parameters:
calendar- the calendar
-
formatDate
Formats the value ofcalendarto theDateformat.The format for
Dateis YYYYMMDD.- Parameters:
calendar- the calendar
-
formatUTCDate
Formats the value ofcalendarto theUTCDateformat.The format for
UTCDateis YYYYMMDD.- Parameters:
calendar- the calendar
-
formatLocalMktDate
Formats the value ofcalendarto theLocalMktDateformat.The format for
LocalMktDateis YYYYMMDD.- Parameters:
calendar- the calendar
-
formatMonthYear
Formats the value ofcalendarto theMonthYearformat.The format for
MonthYearis YYYYMM.- Parameters:
calendar- the calendar
-
formatTime
Formats the value ofcalendarto theTimeformat.The format for
Timeis YYYYMMDD-HH:MM:SS.- Parameters:
calendar- the calendar
-
parseInt
public static long parseInt(byte[] buffer) Parses theintegervalue frombuffer.- Parameters:
buffer- the buffer of bytes- Throws:
IllegalArgumentException
-
parseInt
public static long parseInt(byte[] buffer, int offset, int count) Parses theintegervalue frombuffer.The
offsetargument is the index of the first byte of the subarray and thecountargument specifies the length of the subarray.- Parameters:
buffer- the buffer of bytesoffset- the initial offsetcount- the length- Throws:
IllegalArgumentException
-
parseInt
Parses theintegervalue fromstr.The
offsetargument is the index of the first char of the substring and thecountargument specifies the length of the substring.- Parameters:
str- a string representation of an integer.offset- the initial offsetcount- the length- Throws:
IllegalArgumentException
-
formatInt
public static byte[] formatInt(long value) Formats the integer value.- Parameters:
value- the value- Returns:
- the buffer
-
formatIntLength
public static int formatIntLength(long value) -
formatInt
public static int formatInt(long value, byte[] buffer) -
formatInt
public static int formatInt(long value, byte[] buffer, int offset) -
formatIntLengthWithPadding
public static int formatIntLengthWithPadding(long value, int padLength) -
formatIntWithPadding
public static int formatIntWithPadding(long value, int padLength, byte[] buffer, int offset) -
formatDoubleWithPadding
public static void formatDoubleWithPadding(double value, int precision, int padLength, byte[] buffer, int offset) -
formatUInt
public static byte[] formatUInt(long value) Formats the integer value.- Parameters:
value- the value- Returns:
- the buffer
-
isInvalidInt
public static boolean isInvalidInt(byte[] buffer) Returns true, if subarray contains the invalidintegervalue.- Parameters:
buffer- the buffer of bytes
-
isInvalidInt
public static boolean isInvalidInt(byte[] buf, int off, int len) Check if buffer has invalid integer number- Parameters:
buf- - bufferoff- - buffer offsetlen- - buffer length- Returns:
- true if invalid
-
formatCheckSum
public static byte[] formatCheckSum(int checkSum) Formats the check sum.- Parameters:
checkSum- the check sum- Returns:
- formated string
-
formatStorageTimestamp
@Deprecated public static byte[] formatStorageTimestamp(Calendar calendar, byte[] buffer, int offset) Deprecated.Format timestamp with milliseconds precision- Parameters:
calendar-buffer-offset-- Returns:
-
formatTimestamp
public static byte[] formatTimestamp(byte[] buffer, int offset, Calendar calendar, long additionalFractions, TimestampPrecision precision) -
formatStorageTimestamp
public static byte[] formatStorageTimestamp(byte[] buffer, int offset, Calendar calendar, long additionalFractions, TimestampPrecision precision) -
formatBackupStorageTimestamp
Deprecated.Format backup storage timestamp with default millisecond precision- Parameters:
calendar-- Returns:
-
formatBackupStorageTimestamp
public static byte[] formatBackupStorageTimestamp(byte[] buffer, Calendar calendar, long additionalFractions, TimestampPrecision precision)
-