Updating generated files (and minor code adjustment) for CME schema 8 changes:
This commit is contained in:
1 parent
57ac54b6c5
commit
8a1ab0ba9e
121 files changed
+8857
-5033
No files matched your search
+1
-1
Submodule docker/linux updated: 30707087b8...56c61231f3.
+1
-1
Submodule externals updated: 768cfa0f9b...4d96613ca8.
@@ -162,9 +162,9 @@ map_cust_cti(api::orderman::CTICode code) {
|
||||
case CTI_CODE_CTI_CODE1:
|
||||
return CustOrderCapacity::Membertradingfortheirownaccount;
|
||||
case CTI_CODE_CTI_CODE2:
|
||||
return CustOrderCapacity::Clearingfirmtradingforitsproprietaryaccount;
|
||||
return CustOrderCapacity::Memberfirmtradingforitsproprietaryaccount;
|
||||
case CTI_CODE_CTI_CODE3:
|
||||
return CustOrderCapacity::Membertradingforanothermember;
|
||||
return CustOrderCapacity::Membertradingforanothermemberornonmember;
|
||||
case CTI_CODE_CTI_CODE4:
|
||||
return CustOrderCapacity::Allother;
|
||||
default:
|
||||
|
||||
@@ -2,80 +2,17 @@
|
||||
#ifndef _ILINKBINARY_AVGPXIND_H_
|
||||
#define _ILINKBINARY_AVGPXIND_H_
|
||||
|
||||
#if defined(SBE_HAVE_CMATH)
|
||||
/* cmath needed for std::numeric_limits<double>::quiet_NaN() */
|
||||
# include <cmath>
|
||||
# define SBE_FLOAT_NAN std::numeric_limits<float>::quiet_NaN()
|
||||
# define SBE_DOUBLE_NAN std::numeric_limits<double>::quiet_NaN()
|
||||
#else
|
||||
/* math.h needed for NAN */
|
||||
# include <math.h>
|
||||
# define SBE_FLOAT_NAN NAN
|
||||
# define SBE_DOUBLE_NAN NAN
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201103L
|
||||
# define SBE_CONSTEXPR constexpr
|
||||
# define SBE_NOEXCEPT noexcept
|
||||
#else
|
||||
# define SBE_CONSTEXPR
|
||||
# define SBE_NOEXCEPT
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
# include <string_view>
|
||||
# define SBE_NODISCARD [[nodiscard]]
|
||||
#else
|
||||
# define SBE_NODISCARD
|
||||
#endif
|
||||
|
||||
#if !defined(__STDC_LIMIT_MACROS)
|
||||
# define __STDC_LIMIT_MACROS 1
|
||||
#endif
|
||||
|
||||
#include <cstdint>
|
||||
#include <cstring>
|
||||
#include <iomanip>
|
||||
#include <limits>
|
||||
#include <ostream>
|
||||
#include <stdexcept>
|
||||
#include <sstream>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <tuple>
|
||||
|
||||
#if defined(WIN32) || defined(_WIN32)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) _byteswap_ushort(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) _byteswap_ulong(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) _byteswap_uint64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) (v)
|
||||
#else
|
||||
# error "Byte Ordering of platform not determined. Set __BYTE_ORDER__ manually before including this file."
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
#define SBE_NULLVALUE_INT16 (std::numeric_limits<std::int16_t>::min)()
|
||||
@@ -86,7 +23,6 @@
|
||||
#define SBE_NULLVALUE_UINT32 (std::numeric_limits<std::uint32_t>::max)()
|
||||
#define SBE_NULLVALUE_UINT64 (std::numeric_limits<std::uint64_t>::max)()
|
||||
|
||||
|
||||
namespace iLinkBinary {
|
||||
|
||||
class AvgPxInd
|
||||
@@ -127,8 +63,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& os, AvgPxInd::Value m)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &os, AvgPxInd::Value m)
|
||||
{
|
||||
return os << AvgPxInd::c_str(m);
|
||||
}
|
||||
|
||||
@@ -2,80 +2,17 @@
|
||||
#ifndef _ILINKBINARY_BOOLEANFLAG_H_
|
||||
#define _ILINKBINARY_BOOLEANFLAG_H_
|
||||
|
||||
#if defined(SBE_HAVE_CMATH)
|
||||
/* cmath needed for std::numeric_limits<double>::quiet_NaN() */
|
||||
# include <cmath>
|
||||
# define SBE_FLOAT_NAN std::numeric_limits<float>::quiet_NaN()
|
||||
# define SBE_DOUBLE_NAN std::numeric_limits<double>::quiet_NaN()
|
||||
#else
|
||||
/* math.h needed for NAN */
|
||||
# include <math.h>
|
||||
# define SBE_FLOAT_NAN NAN
|
||||
# define SBE_DOUBLE_NAN NAN
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201103L
|
||||
# define SBE_CONSTEXPR constexpr
|
||||
# define SBE_NOEXCEPT noexcept
|
||||
#else
|
||||
# define SBE_CONSTEXPR
|
||||
# define SBE_NOEXCEPT
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
# include <string_view>
|
||||
# define SBE_NODISCARD [[nodiscard]]
|
||||
#else
|
||||
# define SBE_NODISCARD
|
||||
#endif
|
||||
|
||||
#if !defined(__STDC_LIMIT_MACROS)
|
||||
# define __STDC_LIMIT_MACROS 1
|
||||
#endif
|
||||
|
||||
#include <cstdint>
|
||||
#include <cstring>
|
||||
#include <iomanip>
|
||||
#include <limits>
|
||||
#include <ostream>
|
||||
#include <stdexcept>
|
||||
#include <sstream>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <tuple>
|
||||
|
||||
#if defined(WIN32) || defined(_WIN32)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) _byteswap_ushort(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) _byteswap_ulong(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) _byteswap_uint64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) (v)
|
||||
#else
|
||||
# error "Byte Ordering of platform not determined. Set __BYTE_ORDER__ manually before including this file."
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
#define SBE_NULLVALUE_INT16 (std::numeric_limits<std::int16_t>::min)()
|
||||
@@ -86,7 +23,6 @@
|
||||
#define SBE_NULLVALUE_UINT32 (std::numeric_limits<std::uint32_t>::max)()
|
||||
#define SBE_NULLVALUE_UINT64 (std::numeric_limits<std::uint64_t>::max)()
|
||||
|
||||
|
||||
namespace iLinkBinary {
|
||||
|
||||
class BooleanFlag
|
||||
@@ -124,8 +60,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& os, BooleanFlag::Value m)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &os, BooleanFlag::Value m)
|
||||
{
|
||||
return os << BooleanFlag::c_str(m);
|
||||
}
|
||||
|
||||
@@ -2,80 +2,17 @@
|
||||
#ifndef _ILINKBINARY_BOOLEANNULL_H_
|
||||
#define _ILINKBINARY_BOOLEANNULL_H_
|
||||
|
||||
#if defined(SBE_HAVE_CMATH)
|
||||
/* cmath needed for std::numeric_limits<double>::quiet_NaN() */
|
||||
# include <cmath>
|
||||
# define SBE_FLOAT_NAN std::numeric_limits<float>::quiet_NaN()
|
||||
# define SBE_DOUBLE_NAN std::numeric_limits<double>::quiet_NaN()
|
||||
#else
|
||||
/* math.h needed for NAN */
|
||||
# include <math.h>
|
||||
# define SBE_FLOAT_NAN NAN
|
||||
# define SBE_DOUBLE_NAN NAN
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201103L
|
||||
# define SBE_CONSTEXPR constexpr
|
||||
# define SBE_NOEXCEPT noexcept
|
||||
#else
|
||||
# define SBE_CONSTEXPR
|
||||
# define SBE_NOEXCEPT
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
# include <string_view>
|
||||
# define SBE_NODISCARD [[nodiscard]]
|
||||
#else
|
||||
# define SBE_NODISCARD
|
||||
#endif
|
||||
|
||||
#if !defined(__STDC_LIMIT_MACROS)
|
||||
# define __STDC_LIMIT_MACROS 1
|
||||
#endif
|
||||
|
||||
#include <cstdint>
|
||||
#include <cstring>
|
||||
#include <iomanip>
|
||||
#include <limits>
|
||||
#include <ostream>
|
||||
#include <stdexcept>
|
||||
#include <sstream>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <tuple>
|
||||
|
||||
#if defined(WIN32) || defined(_WIN32)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) _byteswap_ushort(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) _byteswap_ulong(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) _byteswap_uint64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) (v)
|
||||
#else
|
||||
# error "Byte Ordering of platform not determined. Set __BYTE_ORDER__ manually before including this file."
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
#define SBE_NULLVALUE_INT16 (std::numeric_limits<std::int16_t>::min)()
|
||||
@@ -86,7 +23,6 @@
|
||||
#define SBE_NULLVALUE_UINT32 (std::numeric_limits<std::uint32_t>::max)()
|
||||
#define SBE_NULLVALUE_UINT64 (std::numeric_limits<std::uint64_t>::max)()
|
||||
|
||||
|
||||
namespace iLinkBinary {
|
||||
|
||||
class BooleanNULL
|
||||
@@ -124,8 +60,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& os, BooleanNULL::Value m)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &os, BooleanNULL::Value m)
|
||||
{
|
||||
return os << BooleanNULL::c_str(m);
|
||||
}
|
||||
|
||||
@@ -70,11 +70,11 @@
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (__builtin_expect(exp, c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
@@ -156,6 +156,7 @@ private:
|
||||
std::uint64_t m_bufferLength = 0;
|
||||
std::uint64_t m_offset = 0;
|
||||
std::uint64_t m_position = 0;
|
||||
std::uint64_t m_actingBlockLength = 0;
|
||||
std::uint64_t m_actingVersion = 0;
|
||||
|
||||
inline std::uint64_t *sbePositionPtr() SBE_NOEXCEPT
|
||||
@@ -167,7 +168,7 @@ public:
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(330);
|
||||
static const std::uint16_t SBE_TEMPLATE_ID = static_cast<std::uint16_t>(521);
|
||||
static const std::uint16_t SBE_SCHEMA_ID = static_cast<std::uint16_t>(8);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(7);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(8);
|
||||
|
||||
enum MetaAttribute
|
||||
{
|
||||
@@ -200,6 +201,7 @@ public:
|
||||
m_bufferLength(bufferLength),
|
||||
m_offset(offset),
|
||||
m_position(sbeCheckPosition(offset + actingBlockLength)),
|
||||
m_actingBlockLength(actingBlockLength),
|
||||
m_actingVersion(actingVersion)
|
||||
{
|
||||
}
|
||||
@@ -240,7 +242,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeSchemaVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(7);
|
||||
return static_cast<std::uint16_t>(8);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR const char *sbeSemanticType() SBE_NOEXCEPT
|
||||
@@ -286,6 +288,11 @@ public:
|
||||
return *this = BusinessReject521(buffer, offset, bufferLength, actingBlockLength, actingVersion);
|
||||
}
|
||||
|
||||
BusinessReject521 &sbeRewind()
|
||||
{
|
||||
return wrapForDecode(m_buffer, m_offset, m_actingBlockLength, m_actingVersion, m_bufferLength);
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::uint64_t sbePosition() const SBE_NOEXCEPT
|
||||
{
|
||||
return m_position;
|
||||
@@ -668,7 +675,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
BusinessReject521 &putText(const std::string& str)
|
||||
BusinessReject521 &putText(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 256)
|
||||
@@ -874,7 +881,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
BusinessReject521 &putSenderID(const std::string& str)
|
||||
BusinessReject521 &putSenderID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -1293,7 +1300,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
BusinessReject521 &putLocation(const std::string& str)
|
||||
BusinessReject521 &putLocation(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 5)
|
||||
@@ -1724,7 +1731,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
BusinessReject521 &putRefMsgType(const std::string& str)
|
||||
BusinessReject521 &putRefMsgType(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 2)
|
||||
@@ -1932,11 +1939,16 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, BusinessReject521 _writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, BusinessReject521 _writer)
|
||||
{
|
||||
BusinessReject521 writer(_writer.m_buffer, _writer.m_offset,
|
||||
_writer.m_bufferLength, _writer.sbeBlockLength(), _writer.m_actingVersion);
|
||||
BusinessReject521 writer(
|
||||
_writer.m_buffer,
|
||||
_writer.m_offset,
|
||||
_writer.m_bufferLength,
|
||||
_writer.m_actingBlockLength,
|
||||
_writer.m_actingVersion);
|
||||
|
||||
builder << '{';
|
||||
builder << R"("Name": "BusinessReject521", )";
|
||||
builder << R"("sbeTemplateId": )";
|
||||
|
||||
@@ -2,80 +2,17 @@
|
||||
#ifndef _ILINKBINARY_CLEARINGACCTTYPE_H_
|
||||
#define _ILINKBINARY_CLEARINGACCTTYPE_H_
|
||||
|
||||
#if defined(SBE_HAVE_CMATH)
|
||||
/* cmath needed for std::numeric_limits<double>::quiet_NaN() */
|
||||
# include <cmath>
|
||||
# define SBE_FLOAT_NAN std::numeric_limits<float>::quiet_NaN()
|
||||
# define SBE_DOUBLE_NAN std::numeric_limits<double>::quiet_NaN()
|
||||
#else
|
||||
/* math.h needed for NAN */
|
||||
# include <math.h>
|
||||
# define SBE_FLOAT_NAN NAN
|
||||
# define SBE_DOUBLE_NAN NAN
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201103L
|
||||
# define SBE_CONSTEXPR constexpr
|
||||
# define SBE_NOEXCEPT noexcept
|
||||
#else
|
||||
# define SBE_CONSTEXPR
|
||||
# define SBE_NOEXCEPT
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
# include <string_view>
|
||||
# define SBE_NODISCARD [[nodiscard]]
|
||||
#else
|
||||
# define SBE_NODISCARD
|
||||
#endif
|
||||
|
||||
#if !defined(__STDC_LIMIT_MACROS)
|
||||
# define __STDC_LIMIT_MACROS 1
|
||||
#endif
|
||||
|
||||
#include <cstdint>
|
||||
#include <cstring>
|
||||
#include <iomanip>
|
||||
#include <limits>
|
||||
#include <ostream>
|
||||
#include <stdexcept>
|
||||
#include <sstream>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <tuple>
|
||||
|
||||
#if defined(WIN32) || defined(_WIN32)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) _byteswap_ushort(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) _byteswap_ulong(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) _byteswap_uint64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) (v)
|
||||
#else
|
||||
# error "Byte Ordering of platform not determined. Set __BYTE_ORDER__ manually before including this file."
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
#define SBE_NULLVALUE_INT16 (std::numeric_limits<std::int16_t>::min)()
|
||||
@@ -86,7 +23,6 @@
|
||||
#define SBE_NULLVALUE_UINT32 (std::numeric_limits<std::uint32_t>::max)()
|
||||
#define SBE_NULLVALUE_UINT64 (std::numeric_limits<std::uint64_t>::max)()
|
||||
|
||||
|
||||
namespace iLinkBinary {
|
||||
|
||||
class ClearingAcctType
|
||||
@@ -124,8 +60,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& os, ClearingAcctType::Value m)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &os, ClearingAcctType::Value m)
|
||||
{
|
||||
return os << ClearingAcctType::c_str(m);
|
||||
}
|
||||
|
||||
@@ -2,80 +2,17 @@
|
||||
#ifndef _ILINKBINARY_CMTAGIVEUPCD_H_
|
||||
#define _ILINKBINARY_CMTAGIVEUPCD_H_
|
||||
|
||||
#if defined(SBE_HAVE_CMATH)
|
||||
/* cmath needed for std::numeric_limits<double>::quiet_NaN() */
|
||||
# include <cmath>
|
||||
# define SBE_FLOAT_NAN std::numeric_limits<float>::quiet_NaN()
|
||||
# define SBE_DOUBLE_NAN std::numeric_limits<double>::quiet_NaN()
|
||||
#else
|
||||
/* math.h needed for NAN */
|
||||
# include <math.h>
|
||||
# define SBE_FLOAT_NAN NAN
|
||||
# define SBE_DOUBLE_NAN NAN
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201103L
|
||||
# define SBE_CONSTEXPR constexpr
|
||||
# define SBE_NOEXCEPT noexcept
|
||||
#else
|
||||
# define SBE_CONSTEXPR
|
||||
# define SBE_NOEXCEPT
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
# include <string_view>
|
||||
# define SBE_NODISCARD [[nodiscard]]
|
||||
#else
|
||||
# define SBE_NODISCARD
|
||||
#endif
|
||||
|
||||
#if !defined(__STDC_LIMIT_MACROS)
|
||||
# define __STDC_LIMIT_MACROS 1
|
||||
#endif
|
||||
|
||||
#include <cstdint>
|
||||
#include <cstring>
|
||||
#include <iomanip>
|
||||
#include <limits>
|
||||
#include <ostream>
|
||||
#include <stdexcept>
|
||||
#include <sstream>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <tuple>
|
||||
|
||||
#if defined(WIN32) || defined(_WIN32)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) _byteswap_ushort(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) _byteswap_ulong(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) _byteswap_uint64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) (v)
|
||||
#else
|
||||
# error "Byte Ordering of platform not determined. Set __BYTE_ORDER__ manually before including this file."
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
#define SBE_NULLVALUE_INT16 (std::numeric_limits<std::int16_t>::min)()
|
||||
@@ -86,7 +23,6 @@
|
||||
#define SBE_NULLVALUE_UINT32 (std::numeric_limits<std::uint32_t>::max)()
|
||||
#define SBE_NULLVALUE_UINT64 (std::numeric_limits<std::uint64_t>::max)()
|
||||
|
||||
|
||||
namespace iLinkBinary {
|
||||
|
||||
class CmtaGiveUpCD
|
||||
@@ -96,7 +32,7 @@ public:
|
||||
{
|
||||
GiveUp = static_cast<char>(71),
|
||||
SGXoffset = static_cast<char>(83),
|
||||
NULL_VALUE = static_cast<char>(0)
|
||||
NULL_VALUE = static_cast<char>(0x00)
|
||||
};
|
||||
|
||||
static CmtaGiveUpCD::Value get(const char value)
|
||||
@@ -105,7 +41,7 @@ public:
|
||||
{
|
||||
case static_cast<char>(71): return GiveUp;
|
||||
case static_cast<char>(83): return SGXoffset;
|
||||
case static_cast<char>(0): return NULL_VALUE;
|
||||
case static_cast<char>(0x00): return NULL_VALUE;
|
||||
}
|
||||
|
||||
throw std::runtime_error("unknown value for enum CmtaGiveUpCD [E103]");
|
||||
@@ -124,8 +60,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& os, CmtaGiveUpCD::Value m)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &os, CmtaGiveUpCD::Value m)
|
||||
{
|
||||
return os << CmtaGiveUpCD::c_str(m);
|
||||
}
|
||||
|
||||
@@ -2,80 +2,17 @@
|
||||
#ifndef _ILINKBINARY_CUSTORDHANDLINST_H_
|
||||
#define _ILINKBINARY_CUSTORDHANDLINST_H_
|
||||
|
||||
#if defined(SBE_HAVE_CMATH)
|
||||
/* cmath needed for std::numeric_limits<double>::quiet_NaN() */
|
||||
# include <cmath>
|
||||
# define SBE_FLOAT_NAN std::numeric_limits<float>::quiet_NaN()
|
||||
# define SBE_DOUBLE_NAN std::numeric_limits<double>::quiet_NaN()
|
||||
#else
|
||||
/* math.h needed for NAN */
|
||||
# include <math.h>
|
||||
# define SBE_FLOAT_NAN NAN
|
||||
# define SBE_DOUBLE_NAN NAN
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201103L
|
||||
# define SBE_CONSTEXPR constexpr
|
||||
# define SBE_NOEXCEPT noexcept
|
||||
#else
|
||||
# define SBE_CONSTEXPR
|
||||
# define SBE_NOEXCEPT
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
# include <string_view>
|
||||
# define SBE_NODISCARD [[nodiscard]]
|
||||
#else
|
||||
# define SBE_NODISCARD
|
||||
#endif
|
||||
|
||||
#if !defined(__STDC_LIMIT_MACROS)
|
||||
# define __STDC_LIMIT_MACROS 1
|
||||
#endif
|
||||
|
||||
#include <cstdint>
|
||||
#include <cstring>
|
||||
#include <iomanip>
|
||||
#include <limits>
|
||||
#include <ostream>
|
||||
#include <stdexcept>
|
||||
#include <sstream>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <tuple>
|
||||
|
||||
#if defined(WIN32) || defined(_WIN32)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) _byteswap_ushort(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) _byteswap_ulong(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) _byteswap_uint64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) (v)
|
||||
#else
|
||||
# error "Byte Ordering of platform not determined. Set __BYTE_ORDER__ manually before including this file."
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
#define SBE_NULLVALUE_INT16 (std::numeric_limits<std::int16_t>::min)()
|
||||
@@ -86,7 +23,6 @@
|
||||
#define SBE_NULLVALUE_UINT32 (std::numeric_limits<std::uint32_t>::max)()
|
||||
#define SBE_NULLVALUE_UINT64 (std::numeric_limits<std::uint64_t>::max)()
|
||||
|
||||
|
||||
namespace iLinkBinary {
|
||||
|
||||
class CustOrdHandlInst
|
||||
@@ -100,7 +36,7 @@ public:
|
||||
AlgoEngine = static_cast<char>(72),
|
||||
DeskElectronic = static_cast<char>(87),
|
||||
ClientElectronic = static_cast<char>(89),
|
||||
NULL_VALUE = static_cast<char>(0)
|
||||
NULL_VALUE = static_cast<char>(48)
|
||||
};
|
||||
|
||||
static CustOrdHandlInst::Value get(const char value)
|
||||
@@ -113,7 +49,7 @@ public:
|
||||
case static_cast<char>(72): return AlgoEngine;
|
||||
case static_cast<char>(87): return DeskElectronic;
|
||||
case static_cast<char>(89): return ClientElectronic;
|
||||
case static_cast<char>(0): return NULL_VALUE;
|
||||
case static_cast<char>(48): return NULL_VALUE;
|
||||
}
|
||||
|
||||
throw std::runtime_error("unknown value for enum CustOrdHandlInst [E103]");
|
||||
@@ -136,8 +72,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& os, CustOrdHandlInst::Value m)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &os, CustOrdHandlInst::Value m)
|
||||
{
|
||||
return os << CustOrdHandlInst::c_str(m);
|
||||
}
|
||||
|
||||
@@ -2,80 +2,17 @@
|
||||
#ifndef _ILINKBINARY_CUSTORDERCAPACITY_H_
|
||||
#define _ILINKBINARY_CUSTORDERCAPACITY_H_
|
||||
|
||||
#if defined(SBE_HAVE_CMATH)
|
||||
/* cmath needed for std::numeric_limits<double>::quiet_NaN() */
|
||||
# include <cmath>
|
||||
# define SBE_FLOAT_NAN std::numeric_limits<float>::quiet_NaN()
|
||||
# define SBE_DOUBLE_NAN std::numeric_limits<double>::quiet_NaN()
|
||||
#else
|
||||
/* math.h needed for NAN */
|
||||
# include <math.h>
|
||||
# define SBE_FLOAT_NAN NAN
|
||||
# define SBE_DOUBLE_NAN NAN
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201103L
|
||||
# define SBE_CONSTEXPR constexpr
|
||||
# define SBE_NOEXCEPT noexcept
|
||||
#else
|
||||
# define SBE_CONSTEXPR
|
||||
# define SBE_NOEXCEPT
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
# include <string_view>
|
||||
# define SBE_NODISCARD [[nodiscard]]
|
||||
#else
|
||||
# define SBE_NODISCARD
|
||||
#endif
|
||||
|
||||
#if !defined(__STDC_LIMIT_MACROS)
|
||||
# define __STDC_LIMIT_MACROS 1
|
||||
#endif
|
||||
|
||||
#include <cstdint>
|
||||
#include <cstring>
|
||||
#include <iomanip>
|
||||
#include <limits>
|
||||
#include <ostream>
|
||||
#include <stdexcept>
|
||||
#include <sstream>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <tuple>
|
||||
|
||||
#if defined(WIN32) || defined(_WIN32)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) _byteswap_ushort(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) _byteswap_ulong(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) _byteswap_uint64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) (v)
|
||||
#else
|
||||
# error "Byte Ordering of platform not determined. Set __BYTE_ORDER__ manually before including this file."
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
#define SBE_NULLVALUE_INT16 (std::numeric_limits<std::int16_t>::min)()
|
||||
@@ -86,7 +23,6 @@
|
||||
#define SBE_NULLVALUE_UINT32 (std::numeric_limits<std::uint32_t>::max)()
|
||||
#define SBE_NULLVALUE_UINT64 (std::numeric_limits<std::uint64_t>::max)()
|
||||
|
||||
|
||||
namespace iLinkBinary {
|
||||
|
||||
class CustOrderCapacity
|
||||
@@ -95,8 +31,8 @@ public:
|
||||
enum Value
|
||||
{
|
||||
Membertradingfortheirownaccount = static_cast<std::uint8_t>(1),
|
||||
Clearingfirmtradingforitsproprietaryaccount = static_cast<std::uint8_t>(2),
|
||||
Membertradingforanothermember = static_cast<std::uint8_t>(3),
|
||||
Memberfirmtradingforitsproprietaryaccount = static_cast<std::uint8_t>(2),
|
||||
Membertradingforanothermemberornonmember = static_cast<std::uint8_t>(3),
|
||||
Allother = static_cast<std::uint8_t>(4),
|
||||
NULL_VALUE = static_cast<std::uint8_t>(255)
|
||||
};
|
||||
@@ -106,8 +42,8 @@ public:
|
||||
switch (value)
|
||||
{
|
||||
case static_cast<std::uint8_t>(1): return Membertradingfortheirownaccount;
|
||||
case static_cast<std::uint8_t>(2): return Clearingfirmtradingforitsproprietaryaccount;
|
||||
case static_cast<std::uint8_t>(3): return Membertradingforanothermember;
|
||||
case static_cast<std::uint8_t>(2): return Memberfirmtradingforitsproprietaryaccount;
|
||||
case static_cast<std::uint8_t>(3): return Membertradingforanothermemberornonmember;
|
||||
case static_cast<std::uint8_t>(4): return Allother;
|
||||
case static_cast<std::uint8_t>(255): return NULL_VALUE;
|
||||
}
|
||||
@@ -120,8 +56,8 @@ public:
|
||||
switch (value)
|
||||
{
|
||||
case Membertradingfortheirownaccount: return "Membertradingfortheirownaccount";
|
||||
case Clearingfirmtradingforitsproprietaryaccount: return "Clearingfirmtradingforitsproprietaryaccount";
|
||||
case Membertradingforanothermember: return "Membertradingforanothermember";
|
||||
case Memberfirmtradingforitsproprietaryaccount: return "Memberfirmtradingforitsproprietaryaccount";
|
||||
case Membertradingforanothermemberornonmember: return "Membertradingforanothermemberornonmember";
|
||||
case Allother: return "Allother";
|
||||
case NULL_VALUE: return "NULL_VALUE";
|
||||
}
|
||||
@@ -130,8 +66,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& os, CustOrderCapacity::Value m)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &os, CustOrderCapacity::Value m)
|
||||
{
|
||||
return os << CustOrderCapacity::c_str(m);
|
||||
}
|
||||
|
||||
@@ -70,11 +70,11 @@
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (__builtin_expect(exp, c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
@@ -194,7 +194,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeSchemaVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(7);
|
||||
return static_cast<std::uint16_t>(8);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static const char *lengthMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
@@ -324,8 +324,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, DATA writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, DATA writer)
|
||||
{
|
||||
builder << '{';
|
||||
builder << R"("length": )";
|
||||
|
||||
@@ -2,80 +2,17 @@
|
||||
#ifndef _ILINKBINARY_DKREASON_H_
|
||||
#define _ILINKBINARY_DKREASON_H_
|
||||
|
||||
#if defined(SBE_HAVE_CMATH)
|
||||
/* cmath needed for std::numeric_limits<double>::quiet_NaN() */
|
||||
# include <cmath>
|
||||
# define SBE_FLOAT_NAN std::numeric_limits<float>::quiet_NaN()
|
||||
# define SBE_DOUBLE_NAN std::numeric_limits<double>::quiet_NaN()
|
||||
#else
|
||||
/* math.h needed for NAN */
|
||||
# include <math.h>
|
||||
# define SBE_FLOAT_NAN NAN
|
||||
# define SBE_DOUBLE_NAN NAN
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201103L
|
||||
# define SBE_CONSTEXPR constexpr
|
||||
# define SBE_NOEXCEPT noexcept
|
||||
#else
|
||||
# define SBE_CONSTEXPR
|
||||
# define SBE_NOEXCEPT
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
# include <string_view>
|
||||
# define SBE_NODISCARD [[nodiscard]]
|
||||
#else
|
||||
# define SBE_NODISCARD
|
||||
#endif
|
||||
|
||||
#if !defined(__STDC_LIMIT_MACROS)
|
||||
# define __STDC_LIMIT_MACROS 1
|
||||
#endif
|
||||
|
||||
#include <cstdint>
|
||||
#include <cstring>
|
||||
#include <iomanip>
|
||||
#include <limits>
|
||||
#include <ostream>
|
||||
#include <stdexcept>
|
||||
#include <sstream>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <tuple>
|
||||
|
||||
#if defined(WIN32) || defined(_WIN32)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) _byteswap_ushort(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) _byteswap_ulong(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) _byteswap_uint64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) (v)
|
||||
#else
|
||||
# error "Byte Ordering of platform not determined. Set __BYTE_ORDER__ manually before including this file."
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
#define SBE_NULLVALUE_INT16 (std::numeric_limits<std::int16_t>::min)()
|
||||
@@ -86,7 +23,6 @@
|
||||
#define SBE_NULLVALUE_UINT32 (std::numeric_limits<std::uint32_t>::max)()
|
||||
#define SBE_NULLVALUE_UINT64 (std::numeric_limits<std::uint64_t>::max)()
|
||||
|
||||
|
||||
namespace iLinkBinary {
|
||||
|
||||
class DKReason
|
||||
@@ -102,7 +38,7 @@ public:
|
||||
CalculationDifference = static_cast<char>(70),
|
||||
NoMatchingExecutionReport = static_cast<char>(71),
|
||||
Other = static_cast<char>(90),
|
||||
NULL_VALUE = static_cast<char>(0)
|
||||
NULL_VALUE = static_cast<char>(48)
|
||||
};
|
||||
|
||||
static DKReason::Value get(const char value)
|
||||
@@ -117,7 +53,7 @@ public:
|
||||
case static_cast<char>(70): return CalculationDifference;
|
||||
case static_cast<char>(71): return NoMatchingExecutionReport;
|
||||
case static_cast<char>(90): return Other;
|
||||
case static_cast<char>(0): return NULL_VALUE;
|
||||
case static_cast<char>(48): return NULL_VALUE;
|
||||
}
|
||||
|
||||
throw std::runtime_error("unknown value for enum DKReason [E103]");
|
||||
@@ -142,8 +78,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& os, DKReason::Value m)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &os, DKReason::Value m)
|
||||
{
|
||||
return os << DKReason::c_str(m);
|
||||
}
|
||||
|
||||
@@ -70,11 +70,11 @@
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (__builtin_expect(exp, c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
@@ -194,7 +194,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeSchemaVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(7);
|
||||
return static_cast<std::uint16_t>(8);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static const char *mantissaMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
@@ -338,8 +338,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, Decimal32NULL writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, Decimal32NULL writer)
|
||||
{
|
||||
builder << '{';
|
||||
builder << R"("mantissa": )";
|
||||
|
||||
@@ -70,11 +70,11 @@
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (__builtin_expect(exp, c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
@@ -194,7 +194,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeSchemaVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(7);
|
||||
return static_cast<std::uint16_t>(8);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static const char *mantissaMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
@@ -213,7 +213,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint64_t mantissaSinceVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return 0;
|
||||
return 6;
|
||||
}
|
||||
|
||||
SBE_NODISCARD bool mantissaInActingVersion() SBE_NOEXCEPT
|
||||
@@ -255,6 +255,11 @@ public:
|
||||
|
||||
SBE_NODISCARD std::int64_t mantissa() const SBE_NOEXCEPT
|
||||
{
|
||||
if (m_actingVersion < 6)
|
||||
{
|
||||
return INT64_C(9223372036854775807);
|
||||
}
|
||||
|
||||
std::int64_t val;
|
||||
std::memcpy(&val, m_buffer + m_offset + 0, sizeof(std::int64_t));
|
||||
return SBE_LITTLE_ENDIAN_ENCODE_64(val);
|
||||
@@ -283,7 +288,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint64_t exponentSinceVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return 0;
|
||||
return 6;
|
||||
}
|
||||
|
||||
SBE_NODISCARD bool exponentInActingVersion() SBE_NOEXCEPT
|
||||
@@ -325,6 +330,11 @@ public:
|
||||
|
||||
SBE_NODISCARD std::int8_t exponent() const SBE_NOEXCEPT
|
||||
{
|
||||
if (m_actingVersion < 6)
|
||||
{
|
||||
return static_cast<std::int8_t>(127);
|
||||
}
|
||||
|
||||
std::int8_t val;
|
||||
std::memcpy(&val, m_buffer + m_offset + 8, sizeof(std::int8_t));
|
||||
return (val);
|
||||
@@ -338,8 +348,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, Decimal64NULL writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, Decimal64NULL writer)
|
||||
{
|
||||
builder << '{';
|
||||
builder << R"("mantissa": )";
|
||||
|
||||
@@ -70,11 +70,11 @@
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (__builtin_expect(exp, c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
@@ -156,6 +156,7 @@ private:
|
||||
std::uint64_t m_bufferLength = 0;
|
||||
std::uint64_t m_offset = 0;
|
||||
std::uint64_t m_position = 0;
|
||||
std::uint64_t m_actingBlockLength = 0;
|
||||
std::uint64_t m_actingVersion = 0;
|
||||
|
||||
inline std::uint64_t *sbePositionPtr() SBE_NOEXCEPT
|
||||
@@ -167,7 +168,7 @@ public:
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(132);
|
||||
static const std::uint16_t SBE_TEMPLATE_ID = static_cast<std::uint16_t>(503);
|
||||
static const std::uint16_t SBE_SCHEMA_ID = static_cast<std::uint16_t>(8);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(7);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(8);
|
||||
|
||||
enum MetaAttribute
|
||||
{
|
||||
@@ -200,6 +201,7 @@ public:
|
||||
m_bufferLength(bufferLength),
|
||||
m_offset(offset),
|
||||
m_position(sbeCheckPosition(offset + actingBlockLength)),
|
||||
m_actingBlockLength(actingBlockLength),
|
||||
m_actingVersion(actingVersion)
|
||||
{
|
||||
}
|
||||
@@ -240,7 +242,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeSchemaVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(7);
|
||||
return static_cast<std::uint16_t>(8);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR const char *sbeSemanticType() SBE_NOEXCEPT
|
||||
@@ -286,6 +288,11 @@ public:
|
||||
return *this = Establish503(buffer, offset, bufferLength, actingBlockLength, actingVersion);
|
||||
}
|
||||
|
||||
Establish503 &sbeRewind()
|
||||
{
|
||||
return wrapForDecode(m_buffer, m_offset, m_actingBlockLength, m_actingVersion, m_bufferLength);
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::uint64_t sbePosition() const SBE_NOEXCEPT
|
||||
{
|
||||
return m_position;
|
||||
@@ -651,7 +658,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
Establish503 &putHMACSignature(const std::string& str)
|
||||
Establish503 &putHMACSignature(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 32)
|
||||
@@ -857,7 +864,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
Establish503 &putAccessKeyID(const std::string& str)
|
||||
Establish503 &putAccessKeyID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -1063,7 +1070,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
Establish503 &putTradingSystemName(const std::string& str)
|
||||
Establish503 &putTradingSystemName(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 30)
|
||||
@@ -1269,7 +1276,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
Establish503 &putTradingSystemVersion(const std::string& str)
|
||||
Establish503 &putTradingSystemVersion(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 10)
|
||||
@@ -1475,7 +1482,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
Establish503 &putTradingSystemVendor(const std::string& str)
|
||||
Establish503 &putTradingSystemVendor(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 10)
|
||||
@@ -1909,7 +1916,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
Establish503 &putSession(const std::string& str)
|
||||
Establish503 &putSession(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 3)
|
||||
@@ -2115,7 +2122,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
Establish503 &putFirm(const std::string& str)
|
||||
Establish503 &putFirm(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 5)
|
||||
@@ -2367,7 +2374,7 @@ public:
|
||||
}
|
||||
#endif
|
||||
|
||||
Establish503 &putCredentials(const std::string& str)
|
||||
Establish503 &putCredentials(const std::string &str)
|
||||
{
|
||||
if (str.length() > 65534)
|
||||
{
|
||||
@@ -2388,11 +2395,16 @@ public:
|
||||
#endif
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, Establish503 _writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, Establish503 _writer)
|
||||
{
|
||||
Establish503 writer(_writer.m_buffer, _writer.m_offset,
|
||||
_writer.m_bufferLength, _writer.sbeBlockLength(), _writer.m_actingVersion);
|
||||
Establish503 writer(
|
||||
_writer.m_buffer,
|
||||
_writer.m_offset,
|
||||
_writer.m_bufferLength,
|
||||
_writer.m_actingBlockLength,
|
||||
_writer.m_actingVersion);
|
||||
|
||||
builder << '{';
|
||||
builder << R"("Name": "Establish503", )";
|
||||
builder << R"("sbeTemplateId": )";
|
||||
|
||||
@@ -70,11 +70,11 @@
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (__builtin_expect(exp, c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
@@ -156,6 +156,7 @@ private:
|
||||
std::uint64_t m_bufferLength = 0;
|
||||
std::uint64_t m_offset = 0;
|
||||
std::uint64_t m_position = 0;
|
||||
std::uint64_t m_actingBlockLength = 0;
|
||||
std::uint64_t m_actingVersion = 0;
|
||||
|
||||
inline std::uint64_t *sbePositionPtr() SBE_NOEXCEPT
|
||||
@@ -167,7 +168,7 @@ public:
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(38);
|
||||
static const std::uint16_t SBE_TEMPLATE_ID = static_cast<std::uint16_t>(504);
|
||||
static const std::uint16_t SBE_SCHEMA_ID = static_cast<std::uint16_t>(8);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(7);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(8);
|
||||
|
||||
enum MetaAttribute
|
||||
{
|
||||
@@ -200,6 +201,7 @@ public:
|
||||
m_bufferLength(bufferLength),
|
||||
m_offset(offset),
|
||||
m_position(sbeCheckPosition(offset + actingBlockLength)),
|
||||
m_actingBlockLength(actingBlockLength),
|
||||
m_actingVersion(actingVersion)
|
||||
{
|
||||
}
|
||||
@@ -240,7 +242,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeSchemaVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(7);
|
||||
return static_cast<std::uint16_t>(8);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR const char *sbeSemanticType() SBE_NOEXCEPT
|
||||
@@ -286,6 +288,11 @@ public:
|
||||
return *this = EstablishmentAck504(buffer, offset, bufferLength, actingBlockLength, actingVersion);
|
||||
}
|
||||
|
||||
EstablishmentAck504 &sbeRewind()
|
||||
{
|
||||
return wrapForDecode(m_buffer, m_offset, m_actingBlockLength, m_actingVersion, m_bufferLength);
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::uint64_t sbePosition() const SBE_NOEXCEPT
|
||||
{
|
||||
return m_position;
|
||||
@@ -962,11 +969,16 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, EstablishmentAck504 _writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, EstablishmentAck504 _writer)
|
||||
{
|
||||
EstablishmentAck504 writer(_writer.m_buffer, _writer.m_offset,
|
||||
_writer.m_bufferLength, _writer.sbeBlockLength(), _writer.m_actingVersion);
|
||||
EstablishmentAck504 writer(
|
||||
_writer.m_buffer,
|
||||
_writer.m_offset,
|
||||
_writer.m_bufferLength,
|
||||
_writer.m_actingBlockLength,
|
||||
_writer.m_actingVersion);
|
||||
|
||||
builder << '{';
|
||||
builder << R"("Name": "EstablishmentAck504", )";
|
||||
builder << R"("sbeTemplateId": )";
|
||||
|
||||
@@ -70,11 +70,11 @@
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (__builtin_expect(exp, c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
@@ -156,6 +156,7 @@ private:
|
||||
std::uint64_t m_bufferLength = 0;
|
||||
std::uint64_t m_offset = 0;
|
||||
std::uint64_t m_position = 0;
|
||||
std::uint64_t m_actingBlockLength = 0;
|
||||
std::uint64_t m_actingVersion = 0;
|
||||
|
||||
inline std::uint64_t *sbePositionPtr() SBE_NOEXCEPT
|
||||
@@ -167,7 +168,7 @@ public:
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(72);
|
||||
static const std::uint16_t SBE_TEMPLATE_ID = static_cast<std::uint16_t>(505);
|
||||
static const std::uint16_t SBE_SCHEMA_ID = static_cast<std::uint16_t>(8);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(7);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(8);
|
||||
|
||||
enum MetaAttribute
|
||||
{
|
||||
@@ -200,6 +201,7 @@ public:
|
||||
m_bufferLength(bufferLength),
|
||||
m_offset(offset),
|
||||
m_position(sbeCheckPosition(offset + actingBlockLength)),
|
||||
m_actingBlockLength(actingBlockLength),
|
||||
m_actingVersion(actingVersion)
|
||||
{
|
||||
}
|
||||
@@ -240,7 +242,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeSchemaVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(7);
|
||||
return static_cast<std::uint16_t>(8);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR const char *sbeSemanticType() SBE_NOEXCEPT
|
||||
@@ -286,6 +288,11 @@ public:
|
||||
return *this = EstablishmentReject505(buffer, offset, bufferLength, actingBlockLength, actingVersion);
|
||||
}
|
||||
|
||||
EstablishmentReject505 &sbeRewind()
|
||||
{
|
||||
return wrapForDecode(m_buffer, m_offset, m_actingBlockLength, m_actingVersion, m_bufferLength);
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::uint64_t sbePosition() const SBE_NOEXCEPT
|
||||
{
|
||||
return m_position;
|
||||
@@ -526,7 +533,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
EstablishmentReject505 &putReason(const std::string& str)
|
||||
EstablishmentReject505 &putReason(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 48)
|
||||
@@ -955,11 +962,16 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, EstablishmentReject505 _writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, EstablishmentReject505 _writer)
|
||||
{
|
||||
EstablishmentReject505 writer(_writer.m_buffer, _writer.m_offset,
|
||||
_writer.m_bufferLength, _writer.sbeBlockLength(), _writer.m_actingVersion);
|
||||
EstablishmentReject505 writer(
|
||||
_writer.m_buffer,
|
||||
_writer.m_offset,
|
||||
_writer.m_bufferLength,
|
||||
_writer.m_actingBlockLength,
|
||||
_writer.m_actingVersion);
|
||||
|
||||
builder << '{';
|
||||
builder << R"("Name": "EstablishmentReject505", )";
|
||||
builder << R"("sbeTemplateId": )";
|
||||
|
||||
@@ -2,80 +2,17 @@
|
||||
#ifndef _ILINKBINARY_EXECACKSTATUS_H_
|
||||
#define _ILINKBINARY_EXECACKSTATUS_H_
|
||||
|
||||
#if defined(SBE_HAVE_CMATH)
|
||||
/* cmath needed for std::numeric_limits<double>::quiet_NaN() */
|
||||
# include <cmath>
|
||||
# define SBE_FLOAT_NAN std::numeric_limits<float>::quiet_NaN()
|
||||
# define SBE_DOUBLE_NAN std::numeric_limits<double>::quiet_NaN()
|
||||
#else
|
||||
/* math.h needed for NAN */
|
||||
# include <math.h>
|
||||
# define SBE_FLOAT_NAN NAN
|
||||
# define SBE_DOUBLE_NAN NAN
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201103L
|
||||
# define SBE_CONSTEXPR constexpr
|
||||
# define SBE_NOEXCEPT noexcept
|
||||
#else
|
||||
# define SBE_CONSTEXPR
|
||||
# define SBE_NOEXCEPT
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
# include <string_view>
|
||||
# define SBE_NODISCARD [[nodiscard]]
|
||||
#else
|
||||
# define SBE_NODISCARD
|
||||
#endif
|
||||
|
||||
#if !defined(__STDC_LIMIT_MACROS)
|
||||
# define __STDC_LIMIT_MACROS 1
|
||||
#endif
|
||||
|
||||
#include <cstdint>
|
||||
#include <cstring>
|
||||
#include <iomanip>
|
||||
#include <limits>
|
||||
#include <ostream>
|
||||
#include <stdexcept>
|
||||
#include <sstream>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <tuple>
|
||||
|
||||
#if defined(WIN32) || defined(_WIN32)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) _byteswap_ushort(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) _byteswap_ulong(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) _byteswap_uint64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) (v)
|
||||
#else
|
||||
# error "Byte Ordering of platform not determined. Set __BYTE_ORDER__ manually before including this file."
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
#define SBE_NULLVALUE_INT16 (std::numeric_limits<std::int16_t>::min)()
|
||||
@@ -86,7 +23,6 @@
|
||||
#define SBE_NULLVALUE_UINT32 (std::numeric_limits<std::uint32_t>::max)()
|
||||
#define SBE_NULLVALUE_UINT64 (std::numeric_limits<std::uint64_t>::max)()
|
||||
|
||||
|
||||
namespace iLinkBinary {
|
||||
|
||||
class ExecAckStatus
|
||||
@@ -124,8 +60,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& os, ExecAckStatus::Value m)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &os, ExecAckStatus::Value m)
|
||||
{
|
||||
return os << ExecAckStatus::c_str(m);
|
||||
}
|
||||
|
||||
@@ -70,11 +70,11 @@
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (__builtin_expect(exp, c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
@@ -194,7 +194,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeSchemaVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(7);
|
||||
return static_cast<std::uint16_t>(8);
|
||||
}
|
||||
|
||||
ExecInst &clear()
|
||||
@@ -433,8 +433,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, ExecInst writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, ExecInst writer)
|
||||
{
|
||||
builder << '[';
|
||||
bool atLeastOne = false;
|
||||
|
||||
@@ -2,80 +2,17 @@
|
||||
#ifndef _ILINKBINARY_EXECMODE_H_
|
||||
#define _ILINKBINARY_EXECMODE_H_
|
||||
|
||||
#if defined(SBE_HAVE_CMATH)
|
||||
/* cmath needed for std::numeric_limits<double>::quiet_NaN() */
|
||||
# include <cmath>
|
||||
# define SBE_FLOAT_NAN std::numeric_limits<float>::quiet_NaN()
|
||||
# define SBE_DOUBLE_NAN std::numeric_limits<double>::quiet_NaN()
|
||||
#else
|
||||
/* math.h needed for NAN */
|
||||
# include <math.h>
|
||||
# define SBE_FLOAT_NAN NAN
|
||||
# define SBE_DOUBLE_NAN NAN
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201103L
|
||||
# define SBE_CONSTEXPR constexpr
|
||||
# define SBE_NOEXCEPT noexcept
|
||||
#else
|
||||
# define SBE_CONSTEXPR
|
||||
# define SBE_NOEXCEPT
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
# include <string_view>
|
||||
# define SBE_NODISCARD [[nodiscard]]
|
||||
#else
|
||||
# define SBE_NODISCARD
|
||||
#endif
|
||||
|
||||
#if !defined(__STDC_LIMIT_MACROS)
|
||||
# define __STDC_LIMIT_MACROS 1
|
||||
#endif
|
||||
|
||||
#include <cstdint>
|
||||
#include <cstring>
|
||||
#include <iomanip>
|
||||
#include <limits>
|
||||
#include <ostream>
|
||||
#include <stdexcept>
|
||||
#include <sstream>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <tuple>
|
||||
|
||||
#if defined(WIN32) || defined(_WIN32)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) _byteswap_ushort(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) _byteswap_ulong(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) _byteswap_uint64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) (v)
|
||||
#else
|
||||
# error "Byte Ordering of platform not determined. Set __BYTE_ORDER__ manually before including this file."
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
#define SBE_NULLVALUE_INT16 (std::numeric_limits<std::int16_t>::min)()
|
||||
@@ -86,7 +23,6 @@
|
||||
#define SBE_NULLVALUE_UINT32 (std::numeric_limits<std::uint32_t>::max)()
|
||||
#define SBE_NULLVALUE_UINT64 (std::numeric_limits<std::uint64_t>::max)()
|
||||
|
||||
|
||||
namespace iLinkBinary {
|
||||
|
||||
class ExecMode
|
||||
@@ -96,7 +32,7 @@ public:
|
||||
{
|
||||
Aggressive = static_cast<char>(65),
|
||||
Passive = static_cast<char>(80),
|
||||
NULL_VALUE = static_cast<char>(0)
|
||||
NULL_VALUE = static_cast<char>(0x00)
|
||||
};
|
||||
|
||||
static ExecMode::Value get(const char value)
|
||||
@@ -105,7 +41,7 @@ public:
|
||||
{
|
||||
case static_cast<char>(65): return Aggressive;
|
||||
case static_cast<char>(80): return Passive;
|
||||
case static_cast<char>(0): return NULL_VALUE;
|
||||
case static_cast<char>(0x00): return NULL_VALUE;
|
||||
}
|
||||
|
||||
throw std::runtime_error("unknown value for enum ExecMode [E103]");
|
||||
@@ -124,8 +60,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& os, ExecMode::Value m)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &os, ExecMode::Value m)
|
||||
{
|
||||
return os << ExecMode::c_str(m);
|
||||
}
|
||||
|
||||
@@ -2,80 +2,17 @@
|
||||
#ifndef _ILINKBINARY_EXECREASON_H_
|
||||
#define _ILINKBINARY_EXECREASON_H_
|
||||
|
||||
#if defined(SBE_HAVE_CMATH)
|
||||
/* cmath needed for std::numeric_limits<double>::quiet_NaN() */
|
||||
# include <cmath>
|
||||
# define SBE_FLOAT_NAN std::numeric_limits<float>::quiet_NaN()
|
||||
# define SBE_DOUBLE_NAN std::numeric_limits<double>::quiet_NaN()
|
||||
#else
|
||||
/* math.h needed for NAN */
|
||||
# include <math.h>
|
||||
# define SBE_FLOAT_NAN NAN
|
||||
# define SBE_DOUBLE_NAN NAN
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201103L
|
||||
# define SBE_CONSTEXPR constexpr
|
||||
# define SBE_NOEXCEPT noexcept
|
||||
#else
|
||||
# define SBE_CONSTEXPR
|
||||
# define SBE_NOEXCEPT
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
# include <string_view>
|
||||
# define SBE_NODISCARD [[nodiscard]]
|
||||
#else
|
||||
# define SBE_NODISCARD
|
||||
#endif
|
||||
|
||||
#if !defined(__STDC_LIMIT_MACROS)
|
||||
# define __STDC_LIMIT_MACROS 1
|
||||
#endif
|
||||
|
||||
#include <cstdint>
|
||||
#include <cstring>
|
||||
#include <iomanip>
|
||||
#include <limits>
|
||||
#include <ostream>
|
||||
#include <stdexcept>
|
||||
#include <sstream>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <tuple>
|
||||
|
||||
#if defined(WIN32) || defined(_WIN32)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) _byteswap_ushort(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) _byteswap_ulong(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) _byteswap_uint64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) (v)
|
||||
#else
|
||||
# error "Byte Ordering of platform not determined. Set __BYTE_ORDER__ manually before including this file."
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
#define SBE_NULLVALUE_INT16 (std::numeric_limits<std::int16_t>::min)()
|
||||
@@ -86,7 +23,6 @@
|
||||
#define SBE_NULLVALUE_UINT32 (std::numeric_limits<std::uint32_t>::max)()
|
||||
#define SBE_NULLVALUE_UINT64 (std::numeric_limits<std::uint64_t>::max)()
|
||||
|
||||
|
||||
namespace iLinkBinary {
|
||||
|
||||
class ExecReason
|
||||
@@ -103,6 +39,9 @@ public:
|
||||
CancelFromRiskManagementAPI = static_cast<std::uint8_t>(106),
|
||||
SelfMatchPreventionNewestOrderCancelled = static_cast<std::uint8_t>(107),
|
||||
Cancelduetovolquotedoptionorderrestedqtylessthanminordersize = static_cast<std::uint8_t>(108),
|
||||
CancelRFCOrder = static_cast<std::uint8_t>(109),
|
||||
CancelUponContractExpiration = static_cast<std::uint8_t>(110),
|
||||
SystemCancel = static_cast<std::uint8_t>(111),
|
||||
NULL_VALUE = static_cast<std::uint8_t>(255)
|
||||
};
|
||||
|
||||
@@ -119,6 +58,9 @@ public:
|
||||
case static_cast<std::uint8_t>(106): return CancelFromRiskManagementAPI;
|
||||
case static_cast<std::uint8_t>(107): return SelfMatchPreventionNewestOrderCancelled;
|
||||
case static_cast<std::uint8_t>(108): return Cancelduetovolquotedoptionorderrestedqtylessthanminordersize;
|
||||
case static_cast<std::uint8_t>(109): return CancelRFCOrder;
|
||||
case static_cast<std::uint8_t>(110): return CancelUponContractExpiration;
|
||||
case static_cast<std::uint8_t>(111): return SystemCancel;
|
||||
case static_cast<std::uint8_t>(255): return NULL_VALUE;
|
||||
}
|
||||
|
||||
@@ -138,6 +80,9 @@ public:
|
||||
case CancelFromRiskManagementAPI: return "CancelFromRiskManagementAPI";
|
||||
case SelfMatchPreventionNewestOrderCancelled: return "SelfMatchPreventionNewestOrderCancelled";
|
||||
case Cancelduetovolquotedoptionorderrestedqtylessthanminordersize: return "Cancelduetovolquotedoptionorderrestedqtylessthanminordersize";
|
||||
case CancelRFCOrder: return "CancelRFCOrder";
|
||||
case CancelUponContractExpiration: return "CancelUponContractExpiration";
|
||||
case SystemCancel: return "SystemCancel";
|
||||
case NULL_VALUE: return "NULL_VALUE";
|
||||
}
|
||||
|
||||
@@ -145,8 +90,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& os, ExecReason::Value m)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &os, ExecReason::Value m)
|
||||
{
|
||||
return os << ExecReason::c_str(m);
|
||||
}
|
||||
|
||||
@@ -2,80 +2,17 @@
|
||||
#ifndef _ILINKBINARY_EXECTYPTRDCXL_H_
|
||||
#define _ILINKBINARY_EXECTYPTRDCXL_H_
|
||||
|
||||
#if defined(SBE_HAVE_CMATH)
|
||||
/* cmath needed for std::numeric_limits<double>::quiet_NaN() */
|
||||
# include <cmath>
|
||||
# define SBE_FLOAT_NAN std::numeric_limits<float>::quiet_NaN()
|
||||
# define SBE_DOUBLE_NAN std::numeric_limits<double>::quiet_NaN()
|
||||
#else
|
||||
/* math.h needed for NAN */
|
||||
# include <math.h>
|
||||
# define SBE_FLOAT_NAN NAN
|
||||
# define SBE_DOUBLE_NAN NAN
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201103L
|
||||
# define SBE_CONSTEXPR constexpr
|
||||
# define SBE_NOEXCEPT noexcept
|
||||
#else
|
||||
# define SBE_CONSTEXPR
|
||||
# define SBE_NOEXCEPT
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
# include <string_view>
|
||||
# define SBE_NODISCARD [[nodiscard]]
|
||||
#else
|
||||
# define SBE_NODISCARD
|
||||
#endif
|
||||
|
||||
#if !defined(__STDC_LIMIT_MACROS)
|
||||
# define __STDC_LIMIT_MACROS 1
|
||||
#endif
|
||||
|
||||
#include <cstdint>
|
||||
#include <cstring>
|
||||
#include <iomanip>
|
||||
#include <limits>
|
||||
#include <ostream>
|
||||
#include <stdexcept>
|
||||
#include <sstream>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <tuple>
|
||||
|
||||
#if defined(WIN32) || defined(_WIN32)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) _byteswap_ushort(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) _byteswap_ulong(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) _byteswap_uint64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) (v)
|
||||
#else
|
||||
# error "Byte Ordering of platform not determined. Set __BYTE_ORDER__ manually before including this file."
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
#define SBE_NULLVALUE_INT16 (std::numeric_limits<std::int16_t>::min)()
|
||||
@@ -86,7 +23,6 @@
|
||||
#define SBE_NULLVALUE_UINT32 (std::numeric_limits<std::uint32_t>::max)()
|
||||
#define SBE_NULLVALUE_UINT64 (std::numeric_limits<std::uint64_t>::max)()
|
||||
|
||||
|
||||
namespace iLinkBinary {
|
||||
|
||||
class ExecTypTrdCxl
|
||||
@@ -124,8 +60,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& os, ExecTypTrdCxl::Value m)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &os, ExecTypTrdCxl::Value m)
|
||||
{
|
||||
return os << ExecTypTrdCxl::c_str(m);
|
||||
}
|
||||
|
||||
@@ -70,11 +70,11 @@
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (__builtin_expect(exp, c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
@@ -156,6 +156,7 @@ private:
|
||||
std::uint64_t m_bufferLength = 0;
|
||||
std::uint64_t m_offset = 0;
|
||||
std::uint64_t m_position = 0;
|
||||
std::uint64_t m_actingBlockLength = 0;
|
||||
std::uint64_t m_actingVersion = 0;
|
||||
|
||||
inline std::uint64_t *sbePositionPtr() SBE_NOEXCEPT
|
||||
@@ -167,7 +168,7 @@ public:
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(101);
|
||||
static const std::uint16_t SBE_TEMPLATE_ID = static_cast<std::uint16_t>(539);
|
||||
static const std::uint16_t SBE_SCHEMA_ID = static_cast<std::uint16_t>(8);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(7);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(8);
|
||||
|
||||
enum MetaAttribute
|
||||
{
|
||||
@@ -200,6 +201,7 @@ public:
|
||||
m_bufferLength(bufferLength),
|
||||
m_offset(offset),
|
||||
m_position(sbeCheckPosition(offset + actingBlockLength)),
|
||||
m_actingBlockLength(actingBlockLength),
|
||||
m_actingVersion(actingVersion)
|
||||
{
|
||||
}
|
||||
@@ -240,7 +242,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeSchemaVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(7);
|
||||
return static_cast<std::uint16_t>(8);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR const char *sbeSemanticType() SBE_NOEXCEPT
|
||||
@@ -286,6 +288,11 @@ public:
|
||||
return *this = ExecutionAck539(buffer, offset, bufferLength, actingBlockLength, actingVersion);
|
||||
}
|
||||
|
||||
ExecutionAck539 &sbeRewind()
|
||||
{
|
||||
return wrapForDecode(m_buffer, m_offset, m_actingBlockLength, m_actingVersion, m_bufferLength);
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::uint64_t sbePosition() const SBE_NOEXCEPT
|
||||
{
|
||||
return m_position;
|
||||
@@ -802,7 +809,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionAck539 &putClOrdID(const std::string& str)
|
||||
ExecutionAck539 &putClOrdID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -1352,6 +1359,11 @@ public:
|
||||
|
||||
std::string getSenderIDAsJsonEscapedString()
|
||||
{
|
||||
if (m_actingVersion < 4)
|
||||
{
|
||||
return std::string("");
|
||||
}
|
||||
|
||||
std::ostringstream oss;
|
||||
std::string s = getSenderIDAsString();
|
||||
|
||||
@@ -1414,7 +1426,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionAck539 &putSenderID(const std::string& str)
|
||||
ExecutionAck539 &putSenderID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -1654,6 +1666,11 @@ public:
|
||||
|
||||
std::string getLocationAsJsonEscapedString()
|
||||
{
|
||||
if (m_actingVersion < 5)
|
||||
{
|
||||
return std::string("");
|
||||
}
|
||||
|
||||
std::ostringstream oss;
|
||||
std::string s = getLocationAsString();
|
||||
|
||||
@@ -1716,7 +1733,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionAck539 &putLocation(const std::string& str)
|
||||
ExecutionAck539 &putLocation(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 5)
|
||||
@@ -1808,11 +1825,16 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, ExecutionAck539 _writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, ExecutionAck539 _writer)
|
||||
{
|
||||
ExecutionAck539 writer(_writer.m_buffer, _writer.m_offset,
|
||||
_writer.m_bufferLength, _writer.sbeBlockLength(), _writer.m_actingVersion);
|
||||
ExecutionAck539 writer(
|
||||
_writer.m_buffer,
|
||||
_writer.m_offset,
|
||||
_writer.m_bufferLength,
|
||||
_writer.m_actingBlockLength,
|
||||
_writer.m_actingVersion);
|
||||
|
||||
builder << '{';
|
||||
builder << R"("Name": "ExecutionAck539", )";
|
||||
builder << R"("sbeTemplateId": )";
|
||||
|
||||
@@ -70,11 +70,11 @@
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (__builtin_expect(exp, c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
@@ -156,6 +156,7 @@ private:
|
||||
std::uint64_t m_bufferLength = 0;
|
||||
std::uint64_t m_offset = 0;
|
||||
std::uint64_t m_position = 0;
|
||||
std::uint64_t m_actingBlockLength = 0;
|
||||
std::uint64_t m_actingVersion = 0;
|
||||
|
||||
inline std::uint64_t *sbePositionPtr() SBE_NOEXCEPT
|
||||
@@ -164,10 +165,10 @@ private:
|
||||
}
|
||||
|
||||
public:
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(222);
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(247);
|
||||
static const std::uint16_t SBE_TEMPLATE_ID = static_cast<std::uint16_t>(534);
|
||||
static const std::uint16_t SBE_SCHEMA_ID = static_cast<std::uint16_t>(8);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(7);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(8);
|
||||
|
||||
enum MetaAttribute
|
||||
{
|
||||
@@ -200,6 +201,7 @@ public:
|
||||
m_bufferLength(bufferLength),
|
||||
m_offset(offset),
|
||||
m_position(sbeCheckPosition(offset + actingBlockLength)),
|
||||
m_actingBlockLength(actingBlockLength),
|
||||
m_actingVersion(actingVersion)
|
||||
{
|
||||
}
|
||||
@@ -220,7 +222,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeBlockLength() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(222);
|
||||
return static_cast<std::uint16_t>(247);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint64_t sbeBlockAndHeaderLength() SBE_NOEXCEPT
|
||||
@@ -240,7 +242,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeSchemaVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(7);
|
||||
return static_cast<std::uint16_t>(8);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR const char *sbeSemanticType() SBE_NOEXCEPT
|
||||
@@ -286,6 +288,11 @@ public:
|
||||
return *this = ExecutionReportCancel534(buffer, offset, bufferLength, actingBlockLength, actingVersion);
|
||||
}
|
||||
|
||||
ExecutionReportCancel534 &sbeRewind()
|
||||
{
|
||||
return wrapForDecode(m_buffer, m_offset, m_actingBlockLength, m_actingVersion, m_bufferLength);
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::uint64_t sbePosition() const SBE_NOEXCEPT
|
||||
{
|
||||
return m_position;
|
||||
@@ -668,7 +675,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportCancel534 &putExecID(const std::string& str)
|
||||
ExecutionReportCancel534 &putExecID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 40)
|
||||
@@ -874,7 +881,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportCancel534 &putSenderID(const std::string& str)
|
||||
ExecutionReportCancel534 &putSenderID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -1080,7 +1087,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportCancel534 &putClOrdID(const std::string& str)
|
||||
ExecutionReportCancel534 &putClOrdID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -1877,7 +1884,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportCancel534 &putLocation(const std::string& str)
|
||||
ExecutionReportCancel534 &putLocation(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 5)
|
||||
@@ -3581,12 +3588,602 @@ public:
|
||||
return m_discretionPrice;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static const char *ReservationPriceMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
switch (metaAttribute)
|
||||
{
|
||||
case MetaAttribute::SEMANTIC_TYPE: return "Price";
|
||||
case MetaAttribute::PRESENCE: return "required";
|
||||
default: return "";
|
||||
}
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint16_t reservationPriceId() SBE_NOEXCEPT
|
||||
{
|
||||
return 9562;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint64_t reservationPriceSinceVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
SBE_NODISCARD bool reservationPriceInActingVersion() SBE_NOEXCEPT
|
||||
{
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic push
|
||||
#pragma clang diagnostic ignored "-Wtautological-compare"
|
||||
#endif
|
||||
return m_actingVersion >= reservationPriceSinceVersion();
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic pop
|
||||
#endif
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::size_t reservationPriceEncodingOffset() SBE_NOEXCEPT
|
||||
{
|
||||
return 222;
|
||||
}
|
||||
|
||||
private:
|
||||
PRICENULL9 m_reservationPrice;
|
||||
|
||||
public:
|
||||
SBE_NODISCARD PRICENULL9 &reservationPrice()
|
||||
{
|
||||
m_reservationPrice.wrap(m_buffer, m_offset + 222, m_actingVersion, m_bufferLength);
|
||||
return m_reservationPrice;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static const char *PriorityIndicatorMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
switch (metaAttribute)
|
||||
{
|
||||
case MetaAttribute::SEMANTIC_TYPE: return "int";
|
||||
case MetaAttribute::PRESENCE: return "optional";
|
||||
default: return "";
|
||||
}
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint16_t priorityIndicatorId() SBE_NOEXCEPT
|
||||
{
|
||||
return 638;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint64_t priorityIndicatorSinceVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
SBE_NODISCARD bool priorityIndicatorInActingVersion() SBE_NOEXCEPT
|
||||
{
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic push
|
||||
#pragma clang diagnostic ignored "-Wtautological-compare"
|
||||
#endif
|
||||
return m_actingVersion >= priorityIndicatorSinceVersion();
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic pop
|
||||
#endif
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::size_t priorityIndicatorEncodingOffset() SBE_NOEXCEPT
|
||||
{
|
||||
return 230;
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint8_t priorityIndicatorNullValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint8_t>(255);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint8_t priorityIndicatorMinValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint8_t>(0);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint8_t priorityIndicatorMaxValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint8_t>(254);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::size_t priorityIndicatorEncodingLength() SBE_NOEXCEPT
|
||||
{
|
||||
return 1;
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::uint8_t priorityIndicator() const SBE_NOEXCEPT
|
||||
{
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return static_cast<std::uint8_t>(255);
|
||||
}
|
||||
|
||||
std::uint8_t val;
|
||||
std::memcpy(&val, m_buffer + m_offset + 230, sizeof(std::uint8_t));
|
||||
return (val);
|
||||
}
|
||||
|
||||
ExecutionReportCancel534 &priorityIndicator(const std::uint8_t value) SBE_NOEXCEPT
|
||||
{
|
||||
std::uint8_t val = (value);
|
||||
std::memcpy(m_buffer + m_offset + 230, &val, sizeof(std::uint8_t));
|
||||
return *this;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static const char *OrigOrderUserMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
switch (metaAttribute)
|
||||
{
|
||||
case MetaAttribute::SEMANTIC_TYPE: return "String";
|
||||
case MetaAttribute::PRESENCE: return "optional";
|
||||
default: return "";
|
||||
}
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint16_t origOrderUserId() SBE_NOEXCEPT
|
||||
{
|
||||
return 9937;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint64_t origOrderUserSinceVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
SBE_NODISCARD bool origOrderUserInActingVersion() SBE_NOEXCEPT
|
||||
{
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic push
|
||||
#pragma clang diagnostic ignored "-Wtautological-compare"
|
||||
#endif
|
||||
return m_actingVersion >= origOrderUserSinceVersion();
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic pop
|
||||
#endif
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::size_t origOrderUserEncodingOffset() SBE_NOEXCEPT
|
||||
{
|
||||
return 231;
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR char origOrderUserNullValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<char>(0);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR char origOrderUserMinValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<char>(32);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR char origOrderUserMaxValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<char>(126);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::size_t origOrderUserEncodingLength() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint64_t origOrderUserLength() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
SBE_NODISCARD const char *origOrderUser() const SBE_NOEXCEPT
|
||||
{
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
return m_buffer + m_offset + 231;
|
||||
}
|
||||
|
||||
SBE_NODISCARD char *origOrderUser() SBE_NOEXCEPT
|
||||
{
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
return m_buffer + m_offset + 231;
|
||||
}
|
||||
|
||||
SBE_NODISCARD char origOrderUser(const std::uint64_t index) const
|
||||
{
|
||||
if (index >= 8)
|
||||
{
|
||||
throw std::runtime_error("index out of range for origOrderUser [E104]");
|
||||
}
|
||||
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return static_cast<char>(0);
|
||||
}
|
||||
|
||||
char val;
|
||||
std::memcpy(&val, m_buffer + m_offset + 231 + (index * 1), sizeof(char));
|
||||
return (val);
|
||||
}
|
||||
|
||||
ExecutionReportCancel534 &origOrderUser(const std::uint64_t index, const char value)
|
||||
{
|
||||
if (index >= 8)
|
||||
{
|
||||
throw std::runtime_error("index out of range for origOrderUser [E105]");
|
||||
}
|
||||
|
||||
char val = (value);
|
||||
std::memcpy(m_buffer + m_offset + 231 + (index * 1), &val, sizeof(char));
|
||||
return *this;
|
||||
}
|
||||
|
||||
std::uint64_t getOrigOrderUser(char *const dst, const std::uint64_t length) const
|
||||
{
|
||||
if (length > 8)
|
||||
{
|
||||
throw std::runtime_error("length too large for getOrigOrderUser [E106]");
|
||||
}
|
||||
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
std::memcpy(dst, m_buffer + m_offset + 231, sizeof(char) * static_cast<std::size_t>(length));
|
||||
return length;
|
||||
}
|
||||
|
||||
ExecutionReportCancel534 &putOrigOrderUser(const char *const src) SBE_NOEXCEPT
|
||||
{
|
||||
std::memcpy(m_buffer + m_offset + 231, src, sizeof(char) * 8);
|
||||
return *this;
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::string getOrigOrderUserAsString() const
|
||||
{
|
||||
const char *buffer = m_buffer + m_offset + 231;
|
||||
std::size_t length = 0;
|
||||
|
||||
for (; length < 8 && *(buffer + length) != '\0'; ++length);
|
||||
std::string result(buffer, length);
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
std::string getOrigOrderUserAsJsonEscapedString()
|
||||
{
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return std::string("");
|
||||
}
|
||||
|
||||
std::ostringstream oss;
|
||||
std::string s = getOrigOrderUserAsString();
|
||||
|
||||
for (const auto c : s)
|
||||
{
|
||||
switch (c)
|
||||
{
|
||||
case '"': oss << "\\\""; break;
|
||||
case '\\': oss << "\\\\"; break;
|
||||
case '\b': oss << "\\b"; break;
|
||||
case '\f': oss << "\\f"; break;
|
||||
case '\n': oss << "\\n"; break;
|
||||
case '\r': oss << "\\r"; break;
|
||||
case '\t': oss << "\\t"; break;
|
||||
|
||||
default:
|
||||
if ('\x00' <= c && c <= '\x1f')
|
||||
{
|
||||
oss << "\\u" << std::hex << std::setw(4)
|
||||
<< std::setfill('0') << (int)(c);
|
||||
}
|
||||
else
|
||||
{
|
||||
oss << c;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return oss.str();
|
||||
}
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
SBE_NODISCARD std::string_view getOrigOrderUserAsStringView() const SBE_NOEXCEPT
|
||||
{
|
||||
const char *buffer = m_buffer + m_offset + 231;
|
||||
std::size_t length = 0;
|
||||
|
||||
for (; length < 8 && *(buffer + length) != '\0'; ++length);
|
||||
std::string_view result(buffer, length);
|
||||
|
||||
return result;
|
||||
}
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
ExecutionReportCancel534 &putOrigOrderUser(const std::string_view str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 8)
|
||||
{
|
||||
throw std::runtime_error("string too large for putOrigOrderUser [E106]");
|
||||
}
|
||||
|
||||
std::memcpy(m_buffer + m_offset + 231, str.data(), srcLength);
|
||||
for (std::size_t start = srcLength; start < 8; ++start)
|
||||
{
|
||||
m_buffer[m_offset + 231 + start] = 0;
|
||||
}
|
||||
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportCancel534 &putOrigOrderUser(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 8)
|
||||
{
|
||||
throw std::runtime_error("string too large for putOrigOrderUser [E106]");
|
||||
}
|
||||
|
||||
std::memcpy(m_buffer + m_offset + 231, str.c_str(), srcLength);
|
||||
for (std::size_t start = srcLength; start < 8; ++start)
|
||||
{
|
||||
m_buffer[m_offset + 231 + start] = 0;
|
||||
}
|
||||
|
||||
return *this;
|
||||
}
|
||||
#endif
|
||||
|
||||
SBE_NODISCARD static const char *CancelTextMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
switch (metaAttribute)
|
||||
{
|
||||
case MetaAttribute::SEMANTIC_TYPE: return "String";
|
||||
case MetaAttribute::PRESENCE: return "optional";
|
||||
default: return "";
|
||||
}
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint16_t cancelTextId() SBE_NOEXCEPT
|
||||
{
|
||||
return 2807;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint64_t cancelTextSinceVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
SBE_NODISCARD bool cancelTextInActingVersion() SBE_NOEXCEPT
|
||||
{
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic push
|
||||
#pragma clang diagnostic ignored "-Wtautological-compare"
|
||||
#endif
|
||||
return m_actingVersion >= cancelTextSinceVersion();
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic pop
|
||||
#endif
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::size_t cancelTextEncodingOffset() SBE_NOEXCEPT
|
||||
{
|
||||
return 239;
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR char cancelTextNullValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<char>(0);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR char cancelTextMinValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<char>(32);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR char cancelTextMaxValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<char>(126);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::size_t cancelTextEncodingLength() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint64_t cancelTextLength() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
SBE_NODISCARD const char *cancelText() const SBE_NOEXCEPT
|
||||
{
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
return m_buffer + m_offset + 239;
|
||||
}
|
||||
|
||||
SBE_NODISCARD char *cancelText() SBE_NOEXCEPT
|
||||
{
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
return m_buffer + m_offset + 239;
|
||||
}
|
||||
|
||||
SBE_NODISCARD char cancelText(const std::uint64_t index) const
|
||||
{
|
||||
if (index >= 8)
|
||||
{
|
||||
throw std::runtime_error("index out of range for cancelText [E104]");
|
||||
}
|
||||
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return static_cast<char>(0);
|
||||
}
|
||||
|
||||
char val;
|
||||
std::memcpy(&val, m_buffer + m_offset + 239 + (index * 1), sizeof(char));
|
||||
return (val);
|
||||
}
|
||||
|
||||
ExecutionReportCancel534 &cancelText(const std::uint64_t index, const char value)
|
||||
{
|
||||
if (index >= 8)
|
||||
{
|
||||
throw std::runtime_error("index out of range for cancelText [E105]");
|
||||
}
|
||||
|
||||
char val = (value);
|
||||
std::memcpy(m_buffer + m_offset + 239 + (index * 1), &val, sizeof(char));
|
||||
return *this;
|
||||
}
|
||||
|
||||
std::uint64_t getCancelText(char *const dst, const std::uint64_t length) const
|
||||
{
|
||||
if (length > 8)
|
||||
{
|
||||
throw std::runtime_error("length too large for getCancelText [E106]");
|
||||
}
|
||||
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
std::memcpy(dst, m_buffer + m_offset + 239, sizeof(char) * static_cast<std::size_t>(length));
|
||||
return length;
|
||||
}
|
||||
|
||||
ExecutionReportCancel534 &putCancelText(const char *const src) SBE_NOEXCEPT
|
||||
{
|
||||
std::memcpy(m_buffer + m_offset + 239, src, sizeof(char) * 8);
|
||||
return *this;
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::string getCancelTextAsString() const
|
||||
{
|
||||
const char *buffer = m_buffer + m_offset + 239;
|
||||
std::size_t length = 0;
|
||||
|
||||
for (; length < 8 && *(buffer + length) != '\0'; ++length);
|
||||
std::string result(buffer, length);
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
std::string getCancelTextAsJsonEscapedString()
|
||||
{
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return std::string("");
|
||||
}
|
||||
|
||||
std::ostringstream oss;
|
||||
std::string s = getCancelTextAsString();
|
||||
|
||||
for (const auto c : s)
|
||||
{
|
||||
switch (c)
|
||||
{
|
||||
case '"': oss << "\\\""; break;
|
||||
case '\\': oss << "\\\\"; break;
|
||||
case '\b': oss << "\\b"; break;
|
||||
case '\f': oss << "\\f"; break;
|
||||
case '\n': oss << "\\n"; break;
|
||||
case '\r': oss << "\\r"; break;
|
||||
case '\t': oss << "\\t"; break;
|
||||
|
||||
default:
|
||||
if ('\x00' <= c && c <= '\x1f')
|
||||
{
|
||||
oss << "\\u" << std::hex << std::setw(4)
|
||||
<< std::setfill('0') << (int)(c);
|
||||
}
|
||||
else
|
||||
{
|
||||
oss << c;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return oss.str();
|
||||
}
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
SBE_NODISCARD std::string_view getCancelTextAsStringView() const SBE_NOEXCEPT
|
||||
{
|
||||
const char *buffer = m_buffer + m_offset + 239;
|
||||
std::size_t length = 0;
|
||||
|
||||
for (; length < 8 && *(buffer + length) != '\0'; ++length);
|
||||
std::string_view result(buffer, length);
|
||||
|
||||
return result;
|
||||
}
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
ExecutionReportCancel534 &putCancelText(const std::string_view str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 8)
|
||||
{
|
||||
throw std::runtime_error("string too large for putCancelText [E106]");
|
||||
}
|
||||
|
||||
std::memcpy(m_buffer + m_offset + 239, str.data(), srcLength);
|
||||
for (std::size_t start = srcLength; start < 8; ++start)
|
||||
{
|
||||
m_buffer[m_offset + 239 + start] = 0;
|
||||
}
|
||||
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportCancel534 &putCancelText(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 8)
|
||||
{
|
||||
throw std::runtime_error("string too large for putCancelText [E106]");
|
||||
}
|
||||
|
||||
std::memcpy(m_buffer + m_offset + 239, str.c_str(), srcLength);
|
||||
for (std::size_t start = srcLength; start < 8; ++start)
|
||||
{
|
||||
m_buffer[m_offset + 239 + start] = 0;
|
||||
}
|
||||
|
||||
return *this;
|
||||
}
|
||||
#endif
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, ExecutionReportCancel534 _writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, ExecutionReportCancel534 _writer)
|
||||
{
|
||||
ExecutionReportCancel534 writer(_writer.m_buffer, _writer.m_offset,
|
||||
_writer.m_bufferLength, _writer.sbeBlockLength(), _writer.m_actingVersion);
|
||||
ExecutionReportCancel534 writer(
|
||||
_writer.m_buffer,
|
||||
_writer.m_offset,
|
||||
_writer.m_bufferLength,
|
||||
_writer.m_actingBlockLength,
|
||||
_writer.m_actingVersion);
|
||||
|
||||
builder << '{';
|
||||
builder << R"("Name": "ExecutionReportCancel534", )";
|
||||
builder << R"("sbeTemplateId": )";
|
||||
@@ -3742,7 +4339,39 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("DiscretionPrice": )";
|
||||
builder << writer.discretionPrice();
|
||||
if (writer.discretionPriceInActingVersion())
|
||||
{
|
||||
builder << writer.discretionPrice();
|
||||
}
|
||||
else
|
||||
{
|
||||
builder << "{}";
|
||||
}
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("ReservationPrice": )";
|
||||
if (writer.reservationPriceInActingVersion())
|
||||
{
|
||||
builder << writer.reservationPrice();
|
||||
}
|
||||
else
|
||||
{
|
||||
builder << "{}";
|
||||
}
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("PriorityIndicator": )";
|
||||
builder << +writer.priorityIndicator();
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("OrigOrderUser": )";
|
||||
builder << '"' <<
|
||||
writer.getOrigOrderUserAsJsonEscapedString().c_str() << '"';
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("CancelText": )";
|
||||
builder << '"' <<
|
||||
writer.getCancelTextAsJsonEscapedString().c_str() << '"';
|
||||
|
||||
builder << '}';
|
||||
|
||||
|
||||
@@ -70,11 +70,11 @@
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (__builtin_expect(exp, c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
@@ -156,6 +156,7 @@ private:
|
||||
std::uint64_t m_bufferLength = 0;
|
||||
std::uint64_t m_offset = 0;
|
||||
std::uint64_t m_position = 0;
|
||||
std::uint64_t m_actingBlockLength = 0;
|
||||
std::uint64_t m_actingVersion = 0;
|
||||
|
||||
inline std::uint64_t *sbePositionPtr() SBE_NOEXCEPT
|
||||
@@ -164,10 +165,10 @@ private:
|
||||
}
|
||||
|
||||
public:
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(210);
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(219);
|
||||
static const std::uint16_t SBE_TEMPLATE_ID = static_cast<std::uint16_t>(524);
|
||||
static const std::uint16_t SBE_SCHEMA_ID = static_cast<std::uint16_t>(8);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(7);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(8);
|
||||
|
||||
enum MetaAttribute
|
||||
{
|
||||
@@ -200,6 +201,7 @@ public:
|
||||
m_bufferLength(bufferLength),
|
||||
m_offset(offset),
|
||||
m_position(sbeCheckPosition(offset + actingBlockLength)),
|
||||
m_actingBlockLength(actingBlockLength),
|
||||
m_actingVersion(actingVersion)
|
||||
{
|
||||
}
|
||||
@@ -220,7 +222,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeBlockLength() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(210);
|
||||
return static_cast<std::uint16_t>(219);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint64_t sbeBlockAndHeaderLength() SBE_NOEXCEPT
|
||||
@@ -240,7 +242,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeSchemaVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(7);
|
||||
return static_cast<std::uint16_t>(8);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR const char *sbeSemanticType() SBE_NOEXCEPT
|
||||
@@ -286,6 +288,11 @@ public:
|
||||
return *this = ExecutionReportElimination524(buffer, offset, bufferLength, actingBlockLength, actingVersion);
|
||||
}
|
||||
|
||||
ExecutionReportElimination524 &sbeRewind()
|
||||
{
|
||||
return wrapForDecode(m_buffer, m_offset, m_actingBlockLength, m_actingVersion, m_bufferLength);
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::uint64_t sbePosition() const SBE_NOEXCEPT
|
||||
{
|
||||
return m_position;
|
||||
@@ -668,7 +675,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportElimination524 &putExecID(const std::string& str)
|
||||
ExecutionReportElimination524 &putExecID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 40)
|
||||
@@ -874,7 +881,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportElimination524 &putSenderID(const std::string& str)
|
||||
ExecutionReportElimination524 &putSenderID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -1080,7 +1087,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportElimination524 &putClOrdID(const std::string& str)
|
||||
ExecutionReportElimination524 &putClOrdID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -1877,7 +1884,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportElimination524 &putLocation(const std::string& str)
|
||||
ExecutionReportElimination524 &putLocation(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 5)
|
||||
@@ -3308,12 +3315,140 @@ public:
|
||||
return m_discretionPrice;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static const char *ReservationPriceMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
switch (metaAttribute)
|
||||
{
|
||||
case MetaAttribute::SEMANTIC_TYPE: return "Price";
|
||||
case MetaAttribute::PRESENCE: return "required";
|
||||
default: return "";
|
||||
}
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint16_t reservationPriceId() SBE_NOEXCEPT
|
||||
{
|
||||
return 9562;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint64_t reservationPriceSinceVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
SBE_NODISCARD bool reservationPriceInActingVersion() SBE_NOEXCEPT
|
||||
{
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic push
|
||||
#pragma clang diagnostic ignored "-Wtautological-compare"
|
||||
#endif
|
||||
return m_actingVersion >= reservationPriceSinceVersion();
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic pop
|
||||
#endif
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::size_t reservationPriceEncodingOffset() SBE_NOEXCEPT
|
||||
{
|
||||
return 210;
|
||||
}
|
||||
|
||||
private:
|
||||
PRICENULL9 m_reservationPrice;
|
||||
|
||||
public:
|
||||
SBE_NODISCARD PRICENULL9 &reservationPrice()
|
||||
{
|
||||
m_reservationPrice.wrap(m_buffer, m_offset + 210, m_actingVersion, m_bufferLength);
|
||||
return m_reservationPrice;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static const char *PriorityIndicatorMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
switch (metaAttribute)
|
||||
{
|
||||
case MetaAttribute::SEMANTIC_TYPE: return "int";
|
||||
case MetaAttribute::PRESENCE: return "optional";
|
||||
default: return "";
|
||||
}
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint16_t priorityIndicatorId() SBE_NOEXCEPT
|
||||
{
|
||||
return 638;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint64_t priorityIndicatorSinceVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
SBE_NODISCARD bool priorityIndicatorInActingVersion() SBE_NOEXCEPT
|
||||
{
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic push
|
||||
#pragma clang diagnostic ignored "-Wtautological-compare"
|
||||
#endif
|
||||
return m_actingVersion >= priorityIndicatorSinceVersion();
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic pop
|
||||
#endif
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::size_t priorityIndicatorEncodingOffset() SBE_NOEXCEPT
|
||||
{
|
||||
return 218;
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint8_t priorityIndicatorNullValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint8_t>(255);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint8_t priorityIndicatorMinValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint8_t>(0);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint8_t priorityIndicatorMaxValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint8_t>(254);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::size_t priorityIndicatorEncodingLength() SBE_NOEXCEPT
|
||||
{
|
||||
return 1;
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::uint8_t priorityIndicator() const SBE_NOEXCEPT
|
||||
{
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return static_cast<std::uint8_t>(255);
|
||||
}
|
||||
|
||||
std::uint8_t val;
|
||||
std::memcpy(&val, m_buffer + m_offset + 218, sizeof(std::uint8_t));
|
||||
return (val);
|
||||
}
|
||||
|
||||
ExecutionReportElimination524 &priorityIndicator(const std::uint8_t value) SBE_NOEXCEPT
|
||||
{
|
||||
std::uint8_t val = (value);
|
||||
std::memcpy(m_buffer + m_offset + 218, &val, sizeof(std::uint8_t));
|
||||
return *this;
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, ExecutionReportElimination524 _writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, ExecutionReportElimination524 _writer)
|
||||
{
|
||||
ExecutionReportElimination524 writer(_writer.m_buffer, _writer.m_offset,
|
||||
_writer.m_bufferLength, _writer.sbeBlockLength(), _writer.m_actingVersion);
|
||||
ExecutionReportElimination524 writer(
|
||||
_writer.m_buffer,
|
||||
_writer.m_offset,
|
||||
_writer.m_bufferLength,
|
||||
_writer.m_actingBlockLength,
|
||||
_writer.m_actingVersion);
|
||||
|
||||
builder << '{';
|
||||
builder << R"("Name": "ExecutionReportElimination524", )";
|
||||
builder << R"("sbeTemplateId": )";
|
||||
@@ -3453,7 +3588,29 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("DiscretionPrice": )";
|
||||
builder << writer.discretionPrice();
|
||||
if (writer.discretionPriceInActingVersion())
|
||||
{
|
||||
builder << writer.discretionPrice();
|
||||
}
|
||||
else
|
||||
{
|
||||
builder << "{}";
|
||||
}
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("ReservationPrice": )";
|
||||
if (writer.reservationPriceInActingVersion())
|
||||
{
|
||||
builder << writer.reservationPrice();
|
||||
}
|
||||
else
|
||||
{
|
||||
builder << "{}";
|
||||
}
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("PriorityIndicator": )";
|
||||
builder << +writer.priorityIndicator();
|
||||
|
||||
builder << '}';
|
||||
|
||||
|
||||
@@ -70,11 +70,11 @@
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (__builtin_expect(exp, c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
@@ -156,6 +156,7 @@ private:
|
||||
std::uint64_t m_bufferLength = 0;
|
||||
std::uint64_t m_offset = 0;
|
||||
std::uint64_t m_position = 0;
|
||||
std::uint64_t m_actingBlockLength = 0;
|
||||
std::uint64_t m_actingVersion = 0;
|
||||
|
||||
inline std::uint64_t *sbePositionPtr() SBE_NOEXCEPT
|
||||
@@ -164,10 +165,10 @@ private:
|
||||
}
|
||||
|
||||
public:
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(225);
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(226);
|
||||
static const std::uint16_t SBE_TEMPLATE_ID = static_cast<std::uint16_t>(531);
|
||||
static const std::uint16_t SBE_SCHEMA_ID = static_cast<std::uint16_t>(8);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(7);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(8);
|
||||
|
||||
enum MetaAttribute
|
||||
{
|
||||
@@ -200,6 +201,7 @@ public:
|
||||
m_bufferLength(bufferLength),
|
||||
m_offset(offset),
|
||||
m_position(sbeCheckPosition(offset + actingBlockLength)),
|
||||
m_actingBlockLength(actingBlockLength),
|
||||
m_actingVersion(actingVersion)
|
||||
{
|
||||
}
|
||||
@@ -220,7 +222,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeBlockLength() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(225);
|
||||
return static_cast<std::uint16_t>(226);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint64_t sbeBlockAndHeaderLength() SBE_NOEXCEPT
|
||||
@@ -240,7 +242,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeSchemaVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(7);
|
||||
return static_cast<std::uint16_t>(8);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR const char *sbeSemanticType() SBE_NOEXCEPT
|
||||
@@ -286,6 +288,11 @@ public:
|
||||
return *this = ExecutionReportModify531(buffer, offset, bufferLength, actingBlockLength, actingVersion);
|
||||
}
|
||||
|
||||
ExecutionReportModify531 &sbeRewind()
|
||||
{
|
||||
return wrapForDecode(m_buffer, m_offset, m_actingBlockLength, m_actingVersion, m_bufferLength);
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::uint64_t sbePosition() const SBE_NOEXCEPT
|
||||
{
|
||||
return m_position;
|
||||
@@ -668,7 +675,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportModify531 &putExecID(const std::string& str)
|
||||
ExecutionReportModify531 &putExecID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 40)
|
||||
@@ -874,7 +881,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportModify531 &putSenderID(const std::string& str)
|
||||
ExecutionReportModify531 &putSenderID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -1080,7 +1087,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportModify531 &putClOrdID(const std::string& str)
|
||||
ExecutionReportModify531 &putClOrdID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -1877,7 +1884,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportModify531 &putLocation(const std::string& str)
|
||||
ExecutionReportModify531 &putLocation(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 5)
|
||||
@@ -3589,12 +3596,93 @@ public:
|
||||
return m_discretionPrice;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static const char *PriorityIndicatorMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
switch (metaAttribute)
|
||||
{
|
||||
case MetaAttribute::SEMANTIC_TYPE: return "int";
|
||||
case MetaAttribute::PRESENCE: return "optional";
|
||||
default: return "";
|
||||
}
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint16_t priorityIndicatorId() SBE_NOEXCEPT
|
||||
{
|
||||
return 638;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint64_t priorityIndicatorSinceVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
SBE_NODISCARD bool priorityIndicatorInActingVersion() SBE_NOEXCEPT
|
||||
{
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic push
|
||||
#pragma clang diagnostic ignored "-Wtautological-compare"
|
||||
#endif
|
||||
return m_actingVersion >= priorityIndicatorSinceVersion();
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic pop
|
||||
#endif
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::size_t priorityIndicatorEncodingOffset() SBE_NOEXCEPT
|
||||
{
|
||||
return 225;
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint8_t priorityIndicatorNullValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint8_t>(255);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint8_t priorityIndicatorMinValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint8_t>(0);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint8_t priorityIndicatorMaxValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint8_t>(254);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::size_t priorityIndicatorEncodingLength() SBE_NOEXCEPT
|
||||
{
|
||||
return 1;
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::uint8_t priorityIndicator() const SBE_NOEXCEPT
|
||||
{
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return static_cast<std::uint8_t>(255);
|
||||
}
|
||||
|
||||
std::uint8_t val;
|
||||
std::memcpy(&val, m_buffer + m_offset + 225, sizeof(std::uint8_t));
|
||||
return (val);
|
||||
}
|
||||
|
||||
ExecutionReportModify531 &priorityIndicator(const std::uint8_t value) SBE_NOEXCEPT
|
||||
{
|
||||
std::uint8_t val = (value);
|
||||
std::memcpy(m_buffer + m_offset + 225, &val, sizeof(std::uint8_t));
|
||||
return *this;
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, ExecutionReportModify531 _writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, ExecutionReportModify531 _writer)
|
||||
{
|
||||
ExecutionReportModify531 writer(_writer.m_buffer, _writer.m_offset,
|
||||
_writer.m_bufferLength, _writer.sbeBlockLength(), _writer.m_actingVersion);
|
||||
ExecutionReportModify531 writer(
|
||||
_writer.m_buffer,
|
||||
_writer.m_offset,
|
||||
_writer.m_bufferLength,
|
||||
_writer.m_actingBlockLength,
|
||||
_writer.m_actingVersion);
|
||||
|
||||
builder << '{';
|
||||
builder << R"("Name": "ExecutionReportModify531", )";
|
||||
builder << R"("sbeTemplateId": )";
|
||||
@@ -3750,7 +3838,18 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("DiscretionPrice": )";
|
||||
builder << writer.discretionPrice();
|
||||
if (writer.discretionPriceInActingVersion())
|
||||
{
|
||||
builder << writer.discretionPrice();
|
||||
}
|
||||
else
|
||||
{
|
||||
builder << "{}";
|
||||
}
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("PriorityIndicator": )";
|
||||
builder << +writer.priorityIndicator();
|
||||
|
||||
builder << '}';
|
||||
|
||||
|
||||
@@ -70,11 +70,11 @@
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (__builtin_expect(exp, c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
@@ -156,6 +156,7 @@ private:
|
||||
std::uint64_t m_bufferLength = 0;
|
||||
std::uint64_t m_offset = 0;
|
||||
std::uint64_t m_position = 0;
|
||||
std::uint64_t m_actingBlockLength = 0;
|
||||
std::uint64_t m_actingVersion = 0;
|
||||
|
||||
inline std::uint64_t *sbePositionPtr() SBE_NOEXCEPT
|
||||
@@ -164,10 +165,10 @@ private:
|
||||
}
|
||||
|
||||
public:
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(217);
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(226);
|
||||
static const std::uint16_t SBE_TEMPLATE_ID = static_cast<std::uint16_t>(522);
|
||||
static const std::uint16_t SBE_SCHEMA_ID = static_cast<std::uint16_t>(8);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(7);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(8);
|
||||
|
||||
enum MetaAttribute
|
||||
{
|
||||
@@ -200,6 +201,7 @@ public:
|
||||
m_bufferLength(bufferLength),
|
||||
m_offset(offset),
|
||||
m_position(sbeCheckPosition(offset + actingBlockLength)),
|
||||
m_actingBlockLength(actingBlockLength),
|
||||
m_actingVersion(actingVersion)
|
||||
{
|
||||
}
|
||||
@@ -220,7 +222,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeBlockLength() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(217);
|
||||
return static_cast<std::uint16_t>(226);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint64_t sbeBlockAndHeaderLength() SBE_NOEXCEPT
|
||||
@@ -240,7 +242,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeSchemaVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(7);
|
||||
return static_cast<std::uint16_t>(8);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR const char *sbeSemanticType() SBE_NOEXCEPT
|
||||
@@ -286,6 +288,11 @@ public:
|
||||
return *this = ExecutionReportNew522(buffer, offset, bufferLength, actingBlockLength, actingVersion);
|
||||
}
|
||||
|
||||
ExecutionReportNew522 &sbeRewind()
|
||||
{
|
||||
return wrapForDecode(m_buffer, m_offset, m_actingBlockLength, m_actingVersion, m_bufferLength);
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::uint64_t sbePosition() const SBE_NOEXCEPT
|
||||
{
|
||||
return m_position;
|
||||
@@ -668,7 +675,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportNew522 &putExecID(const std::string& str)
|
||||
ExecutionReportNew522 &putExecID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 40)
|
||||
@@ -874,7 +881,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportNew522 &putSenderID(const std::string& str)
|
||||
ExecutionReportNew522 &putSenderID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -1080,7 +1087,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportNew522 &putClOrdID(const std::string& str)
|
||||
ExecutionReportNew522 &putClOrdID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -1877,7 +1884,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportNew522 &putLocation(const std::string& str)
|
||||
ExecutionReportNew522 &putLocation(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 5)
|
||||
@@ -3447,12 +3454,140 @@ public:
|
||||
return m_discretionPrice;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static const char *ReservationPriceMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
switch (metaAttribute)
|
||||
{
|
||||
case MetaAttribute::SEMANTIC_TYPE: return "Price";
|
||||
case MetaAttribute::PRESENCE: return "required";
|
||||
default: return "";
|
||||
}
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint16_t reservationPriceId() SBE_NOEXCEPT
|
||||
{
|
||||
return 9562;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint64_t reservationPriceSinceVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
SBE_NODISCARD bool reservationPriceInActingVersion() SBE_NOEXCEPT
|
||||
{
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic push
|
||||
#pragma clang diagnostic ignored "-Wtautological-compare"
|
||||
#endif
|
||||
return m_actingVersion >= reservationPriceSinceVersion();
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic pop
|
||||
#endif
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::size_t reservationPriceEncodingOffset() SBE_NOEXCEPT
|
||||
{
|
||||
return 217;
|
||||
}
|
||||
|
||||
private:
|
||||
PRICENULL9 m_reservationPrice;
|
||||
|
||||
public:
|
||||
SBE_NODISCARD PRICENULL9 &reservationPrice()
|
||||
{
|
||||
m_reservationPrice.wrap(m_buffer, m_offset + 217, m_actingVersion, m_bufferLength);
|
||||
return m_reservationPrice;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static const char *PriorityIndicatorMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
switch (metaAttribute)
|
||||
{
|
||||
case MetaAttribute::SEMANTIC_TYPE: return "int";
|
||||
case MetaAttribute::PRESENCE: return "optional";
|
||||
default: return "";
|
||||
}
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint16_t priorityIndicatorId() SBE_NOEXCEPT
|
||||
{
|
||||
return 638;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint64_t priorityIndicatorSinceVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
SBE_NODISCARD bool priorityIndicatorInActingVersion() SBE_NOEXCEPT
|
||||
{
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic push
|
||||
#pragma clang diagnostic ignored "-Wtautological-compare"
|
||||
#endif
|
||||
return m_actingVersion >= priorityIndicatorSinceVersion();
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic pop
|
||||
#endif
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::size_t priorityIndicatorEncodingOffset() SBE_NOEXCEPT
|
||||
{
|
||||
return 225;
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint8_t priorityIndicatorNullValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint8_t>(255);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint8_t priorityIndicatorMinValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint8_t>(0);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint8_t priorityIndicatorMaxValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint8_t>(254);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::size_t priorityIndicatorEncodingLength() SBE_NOEXCEPT
|
||||
{
|
||||
return 1;
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::uint8_t priorityIndicator() const SBE_NOEXCEPT
|
||||
{
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return static_cast<std::uint8_t>(255);
|
||||
}
|
||||
|
||||
std::uint8_t val;
|
||||
std::memcpy(&val, m_buffer + m_offset + 225, sizeof(std::uint8_t));
|
||||
return (val);
|
||||
}
|
||||
|
||||
ExecutionReportNew522 &priorityIndicator(const std::uint8_t value) SBE_NOEXCEPT
|
||||
{
|
||||
std::uint8_t val = (value);
|
||||
std::memcpy(m_buffer + m_offset + 225, &val, sizeof(std::uint8_t));
|
||||
return *this;
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, ExecutionReportNew522 _writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, ExecutionReportNew522 _writer)
|
||||
{
|
||||
ExecutionReportNew522 writer(_writer.m_buffer, _writer.m_offset,
|
||||
_writer.m_bufferLength, _writer.sbeBlockLength(), _writer.m_actingVersion);
|
||||
ExecutionReportNew522 writer(
|
||||
_writer.m_buffer,
|
||||
_writer.m_offset,
|
||||
_writer.m_bufferLength,
|
||||
_writer.m_actingBlockLength,
|
||||
_writer.m_actingVersion);
|
||||
|
||||
builder << '{';
|
||||
builder << R"("Name": "ExecutionReportNew522", )";
|
||||
builder << R"("sbeTemplateId": )";
|
||||
@@ -3600,7 +3735,29 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("DiscretionPrice": )";
|
||||
builder << writer.discretionPrice();
|
||||
if (writer.discretionPriceInActingVersion())
|
||||
{
|
||||
builder << writer.discretionPrice();
|
||||
}
|
||||
else
|
||||
{
|
||||
builder << "{}";
|
||||
}
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("ReservationPrice": )";
|
||||
if (writer.reservationPriceInActingVersion())
|
||||
{
|
||||
builder << writer.reservationPrice();
|
||||
}
|
||||
else
|
||||
{
|
||||
builder << "{}";
|
||||
}
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("PriorityIndicator": )";
|
||||
builder << +writer.priorityIndicator();
|
||||
|
||||
builder << '}';
|
||||
|
||||
|
||||
@@ -70,11 +70,11 @@
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (__builtin_expect(exp, c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
@@ -156,6 +156,7 @@ private:
|
||||
std::uint64_t m_bufferLength = 0;
|
||||
std::uint64_t m_offset = 0;
|
||||
std::uint64_t m_position = 0;
|
||||
std::uint64_t m_actingBlockLength = 0;
|
||||
std::uint64_t m_actingVersion = 0;
|
||||
|
||||
inline std::uint64_t *sbePositionPtr() SBE_NOEXCEPT
|
||||
@@ -164,10 +165,10 @@ private:
|
||||
}
|
||||
|
||||
public:
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(194);
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(219);
|
||||
static const std::uint16_t SBE_TEMPLATE_ID = static_cast<std::uint16_t>(564);
|
||||
static const std::uint16_t SBE_SCHEMA_ID = static_cast<std::uint16_t>(8);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(7);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(8);
|
||||
|
||||
enum MetaAttribute
|
||||
{
|
||||
@@ -200,6 +201,7 @@ public:
|
||||
m_bufferLength(bufferLength),
|
||||
m_offset(offset),
|
||||
m_position(sbeCheckPosition(offset + actingBlockLength)),
|
||||
m_actingBlockLength(actingBlockLength),
|
||||
m_actingVersion(actingVersion)
|
||||
{
|
||||
}
|
||||
@@ -220,7 +222,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeBlockLength() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(194);
|
||||
return static_cast<std::uint16_t>(219);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint64_t sbeBlockAndHeaderLength() SBE_NOEXCEPT
|
||||
@@ -240,7 +242,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeSchemaVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(7);
|
||||
return static_cast<std::uint16_t>(8);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR const char *sbeSemanticType() SBE_NOEXCEPT
|
||||
@@ -286,6 +288,11 @@ public:
|
||||
return *this = ExecutionReportPendingCancel564(buffer, offset, bufferLength, actingBlockLength, actingVersion);
|
||||
}
|
||||
|
||||
ExecutionReportPendingCancel564 &sbeRewind()
|
||||
{
|
||||
return wrapForDecode(m_buffer, m_offset, m_actingBlockLength, m_actingVersion, m_bufferLength);
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::uint64_t sbePosition() const SBE_NOEXCEPT
|
||||
{
|
||||
return m_position;
|
||||
@@ -668,7 +675,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportPendingCancel564 &putExecID(const std::string& str)
|
||||
ExecutionReportPendingCancel564 &putExecID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 40)
|
||||
@@ -874,7 +881,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportPendingCancel564 &putSenderID(const std::string& str)
|
||||
ExecutionReportPendingCancel564 &putSenderID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -1080,7 +1087,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportPendingCancel564 &putClOrdID(const std::string& str)
|
||||
ExecutionReportPendingCancel564 &putClOrdID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -1688,7 +1695,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportPendingCancel564 &putLocation(const std::string& str)
|
||||
ExecutionReportPendingCancel564 &putLocation(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 5)
|
||||
@@ -3022,12 +3029,602 @@ public:
|
||||
return m_discretionPrice;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static const char *ReservationPriceMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
switch (metaAttribute)
|
||||
{
|
||||
case MetaAttribute::SEMANTIC_TYPE: return "Price";
|
||||
case MetaAttribute::PRESENCE: return "required";
|
||||
default: return "";
|
||||
}
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint16_t reservationPriceId() SBE_NOEXCEPT
|
||||
{
|
||||
return 9562;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint64_t reservationPriceSinceVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
SBE_NODISCARD bool reservationPriceInActingVersion() SBE_NOEXCEPT
|
||||
{
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic push
|
||||
#pragma clang diagnostic ignored "-Wtautological-compare"
|
||||
#endif
|
||||
return m_actingVersion >= reservationPriceSinceVersion();
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic pop
|
||||
#endif
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::size_t reservationPriceEncodingOffset() SBE_NOEXCEPT
|
||||
{
|
||||
return 194;
|
||||
}
|
||||
|
||||
private:
|
||||
PRICENULL9 m_reservationPrice;
|
||||
|
||||
public:
|
||||
SBE_NODISCARD PRICENULL9 &reservationPrice()
|
||||
{
|
||||
m_reservationPrice.wrap(m_buffer, m_offset + 194, m_actingVersion, m_bufferLength);
|
||||
return m_reservationPrice;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static const char *PriorityIndicatorMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
switch (metaAttribute)
|
||||
{
|
||||
case MetaAttribute::SEMANTIC_TYPE: return "int";
|
||||
case MetaAttribute::PRESENCE: return "optional";
|
||||
default: return "";
|
||||
}
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint16_t priorityIndicatorId() SBE_NOEXCEPT
|
||||
{
|
||||
return 638;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint64_t priorityIndicatorSinceVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
SBE_NODISCARD bool priorityIndicatorInActingVersion() SBE_NOEXCEPT
|
||||
{
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic push
|
||||
#pragma clang diagnostic ignored "-Wtautological-compare"
|
||||
#endif
|
||||
return m_actingVersion >= priorityIndicatorSinceVersion();
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic pop
|
||||
#endif
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::size_t priorityIndicatorEncodingOffset() SBE_NOEXCEPT
|
||||
{
|
||||
return 202;
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint8_t priorityIndicatorNullValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint8_t>(255);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint8_t priorityIndicatorMinValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint8_t>(0);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint8_t priorityIndicatorMaxValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint8_t>(254);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::size_t priorityIndicatorEncodingLength() SBE_NOEXCEPT
|
||||
{
|
||||
return 1;
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::uint8_t priorityIndicator() const SBE_NOEXCEPT
|
||||
{
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return static_cast<std::uint8_t>(255);
|
||||
}
|
||||
|
||||
std::uint8_t val;
|
||||
std::memcpy(&val, m_buffer + m_offset + 202, sizeof(std::uint8_t));
|
||||
return (val);
|
||||
}
|
||||
|
||||
ExecutionReportPendingCancel564 &priorityIndicator(const std::uint8_t value) SBE_NOEXCEPT
|
||||
{
|
||||
std::uint8_t val = (value);
|
||||
std::memcpy(m_buffer + m_offset + 202, &val, sizeof(std::uint8_t));
|
||||
return *this;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static const char *OrigOrderUserMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
switch (metaAttribute)
|
||||
{
|
||||
case MetaAttribute::SEMANTIC_TYPE: return "String";
|
||||
case MetaAttribute::PRESENCE: return "optional";
|
||||
default: return "";
|
||||
}
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint16_t origOrderUserId() SBE_NOEXCEPT
|
||||
{
|
||||
return 9937;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint64_t origOrderUserSinceVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
SBE_NODISCARD bool origOrderUserInActingVersion() SBE_NOEXCEPT
|
||||
{
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic push
|
||||
#pragma clang diagnostic ignored "-Wtautological-compare"
|
||||
#endif
|
||||
return m_actingVersion >= origOrderUserSinceVersion();
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic pop
|
||||
#endif
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::size_t origOrderUserEncodingOffset() SBE_NOEXCEPT
|
||||
{
|
||||
return 203;
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR char origOrderUserNullValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<char>(0);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR char origOrderUserMinValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<char>(32);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR char origOrderUserMaxValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<char>(126);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::size_t origOrderUserEncodingLength() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint64_t origOrderUserLength() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
SBE_NODISCARD const char *origOrderUser() const SBE_NOEXCEPT
|
||||
{
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
return m_buffer + m_offset + 203;
|
||||
}
|
||||
|
||||
SBE_NODISCARD char *origOrderUser() SBE_NOEXCEPT
|
||||
{
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
return m_buffer + m_offset + 203;
|
||||
}
|
||||
|
||||
SBE_NODISCARD char origOrderUser(const std::uint64_t index) const
|
||||
{
|
||||
if (index >= 8)
|
||||
{
|
||||
throw std::runtime_error("index out of range for origOrderUser [E104]");
|
||||
}
|
||||
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return static_cast<char>(0);
|
||||
}
|
||||
|
||||
char val;
|
||||
std::memcpy(&val, m_buffer + m_offset + 203 + (index * 1), sizeof(char));
|
||||
return (val);
|
||||
}
|
||||
|
||||
ExecutionReportPendingCancel564 &origOrderUser(const std::uint64_t index, const char value)
|
||||
{
|
||||
if (index >= 8)
|
||||
{
|
||||
throw std::runtime_error("index out of range for origOrderUser [E105]");
|
||||
}
|
||||
|
||||
char val = (value);
|
||||
std::memcpy(m_buffer + m_offset + 203 + (index * 1), &val, sizeof(char));
|
||||
return *this;
|
||||
}
|
||||
|
||||
std::uint64_t getOrigOrderUser(char *const dst, const std::uint64_t length) const
|
||||
{
|
||||
if (length > 8)
|
||||
{
|
||||
throw std::runtime_error("length too large for getOrigOrderUser [E106]");
|
||||
}
|
||||
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
std::memcpy(dst, m_buffer + m_offset + 203, sizeof(char) * static_cast<std::size_t>(length));
|
||||
return length;
|
||||
}
|
||||
|
||||
ExecutionReportPendingCancel564 &putOrigOrderUser(const char *const src) SBE_NOEXCEPT
|
||||
{
|
||||
std::memcpy(m_buffer + m_offset + 203, src, sizeof(char) * 8);
|
||||
return *this;
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::string getOrigOrderUserAsString() const
|
||||
{
|
||||
const char *buffer = m_buffer + m_offset + 203;
|
||||
std::size_t length = 0;
|
||||
|
||||
for (; length < 8 && *(buffer + length) != '\0'; ++length);
|
||||
std::string result(buffer, length);
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
std::string getOrigOrderUserAsJsonEscapedString()
|
||||
{
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return std::string("");
|
||||
}
|
||||
|
||||
std::ostringstream oss;
|
||||
std::string s = getOrigOrderUserAsString();
|
||||
|
||||
for (const auto c : s)
|
||||
{
|
||||
switch (c)
|
||||
{
|
||||
case '"': oss << "\\\""; break;
|
||||
case '\\': oss << "\\\\"; break;
|
||||
case '\b': oss << "\\b"; break;
|
||||
case '\f': oss << "\\f"; break;
|
||||
case '\n': oss << "\\n"; break;
|
||||
case '\r': oss << "\\r"; break;
|
||||
case '\t': oss << "\\t"; break;
|
||||
|
||||
default:
|
||||
if ('\x00' <= c && c <= '\x1f')
|
||||
{
|
||||
oss << "\\u" << std::hex << std::setw(4)
|
||||
<< std::setfill('0') << (int)(c);
|
||||
}
|
||||
else
|
||||
{
|
||||
oss << c;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return oss.str();
|
||||
}
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
SBE_NODISCARD std::string_view getOrigOrderUserAsStringView() const SBE_NOEXCEPT
|
||||
{
|
||||
const char *buffer = m_buffer + m_offset + 203;
|
||||
std::size_t length = 0;
|
||||
|
||||
for (; length < 8 && *(buffer + length) != '\0'; ++length);
|
||||
std::string_view result(buffer, length);
|
||||
|
||||
return result;
|
||||
}
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
ExecutionReportPendingCancel564 &putOrigOrderUser(const std::string_view str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 8)
|
||||
{
|
||||
throw std::runtime_error("string too large for putOrigOrderUser [E106]");
|
||||
}
|
||||
|
||||
std::memcpy(m_buffer + m_offset + 203, str.data(), srcLength);
|
||||
for (std::size_t start = srcLength; start < 8; ++start)
|
||||
{
|
||||
m_buffer[m_offset + 203 + start] = 0;
|
||||
}
|
||||
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportPendingCancel564 &putOrigOrderUser(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 8)
|
||||
{
|
||||
throw std::runtime_error("string too large for putOrigOrderUser [E106]");
|
||||
}
|
||||
|
||||
std::memcpy(m_buffer + m_offset + 203, str.c_str(), srcLength);
|
||||
for (std::size_t start = srcLength; start < 8; ++start)
|
||||
{
|
||||
m_buffer[m_offset + 203 + start] = 0;
|
||||
}
|
||||
|
||||
return *this;
|
||||
}
|
||||
#endif
|
||||
|
||||
SBE_NODISCARD static const char *CancelTextMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
switch (metaAttribute)
|
||||
{
|
||||
case MetaAttribute::SEMANTIC_TYPE: return "String";
|
||||
case MetaAttribute::PRESENCE: return "optional";
|
||||
default: return "";
|
||||
}
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint16_t cancelTextId() SBE_NOEXCEPT
|
||||
{
|
||||
return 2807;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint64_t cancelTextSinceVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
SBE_NODISCARD bool cancelTextInActingVersion() SBE_NOEXCEPT
|
||||
{
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic push
|
||||
#pragma clang diagnostic ignored "-Wtautological-compare"
|
||||
#endif
|
||||
return m_actingVersion >= cancelTextSinceVersion();
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic pop
|
||||
#endif
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::size_t cancelTextEncodingOffset() SBE_NOEXCEPT
|
||||
{
|
||||
return 211;
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR char cancelTextNullValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<char>(0);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR char cancelTextMinValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<char>(32);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR char cancelTextMaxValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<char>(126);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::size_t cancelTextEncodingLength() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint64_t cancelTextLength() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
SBE_NODISCARD const char *cancelText() const SBE_NOEXCEPT
|
||||
{
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
return m_buffer + m_offset + 211;
|
||||
}
|
||||
|
||||
SBE_NODISCARD char *cancelText() SBE_NOEXCEPT
|
||||
{
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
return m_buffer + m_offset + 211;
|
||||
}
|
||||
|
||||
SBE_NODISCARD char cancelText(const std::uint64_t index) const
|
||||
{
|
||||
if (index >= 8)
|
||||
{
|
||||
throw std::runtime_error("index out of range for cancelText [E104]");
|
||||
}
|
||||
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return static_cast<char>(0);
|
||||
}
|
||||
|
||||
char val;
|
||||
std::memcpy(&val, m_buffer + m_offset + 211 + (index * 1), sizeof(char));
|
||||
return (val);
|
||||
}
|
||||
|
||||
ExecutionReportPendingCancel564 &cancelText(const std::uint64_t index, const char value)
|
||||
{
|
||||
if (index >= 8)
|
||||
{
|
||||
throw std::runtime_error("index out of range for cancelText [E105]");
|
||||
}
|
||||
|
||||
char val = (value);
|
||||
std::memcpy(m_buffer + m_offset + 211 + (index * 1), &val, sizeof(char));
|
||||
return *this;
|
||||
}
|
||||
|
||||
std::uint64_t getCancelText(char *const dst, const std::uint64_t length) const
|
||||
{
|
||||
if (length > 8)
|
||||
{
|
||||
throw std::runtime_error("length too large for getCancelText [E106]");
|
||||
}
|
||||
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
std::memcpy(dst, m_buffer + m_offset + 211, sizeof(char) * static_cast<std::size_t>(length));
|
||||
return length;
|
||||
}
|
||||
|
||||
ExecutionReportPendingCancel564 &putCancelText(const char *const src) SBE_NOEXCEPT
|
||||
{
|
||||
std::memcpy(m_buffer + m_offset + 211, src, sizeof(char) * 8);
|
||||
return *this;
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::string getCancelTextAsString() const
|
||||
{
|
||||
const char *buffer = m_buffer + m_offset + 211;
|
||||
std::size_t length = 0;
|
||||
|
||||
for (; length < 8 && *(buffer + length) != '\0'; ++length);
|
||||
std::string result(buffer, length);
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
std::string getCancelTextAsJsonEscapedString()
|
||||
{
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return std::string("");
|
||||
}
|
||||
|
||||
std::ostringstream oss;
|
||||
std::string s = getCancelTextAsString();
|
||||
|
||||
for (const auto c : s)
|
||||
{
|
||||
switch (c)
|
||||
{
|
||||
case '"': oss << "\\\""; break;
|
||||
case '\\': oss << "\\\\"; break;
|
||||
case '\b': oss << "\\b"; break;
|
||||
case '\f': oss << "\\f"; break;
|
||||
case '\n': oss << "\\n"; break;
|
||||
case '\r': oss << "\\r"; break;
|
||||
case '\t': oss << "\\t"; break;
|
||||
|
||||
default:
|
||||
if ('\x00' <= c && c <= '\x1f')
|
||||
{
|
||||
oss << "\\u" << std::hex << std::setw(4)
|
||||
<< std::setfill('0') << (int)(c);
|
||||
}
|
||||
else
|
||||
{
|
||||
oss << c;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return oss.str();
|
||||
}
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
SBE_NODISCARD std::string_view getCancelTextAsStringView() const SBE_NOEXCEPT
|
||||
{
|
||||
const char *buffer = m_buffer + m_offset + 211;
|
||||
std::size_t length = 0;
|
||||
|
||||
for (; length < 8 && *(buffer + length) != '\0'; ++length);
|
||||
std::string_view result(buffer, length);
|
||||
|
||||
return result;
|
||||
}
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
ExecutionReportPendingCancel564 &putCancelText(const std::string_view str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 8)
|
||||
{
|
||||
throw std::runtime_error("string too large for putCancelText [E106]");
|
||||
}
|
||||
|
||||
std::memcpy(m_buffer + m_offset + 211, str.data(), srcLength);
|
||||
for (std::size_t start = srcLength; start < 8; ++start)
|
||||
{
|
||||
m_buffer[m_offset + 211 + start] = 0;
|
||||
}
|
||||
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportPendingCancel564 &putCancelText(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 8)
|
||||
{
|
||||
throw std::runtime_error("string too large for putCancelText [E106]");
|
||||
}
|
||||
|
||||
std::memcpy(m_buffer + m_offset + 211, str.c_str(), srcLength);
|
||||
for (std::size_t start = srcLength; start < 8; ++start)
|
||||
{
|
||||
m_buffer[m_offset + 211 + start] = 0;
|
||||
}
|
||||
|
||||
return *this;
|
||||
}
|
||||
#endif
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, ExecutionReportPendingCancel564 _writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, ExecutionReportPendingCancel564 _writer)
|
||||
{
|
||||
ExecutionReportPendingCancel564 writer(_writer.m_buffer, _writer.m_offset,
|
||||
_writer.m_bufferLength, _writer.sbeBlockLength(), _writer.m_actingVersion);
|
||||
ExecutionReportPendingCancel564 writer(
|
||||
_writer.m_buffer,
|
||||
_writer.m_offset,
|
||||
_writer.m_bufferLength,
|
||||
_writer.m_actingBlockLength,
|
||||
_writer.m_actingVersion);
|
||||
|
||||
builder << '{';
|
||||
builder << R"("Name": "ExecutionReportPendingCancel564", )";
|
||||
builder << R"("sbeTemplateId": )";
|
||||
@@ -3149,6 +3746,31 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
builder << R"("DiscretionPrice": )";
|
||||
builder << writer.discretionPrice();
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("ReservationPrice": )";
|
||||
if (writer.reservationPriceInActingVersion())
|
||||
{
|
||||
builder << writer.reservationPrice();
|
||||
}
|
||||
else
|
||||
{
|
||||
builder << "{}";
|
||||
}
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("PriorityIndicator": )";
|
||||
builder << +writer.priorityIndicator();
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("OrigOrderUser": )";
|
||||
builder << '"' <<
|
||||
writer.getOrigOrderUserAsJsonEscapedString().c_str() << '"';
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("CancelText": )";
|
||||
builder << '"' <<
|
||||
writer.getCancelTextAsJsonEscapedString().c_str() << '"';
|
||||
|
||||
builder << '}';
|
||||
|
||||
return builder;
|
||||
|
||||
@@ -70,11 +70,11 @@
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (__builtin_expect(exp, c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
@@ -156,6 +156,7 @@ private:
|
||||
std::uint64_t m_bufferLength = 0;
|
||||
std::uint64_t m_offset = 0;
|
||||
std::uint64_t m_position = 0;
|
||||
std::uint64_t m_actingBlockLength = 0;
|
||||
std::uint64_t m_actingVersion = 0;
|
||||
|
||||
inline std::uint64_t *sbePositionPtr() SBE_NOEXCEPT
|
||||
@@ -164,10 +165,10 @@ private:
|
||||
}
|
||||
|
||||
public:
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(195);
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(196);
|
||||
static const std::uint16_t SBE_TEMPLATE_ID = static_cast<std::uint16_t>(565);
|
||||
static const std::uint16_t SBE_SCHEMA_ID = static_cast<std::uint16_t>(8);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(7);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(8);
|
||||
|
||||
enum MetaAttribute
|
||||
{
|
||||
@@ -200,6 +201,7 @@ public:
|
||||
m_bufferLength(bufferLength),
|
||||
m_offset(offset),
|
||||
m_position(sbeCheckPosition(offset + actingBlockLength)),
|
||||
m_actingBlockLength(actingBlockLength),
|
||||
m_actingVersion(actingVersion)
|
||||
{
|
||||
}
|
||||
@@ -220,7 +222,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeBlockLength() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(195);
|
||||
return static_cast<std::uint16_t>(196);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint64_t sbeBlockAndHeaderLength() SBE_NOEXCEPT
|
||||
@@ -240,7 +242,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeSchemaVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(7);
|
||||
return static_cast<std::uint16_t>(8);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR const char *sbeSemanticType() SBE_NOEXCEPT
|
||||
@@ -286,6 +288,11 @@ public:
|
||||
return *this = ExecutionReportPendingReplace565(buffer, offset, bufferLength, actingBlockLength, actingVersion);
|
||||
}
|
||||
|
||||
ExecutionReportPendingReplace565 &sbeRewind()
|
||||
{
|
||||
return wrapForDecode(m_buffer, m_offset, m_actingBlockLength, m_actingVersion, m_bufferLength);
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::uint64_t sbePosition() const SBE_NOEXCEPT
|
||||
{
|
||||
return m_position;
|
||||
@@ -668,7 +675,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportPendingReplace565 &putExecID(const std::string& str)
|
||||
ExecutionReportPendingReplace565 &putExecID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 40)
|
||||
@@ -874,7 +881,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportPendingReplace565 &putSenderID(const std::string& str)
|
||||
ExecutionReportPendingReplace565 &putSenderID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -1080,7 +1087,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportPendingReplace565 &putClOrdID(const std::string& str)
|
||||
ExecutionReportPendingReplace565 &putClOrdID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -1688,7 +1695,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportPendingReplace565 &putLocation(const std::string& str)
|
||||
ExecutionReportPendingReplace565 &putLocation(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 5)
|
||||
@@ -3085,12 +3092,93 @@ public:
|
||||
return m_discretionPrice;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static const char *PriorityIndicatorMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
switch (metaAttribute)
|
||||
{
|
||||
case MetaAttribute::SEMANTIC_TYPE: return "int";
|
||||
case MetaAttribute::PRESENCE: return "optional";
|
||||
default: return "";
|
||||
}
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint16_t priorityIndicatorId() SBE_NOEXCEPT
|
||||
{
|
||||
return 638;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint64_t priorityIndicatorSinceVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
SBE_NODISCARD bool priorityIndicatorInActingVersion() SBE_NOEXCEPT
|
||||
{
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic push
|
||||
#pragma clang diagnostic ignored "-Wtautological-compare"
|
||||
#endif
|
||||
return m_actingVersion >= priorityIndicatorSinceVersion();
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic pop
|
||||
#endif
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::size_t priorityIndicatorEncodingOffset() SBE_NOEXCEPT
|
||||
{
|
||||
return 195;
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint8_t priorityIndicatorNullValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint8_t>(255);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint8_t priorityIndicatorMinValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint8_t>(0);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint8_t priorityIndicatorMaxValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint8_t>(254);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::size_t priorityIndicatorEncodingLength() SBE_NOEXCEPT
|
||||
{
|
||||
return 1;
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::uint8_t priorityIndicator() const SBE_NOEXCEPT
|
||||
{
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return static_cast<std::uint8_t>(255);
|
||||
}
|
||||
|
||||
std::uint8_t val;
|
||||
std::memcpy(&val, m_buffer + m_offset + 195, sizeof(std::uint8_t));
|
||||
return (val);
|
||||
}
|
||||
|
||||
ExecutionReportPendingReplace565 &priorityIndicator(const std::uint8_t value) SBE_NOEXCEPT
|
||||
{
|
||||
std::uint8_t val = (value);
|
||||
std::memcpy(m_buffer + m_offset + 195, &val, sizeof(std::uint8_t));
|
||||
return *this;
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, ExecutionReportPendingReplace565 _writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, ExecutionReportPendingReplace565 _writer)
|
||||
{
|
||||
ExecutionReportPendingReplace565 writer(_writer.m_buffer, _writer.m_offset,
|
||||
_writer.m_bufferLength, _writer.sbeBlockLength(), _writer.m_actingVersion);
|
||||
ExecutionReportPendingReplace565 writer(
|
||||
_writer.m_buffer,
|
||||
_writer.m_offset,
|
||||
_writer.m_bufferLength,
|
||||
_writer.m_actingBlockLength,
|
||||
_writer.m_actingVersion);
|
||||
|
||||
builder << '{';
|
||||
builder << R"("Name": "ExecutionReportPendingReplace565", )";
|
||||
builder << R"("sbeTemplateId": )";
|
||||
@@ -3216,6 +3304,10 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
builder << R"("DiscretionPrice": )";
|
||||
builder << writer.discretionPrice();
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("PriorityIndicator": )";
|
||||
builder << +writer.priorityIndicator();
|
||||
|
||||
builder << '}';
|
||||
|
||||
return builder;
|
||||
|
||||
@@ -70,11 +70,11 @@
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (__builtin_expect(exp, c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
@@ -156,6 +156,7 @@ private:
|
||||
std::uint64_t m_bufferLength = 0;
|
||||
std::uint64_t m_offset = 0;
|
||||
std::uint64_t m_position = 0;
|
||||
std::uint64_t m_actingBlockLength = 0;
|
||||
std::uint64_t m_actingVersion = 0;
|
||||
|
||||
inline std::uint64_t *sbePositionPtr() SBE_NOEXCEPT
|
||||
@@ -164,10 +165,10 @@ private:
|
||||
}
|
||||
|
||||
public:
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(475);
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(483);
|
||||
static const std::uint16_t SBE_TEMPLATE_ID = static_cast<std::uint16_t>(523);
|
||||
static const std::uint16_t SBE_SCHEMA_ID = static_cast<std::uint16_t>(8);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(7);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(8);
|
||||
|
||||
enum MetaAttribute
|
||||
{
|
||||
@@ -200,6 +201,7 @@ public:
|
||||
m_bufferLength(bufferLength),
|
||||
m_offset(offset),
|
||||
m_position(sbeCheckPosition(offset + actingBlockLength)),
|
||||
m_actingBlockLength(actingBlockLength),
|
||||
m_actingVersion(actingVersion)
|
||||
{
|
||||
}
|
||||
@@ -220,7 +222,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeBlockLength() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(475);
|
||||
return static_cast<std::uint16_t>(483);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint64_t sbeBlockAndHeaderLength() SBE_NOEXCEPT
|
||||
@@ -240,7 +242,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeSchemaVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(7);
|
||||
return static_cast<std::uint16_t>(8);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR const char *sbeSemanticType() SBE_NOEXCEPT
|
||||
@@ -286,6 +288,11 @@ public:
|
||||
return *this = ExecutionReportReject523(buffer, offset, bufferLength, actingBlockLength, actingVersion);
|
||||
}
|
||||
|
||||
ExecutionReportReject523 &sbeRewind()
|
||||
{
|
||||
return wrapForDecode(m_buffer, m_offset, m_actingBlockLength, m_actingVersion, m_bufferLength);
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::uint64_t sbePosition() const SBE_NOEXCEPT
|
||||
{
|
||||
return m_position;
|
||||
@@ -668,7 +675,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportReject523 &putText(const std::string& str)
|
||||
ExecutionReportReject523 &putText(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 256)
|
||||
@@ -874,7 +881,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportReject523 &putExecID(const std::string& str)
|
||||
ExecutionReportReject523 &putExecID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 40)
|
||||
@@ -1080,7 +1087,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportReject523 &putSenderID(const std::string& str)
|
||||
ExecutionReportReject523 &putSenderID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -1286,7 +1293,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportReject523 &putClOrdID(const std::string& str)
|
||||
ExecutionReportReject523 &putClOrdID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -2083,7 +2090,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportReject523 &putLocation(const std::string& str)
|
||||
ExecutionReportReject523 &putLocation(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 5)
|
||||
@@ -3724,12 +3731,64 @@ public:
|
||||
return m_discretionPrice;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static const char *ReservationPriceMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
switch (metaAttribute)
|
||||
{
|
||||
case MetaAttribute::SEMANTIC_TYPE: return "Price";
|
||||
case MetaAttribute::PRESENCE: return "required";
|
||||
default: return "";
|
||||
}
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint16_t reservationPriceId() SBE_NOEXCEPT
|
||||
{
|
||||
return 9562;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint64_t reservationPriceSinceVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
SBE_NODISCARD bool reservationPriceInActingVersion() SBE_NOEXCEPT
|
||||
{
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic push
|
||||
#pragma clang diagnostic ignored "-Wtautological-compare"
|
||||
#endif
|
||||
return m_actingVersion >= reservationPriceSinceVersion();
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic pop
|
||||
#endif
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::size_t reservationPriceEncodingOffset() SBE_NOEXCEPT
|
||||
{
|
||||
return 475;
|
||||
}
|
||||
|
||||
private:
|
||||
PRICENULL9 m_reservationPrice;
|
||||
|
||||
public:
|
||||
SBE_NODISCARD PRICENULL9 &reservationPrice()
|
||||
{
|
||||
m_reservationPrice.wrap(m_buffer, m_offset + 475, m_actingVersion, m_bufferLength);
|
||||
return m_reservationPrice;
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, ExecutionReportReject523 _writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, ExecutionReportReject523 _writer)
|
||||
{
|
||||
ExecutionReportReject523 writer(_writer.m_buffer, _writer.m_offset,
|
||||
_writer.m_bufferLength, _writer.sbeBlockLength(), _writer.m_actingVersion);
|
||||
ExecutionReportReject523 writer(
|
||||
_writer.m_buffer,
|
||||
_writer.m_offset,
|
||||
_writer.m_bufferLength,
|
||||
_writer.m_actingBlockLength,
|
||||
_writer.m_actingVersion);
|
||||
|
||||
builder << '{';
|
||||
builder << R"("Name": "ExecutionReportReject523", )";
|
||||
builder << R"("sbeTemplateId": )";
|
||||
@@ -3886,7 +3945,25 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("DiscretionPrice": )";
|
||||
builder << writer.discretionPrice();
|
||||
if (writer.discretionPriceInActingVersion())
|
||||
{
|
||||
builder << writer.discretionPrice();
|
||||
}
|
||||
else
|
||||
{
|
||||
builder << "{}";
|
||||
}
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("ReservationPrice": )";
|
||||
if (writer.reservationPriceInActingVersion())
|
||||
{
|
||||
builder << writer.reservationPrice();
|
||||
}
|
||||
else
|
||||
{
|
||||
builder << "{}";
|
||||
}
|
||||
|
||||
builder << '}';
|
||||
|
||||
|
||||
@@ -70,11 +70,11 @@
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (__builtin_expect(exp, c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
@@ -156,6 +156,7 @@ private:
|
||||
std::uint64_t m_bufferLength = 0;
|
||||
std::uint64_t m_offset = 0;
|
||||
std::uint64_t m_position = 0;
|
||||
std::uint64_t m_actingBlockLength = 0;
|
||||
std::uint64_t m_actingVersion = 0;
|
||||
|
||||
inline std::uint64_t *sbePositionPtr() SBE_NOEXCEPT
|
||||
@@ -164,10 +165,10 @@ private:
|
||||
}
|
||||
|
||||
public:
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(488);
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(513);
|
||||
static const std::uint16_t SBE_TEMPLATE_ID = static_cast<std::uint16_t>(532);
|
||||
static const std::uint16_t SBE_SCHEMA_ID = static_cast<std::uint16_t>(8);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(7);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(8);
|
||||
|
||||
enum MetaAttribute
|
||||
{
|
||||
@@ -200,6 +201,7 @@ public:
|
||||
m_bufferLength(bufferLength),
|
||||
m_offset(offset),
|
||||
m_position(sbeCheckPosition(offset + actingBlockLength)),
|
||||
m_actingBlockLength(actingBlockLength),
|
||||
m_actingVersion(actingVersion)
|
||||
{
|
||||
}
|
||||
@@ -220,7 +222,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeBlockLength() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(488);
|
||||
return static_cast<std::uint16_t>(513);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint64_t sbeBlockAndHeaderLength() SBE_NOEXCEPT
|
||||
@@ -240,7 +242,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeSchemaVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(7);
|
||||
return static_cast<std::uint16_t>(8);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR const char *sbeSemanticType() SBE_NOEXCEPT
|
||||
@@ -286,6 +288,11 @@ public:
|
||||
return *this = ExecutionReportStatus532(buffer, offset, bufferLength, actingBlockLength, actingVersion);
|
||||
}
|
||||
|
||||
ExecutionReportStatus532 &sbeRewind()
|
||||
{
|
||||
return wrapForDecode(m_buffer, m_offset, m_actingBlockLength, m_actingVersion, m_bufferLength);
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::uint64_t sbePosition() const SBE_NOEXCEPT
|
||||
{
|
||||
return m_position;
|
||||
@@ -668,7 +675,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportStatus532 &putText(const std::string& str)
|
||||
ExecutionReportStatus532 &putText(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 256)
|
||||
@@ -874,7 +881,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportStatus532 &putExecID(const std::string& str)
|
||||
ExecutionReportStatus532 &putExecID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 40)
|
||||
@@ -1080,7 +1087,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportStatus532 &putSenderID(const std::string& str)
|
||||
ExecutionReportStatus532 &putSenderID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -1286,7 +1293,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportStatus532 &putClOrdID(const std::string& str)
|
||||
ExecutionReportStatus532 &putClOrdID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -2225,7 +2232,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportStatus532 &putLocation(const std::string& str)
|
||||
ExecutionReportStatus532 &putLocation(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 5)
|
||||
@@ -3728,12 +3735,602 @@ public:
|
||||
return m_discretionPrice;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static const char *ReservationPriceMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
switch (metaAttribute)
|
||||
{
|
||||
case MetaAttribute::SEMANTIC_TYPE: return "Price";
|
||||
case MetaAttribute::PRESENCE: return "required";
|
||||
default: return "";
|
||||
}
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint16_t reservationPriceId() SBE_NOEXCEPT
|
||||
{
|
||||
return 9562;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint64_t reservationPriceSinceVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
SBE_NODISCARD bool reservationPriceInActingVersion() SBE_NOEXCEPT
|
||||
{
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic push
|
||||
#pragma clang diagnostic ignored "-Wtautological-compare"
|
||||
#endif
|
||||
return m_actingVersion >= reservationPriceSinceVersion();
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic pop
|
||||
#endif
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::size_t reservationPriceEncodingOffset() SBE_NOEXCEPT
|
||||
{
|
||||
return 488;
|
||||
}
|
||||
|
||||
private:
|
||||
PRICENULL9 m_reservationPrice;
|
||||
|
||||
public:
|
||||
SBE_NODISCARD PRICENULL9 &reservationPrice()
|
||||
{
|
||||
m_reservationPrice.wrap(m_buffer, m_offset + 488, m_actingVersion, m_bufferLength);
|
||||
return m_reservationPrice;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static const char *PriorityIndicatorMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
switch (metaAttribute)
|
||||
{
|
||||
case MetaAttribute::SEMANTIC_TYPE: return "int";
|
||||
case MetaAttribute::PRESENCE: return "optional";
|
||||
default: return "";
|
||||
}
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint16_t priorityIndicatorId() SBE_NOEXCEPT
|
||||
{
|
||||
return 638;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint64_t priorityIndicatorSinceVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
SBE_NODISCARD bool priorityIndicatorInActingVersion() SBE_NOEXCEPT
|
||||
{
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic push
|
||||
#pragma clang diagnostic ignored "-Wtautological-compare"
|
||||
#endif
|
||||
return m_actingVersion >= priorityIndicatorSinceVersion();
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic pop
|
||||
#endif
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::size_t priorityIndicatorEncodingOffset() SBE_NOEXCEPT
|
||||
{
|
||||
return 496;
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint8_t priorityIndicatorNullValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint8_t>(255);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint8_t priorityIndicatorMinValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint8_t>(0);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint8_t priorityIndicatorMaxValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint8_t>(254);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::size_t priorityIndicatorEncodingLength() SBE_NOEXCEPT
|
||||
{
|
||||
return 1;
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::uint8_t priorityIndicator() const SBE_NOEXCEPT
|
||||
{
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return static_cast<std::uint8_t>(255);
|
||||
}
|
||||
|
||||
std::uint8_t val;
|
||||
std::memcpy(&val, m_buffer + m_offset + 496, sizeof(std::uint8_t));
|
||||
return (val);
|
||||
}
|
||||
|
||||
ExecutionReportStatus532 &priorityIndicator(const std::uint8_t value) SBE_NOEXCEPT
|
||||
{
|
||||
std::uint8_t val = (value);
|
||||
std::memcpy(m_buffer + m_offset + 496, &val, sizeof(std::uint8_t));
|
||||
return *this;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static const char *OrigOrderUserMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
switch (metaAttribute)
|
||||
{
|
||||
case MetaAttribute::SEMANTIC_TYPE: return "String";
|
||||
case MetaAttribute::PRESENCE: return "optional";
|
||||
default: return "";
|
||||
}
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint16_t origOrderUserId() SBE_NOEXCEPT
|
||||
{
|
||||
return 9937;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint64_t origOrderUserSinceVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
SBE_NODISCARD bool origOrderUserInActingVersion() SBE_NOEXCEPT
|
||||
{
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic push
|
||||
#pragma clang diagnostic ignored "-Wtautological-compare"
|
||||
#endif
|
||||
return m_actingVersion >= origOrderUserSinceVersion();
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic pop
|
||||
#endif
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::size_t origOrderUserEncodingOffset() SBE_NOEXCEPT
|
||||
{
|
||||
return 497;
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR char origOrderUserNullValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<char>(0);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR char origOrderUserMinValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<char>(32);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR char origOrderUserMaxValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<char>(126);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::size_t origOrderUserEncodingLength() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint64_t origOrderUserLength() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
SBE_NODISCARD const char *origOrderUser() const SBE_NOEXCEPT
|
||||
{
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
return m_buffer + m_offset + 497;
|
||||
}
|
||||
|
||||
SBE_NODISCARD char *origOrderUser() SBE_NOEXCEPT
|
||||
{
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
return m_buffer + m_offset + 497;
|
||||
}
|
||||
|
||||
SBE_NODISCARD char origOrderUser(const std::uint64_t index) const
|
||||
{
|
||||
if (index >= 8)
|
||||
{
|
||||
throw std::runtime_error("index out of range for origOrderUser [E104]");
|
||||
}
|
||||
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return static_cast<char>(0);
|
||||
}
|
||||
|
||||
char val;
|
||||
std::memcpy(&val, m_buffer + m_offset + 497 + (index * 1), sizeof(char));
|
||||
return (val);
|
||||
}
|
||||
|
||||
ExecutionReportStatus532 &origOrderUser(const std::uint64_t index, const char value)
|
||||
{
|
||||
if (index >= 8)
|
||||
{
|
||||
throw std::runtime_error("index out of range for origOrderUser [E105]");
|
||||
}
|
||||
|
||||
char val = (value);
|
||||
std::memcpy(m_buffer + m_offset + 497 + (index * 1), &val, sizeof(char));
|
||||
return *this;
|
||||
}
|
||||
|
||||
std::uint64_t getOrigOrderUser(char *const dst, const std::uint64_t length) const
|
||||
{
|
||||
if (length > 8)
|
||||
{
|
||||
throw std::runtime_error("length too large for getOrigOrderUser [E106]");
|
||||
}
|
||||
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
std::memcpy(dst, m_buffer + m_offset + 497, sizeof(char) * static_cast<std::size_t>(length));
|
||||
return length;
|
||||
}
|
||||
|
||||
ExecutionReportStatus532 &putOrigOrderUser(const char *const src) SBE_NOEXCEPT
|
||||
{
|
||||
std::memcpy(m_buffer + m_offset + 497, src, sizeof(char) * 8);
|
||||
return *this;
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::string getOrigOrderUserAsString() const
|
||||
{
|
||||
const char *buffer = m_buffer + m_offset + 497;
|
||||
std::size_t length = 0;
|
||||
|
||||
for (; length < 8 && *(buffer + length) != '\0'; ++length);
|
||||
std::string result(buffer, length);
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
std::string getOrigOrderUserAsJsonEscapedString()
|
||||
{
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return std::string("");
|
||||
}
|
||||
|
||||
std::ostringstream oss;
|
||||
std::string s = getOrigOrderUserAsString();
|
||||
|
||||
for (const auto c : s)
|
||||
{
|
||||
switch (c)
|
||||
{
|
||||
case '"': oss << "\\\""; break;
|
||||
case '\\': oss << "\\\\"; break;
|
||||
case '\b': oss << "\\b"; break;
|
||||
case '\f': oss << "\\f"; break;
|
||||
case '\n': oss << "\\n"; break;
|
||||
case '\r': oss << "\\r"; break;
|
||||
case '\t': oss << "\\t"; break;
|
||||
|
||||
default:
|
||||
if ('\x00' <= c && c <= '\x1f')
|
||||
{
|
||||
oss << "\\u" << std::hex << std::setw(4)
|
||||
<< std::setfill('0') << (int)(c);
|
||||
}
|
||||
else
|
||||
{
|
||||
oss << c;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return oss.str();
|
||||
}
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
SBE_NODISCARD std::string_view getOrigOrderUserAsStringView() const SBE_NOEXCEPT
|
||||
{
|
||||
const char *buffer = m_buffer + m_offset + 497;
|
||||
std::size_t length = 0;
|
||||
|
||||
for (; length < 8 && *(buffer + length) != '\0'; ++length);
|
||||
std::string_view result(buffer, length);
|
||||
|
||||
return result;
|
||||
}
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
ExecutionReportStatus532 &putOrigOrderUser(const std::string_view str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 8)
|
||||
{
|
||||
throw std::runtime_error("string too large for putOrigOrderUser [E106]");
|
||||
}
|
||||
|
||||
std::memcpy(m_buffer + m_offset + 497, str.data(), srcLength);
|
||||
for (std::size_t start = srcLength; start < 8; ++start)
|
||||
{
|
||||
m_buffer[m_offset + 497 + start] = 0;
|
||||
}
|
||||
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportStatus532 &putOrigOrderUser(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 8)
|
||||
{
|
||||
throw std::runtime_error("string too large for putOrigOrderUser [E106]");
|
||||
}
|
||||
|
||||
std::memcpy(m_buffer + m_offset + 497, str.c_str(), srcLength);
|
||||
for (std::size_t start = srcLength; start < 8; ++start)
|
||||
{
|
||||
m_buffer[m_offset + 497 + start] = 0;
|
||||
}
|
||||
|
||||
return *this;
|
||||
}
|
||||
#endif
|
||||
|
||||
SBE_NODISCARD static const char *CancelTextMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
switch (metaAttribute)
|
||||
{
|
||||
case MetaAttribute::SEMANTIC_TYPE: return "String";
|
||||
case MetaAttribute::PRESENCE: return "optional";
|
||||
default: return "";
|
||||
}
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint16_t cancelTextId() SBE_NOEXCEPT
|
||||
{
|
||||
return 2807;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint64_t cancelTextSinceVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
SBE_NODISCARD bool cancelTextInActingVersion() SBE_NOEXCEPT
|
||||
{
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic push
|
||||
#pragma clang diagnostic ignored "-Wtautological-compare"
|
||||
#endif
|
||||
return m_actingVersion >= cancelTextSinceVersion();
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic pop
|
||||
#endif
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::size_t cancelTextEncodingOffset() SBE_NOEXCEPT
|
||||
{
|
||||
return 505;
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR char cancelTextNullValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<char>(0);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR char cancelTextMinValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<char>(32);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR char cancelTextMaxValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<char>(126);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::size_t cancelTextEncodingLength() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint64_t cancelTextLength() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
SBE_NODISCARD const char *cancelText() const SBE_NOEXCEPT
|
||||
{
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
return m_buffer + m_offset + 505;
|
||||
}
|
||||
|
||||
SBE_NODISCARD char *cancelText() SBE_NOEXCEPT
|
||||
{
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
return m_buffer + m_offset + 505;
|
||||
}
|
||||
|
||||
SBE_NODISCARD char cancelText(const std::uint64_t index) const
|
||||
{
|
||||
if (index >= 8)
|
||||
{
|
||||
throw std::runtime_error("index out of range for cancelText [E104]");
|
||||
}
|
||||
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return static_cast<char>(0);
|
||||
}
|
||||
|
||||
char val;
|
||||
std::memcpy(&val, m_buffer + m_offset + 505 + (index * 1), sizeof(char));
|
||||
return (val);
|
||||
}
|
||||
|
||||
ExecutionReportStatus532 &cancelText(const std::uint64_t index, const char value)
|
||||
{
|
||||
if (index >= 8)
|
||||
{
|
||||
throw std::runtime_error("index out of range for cancelText [E105]");
|
||||
}
|
||||
|
||||
char val = (value);
|
||||
std::memcpy(m_buffer + m_offset + 505 + (index * 1), &val, sizeof(char));
|
||||
return *this;
|
||||
}
|
||||
|
||||
std::uint64_t getCancelText(char *const dst, const std::uint64_t length) const
|
||||
{
|
||||
if (length > 8)
|
||||
{
|
||||
throw std::runtime_error("length too large for getCancelText [E106]");
|
||||
}
|
||||
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
std::memcpy(dst, m_buffer + m_offset + 505, sizeof(char) * static_cast<std::size_t>(length));
|
||||
return length;
|
||||
}
|
||||
|
||||
ExecutionReportStatus532 &putCancelText(const char *const src) SBE_NOEXCEPT
|
||||
{
|
||||
std::memcpy(m_buffer + m_offset + 505, src, sizeof(char) * 8);
|
||||
return *this;
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::string getCancelTextAsString() const
|
||||
{
|
||||
const char *buffer = m_buffer + m_offset + 505;
|
||||
std::size_t length = 0;
|
||||
|
||||
for (; length < 8 && *(buffer + length) != '\0'; ++length);
|
||||
std::string result(buffer, length);
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
std::string getCancelTextAsJsonEscapedString()
|
||||
{
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return std::string("");
|
||||
}
|
||||
|
||||
std::ostringstream oss;
|
||||
std::string s = getCancelTextAsString();
|
||||
|
||||
for (const auto c : s)
|
||||
{
|
||||
switch (c)
|
||||
{
|
||||
case '"': oss << "\\\""; break;
|
||||
case '\\': oss << "\\\\"; break;
|
||||
case '\b': oss << "\\b"; break;
|
||||
case '\f': oss << "\\f"; break;
|
||||
case '\n': oss << "\\n"; break;
|
||||
case '\r': oss << "\\r"; break;
|
||||
case '\t': oss << "\\t"; break;
|
||||
|
||||
default:
|
||||
if ('\x00' <= c && c <= '\x1f')
|
||||
{
|
||||
oss << "\\u" << std::hex << std::setw(4)
|
||||
<< std::setfill('0') << (int)(c);
|
||||
}
|
||||
else
|
||||
{
|
||||
oss << c;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return oss.str();
|
||||
}
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
SBE_NODISCARD std::string_view getCancelTextAsStringView() const SBE_NOEXCEPT
|
||||
{
|
||||
const char *buffer = m_buffer + m_offset + 505;
|
||||
std::size_t length = 0;
|
||||
|
||||
for (; length < 8 && *(buffer + length) != '\0'; ++length);
|
||||
std::string_view result(buffer, length);
|
||||
|
||||
return result;
|
||||
}
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
ExecutionReportStatus532 &putCancelText(const std::string_view str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 8)
|
||||
{
|
||||
throw std::runtime_error("string too large for putCancelText [E106]");
|
||||
}
|
||||
|
||||
std::memcpy(m_buffer + m_offset + 505, str.data(), srcLength);
|
||||
for (std::size_t start = srcLength; start < 8; ++start)
|
||||
{
|
||||
m_buffer[m_offset + 505 + start] = 0;
|
||||
}
|
||||
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportStatus532 &putCancelText(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 8)
|
||||
{
|
||||
throw std::runtime_error("string too large for putCancelText [E106]");
|
||||
}
|
||||
|
||||
std::memcpy(m_buffer + m_offset + 505, str.c_str(), srcLength);
|
||||
for (std::size_t start = srcLength; start < 8; ++start)
|
||||
{
|
||||
m_buffer[m_offset + 505 + start] = 0;
|
||||
}
|
||||
|
||||
return *this;
|
||||
}
|
||||
#endif
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, ExecutionReportStatus532 _writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, ExecutionReportStatus532 _writer)
|
||||
{
|
||||
ExecutionReportStatus532 writer(_writer.m_buffer, _writer.m_offset,
|
||||
_writer.m_bufferLength, _writer.sbeBlockLength(), _writer.m_actingVersion);
|
||||
ExecutionReportStatus532 writer(
|
||||
_writer.m_buffer,
|
||||
_writer.m_offset,
|
||||
_writer.m_bufferLength,
|
||||
_writer.m_actingBlockLength,
|
||||
_writer.m_actingVersion);
|
||||
|
||||
builder << '{';
|
||||
builder << R"("Name": "ExecutionReportStatus532", )";
|
||||
builder << R"("sbeTemplateId": )";
|
||||
@@ -3898,7 +4495,39 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("DiscretionPrice": )";
|
||||
builder << writer.discretionPrice();
|
||||
if (writer.discretionPriceInActingVersion())
|
||||
{
|
||||
builder << writer.discretionPrice();
|
||||
}
|
||||
else
|
||||
{
|
||||
builder << "{}";
|
||||
}
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("ReservationPrice": )";
|
||||
if (writer.reservationPriceInActingVersion())
|
||||
{
|
||||
builder << writer.reservationPrice();
|
||||
}
|
||||
else
|
||||
{
|
||||
builder << "{}";
|
||||
}
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("PriorityIndicator": )";
|
||||
builder << +writer.priorityIndicator();
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("OrigOrderUser": )";
|
||||
builder << '"' <<
|
||||
writer.getOrigOrderUserAsJsonEscapedString().c_str() << '"';
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("CancelText": )";
|
||||
builder << '"' <<
|
||||
writer.getCancelTextAsJsonEscapedString().c_str() << '"';
|
||||
|
||||
builder << '}';
|
||||
|
||||
|
||||
+109
-75
@@ -70,11 +70,11 @@
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (__builtin_expect(exp, c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
@@ -156,6 +156,7 @@ private:
|
||||
std::uint64_t m_bufferLength = 0;
|
||||
std::uint64_t m_offset = 0;
|
||||
std::uint64_t m_position = 0;
|
||||
std::uint64_t m_actingBlockLength = 0;
|
||||
std::uint64_t m_actingVersion = 0;
|
||||
|
||||
inline std::uint64_t *sbePositionPtr() SBE_NOEXCEPT
|
||||
@@ -167,7 +168,7 @@ public:
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(222);
|
||||
static const std::uint16_t SBE_TEMPLATE_ID = static_cast<std::uint16_t>(548);
|
||||
static const std::uint16_t SBE_SCHEMA_ID = static_cast<std::uint16_t>(8);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(7);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(8);
|
||||
|
||||
enum MetaAttribute
|
||||
{
|
||||
@@ -200,6 +201,7 @@ public:
|
||||
m_bufferLength(bufferLength),
|
||||
m_offset(offset),
|
||||
m_position(sbeCheckPosition(offset + actingBlockLength)),
|
||||
m_actingBlockLength(actingBlockLength),
|
||||
m_actingVersion(actingVersion)
|
||||
{
|
||||
}
|
||||
@@ -240,7 +242,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeSchemaVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(7);
|
||||
return static_cast<std::uint16_t>(8);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR const char *sbeSemanticType() SBE_NOEXCEPT
|
||||
@@ -286,6 +288,11 @@ public:
|
||||
return *this = ExecutionReportTradeAddendumOutright548(buffer, offset, bufferLength, actingBlockLength, actingVersion);
|
||||
}
|
||||
|
||||
ExecutionReportTradeAddendumOutright548 &sbeRewind()
|
||||
{
|
||||
return wrapForDecode(m_buffer, m_offset, m_actingBlockLength, m_actingVersion, m_bufferLength);
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::uint64_t sbePosition() const SBE_NOEXCEPT
|
||||
{
|
||||
return m_position;
|
||||
@@ -668,7 +675,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportTradeAddendumOutright548 &putExecID(const std::string& str)
|
||||
ExecutionReportTradeAddendumOutright548 &putExecID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 40)
|
||||
@@ -874,7 +881,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportTradeAddendumOutright548 &putSenderID(const std::string& str)
|
||||
ExecutionReportTradeAddendumOutright548 &putSenderID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -1080,7 +1087,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportTradeAddendumOutright548 &putClOrdID(const std::string& str)
|
||||
ExecutionReportTradeAddendumOutright548 &putClOrdID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -1759,7 +1766,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportTradeAddendumOutright548 &putLocation(const std::string& str)
|
||||
ExecutionReportTradeAddendumOutright548 &putLocation(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 5)
|
||||
@@ -3366,7 +3373,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
|
||||
inline std::uint64_t resetCountToIndex() SBE_NOEXCEPT
|
||||
inline std::uint64_t resetCountToIndex()
|
||||
{
|
||||
m_count = m_index;
|
||||
GroupSize dimensions(m_buffer, m_initialPosition, m_bufferLength, m_actingVersion);
|
||||
@@ -3374,8 +3381,7 @@ public:
|
||||
return m_count;
|
||||
}
|
||||
|
||||
#if __cplusplus < 201103L
|
||||
template<class Func> inline void forEach(Func& func)
|
||||
template<class Func> inline void forEach(Func &&func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
@@ -3384,17 +3390,6 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
#else
|
||||
template<class Func> inline void forEach(Func&& func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
next();
|
||||
func(*this);
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
SBE_NODISCARD static const char *FillPxMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
@@ -3714,7 +3709,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
NoFills &putFillExecID(const std::string& str)
|
||||
NoFills &putFillExecID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 2)
|
||||
@@ -3804,8 +3799,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, NoFills writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, NoFills writer)
|
||||
{
|
||||
builder << '{';
|
||||
builder << R"("FillPx": )";
|
||||
@@ -4017,7 +4012,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
|
||||
inline std::uint64_t resetCountToIndex() SBE_NOEXCEPT
|
||||
inline std::uint64_t resetCountToIndex()
|
||||
{
|
||||
m_count = m_index;
|
||||
GroupSize dimensions(m_buffer, m_initialPosition, m_bufferLength, m_actingVersion);
|
||||
@@ -4025,8 +4020,7 @@ public:
|
||||
return m_count;
|
||||
}
|
||||
|
||||
#if __cplusplus < 201103L
|
||||
template<class Func> inline void forEach(Func& func)
|
||||
template<class Func> inline void forEach(Func &&func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
@@ -4035,17 +4029,6 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
#else
|
||||
template<class Func> inline void forEach(Func&& func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
next();
|
||||
func(*this);
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
SBE_NODISCARD static const char *OrderEventPxMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
@@ -4282,7 +4265,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
NoOrderEvents &putOrderEventText(const std::string& str)
|
||||
NoOrderEvents &putOrderEventText(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 5)
|
||||
@@ -4747,8 +4730,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, NoOrderEvents writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, NoOrderEvents writer)
|
||||
{
|
||||
builder << '{';
|
||||
builder << R"("OrderEventPx": )";
|
||||
@@ -4781,11 +4764,25 @@ public:
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("ContraGrossTradeAmt": )";
|
||||
builder << writer.contraGrossTradeAmt();
|
||||
if (writer.contraGrossTradeAmtInActingVersion())
|
||||
{
|
||||
builder << writer.contraGrossTradeAmt();
|
||||
}
|
||||
else
|
||||
{
|
||||
builder << "{}";
|
||||
}
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("ContraCalculatedCcyLastQty": )";
|
||||
builder << writer.contraCalculatedCcyLastQty();
|
||||
if (writer.contraCalculatedCcyLastQtyInActingVersion())
|
||||
{
|
||||
builder << writer.contraCalculatedCcyLastQty();
|
||||
}
|
||||
else
|
||||
{
|
||||
builder << "{}";
|
||||
}
|
||||
|
||||
builder << '}';
|
||||
|
||||
@@ -4855,11 +4852,16 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, ExecutionReportTradeAddendumOutright548 _writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, ExecutionReportTradeAddendumOutright548 _writer)
|
||||
{
|
||||
ExecutionReportTradeAddendumOutright548 writer(_writer.m_buffer, _writer.m_offset,
|
||||
_writer.m_bufferLength, _writer.sbeBlockLength(), _writer.m_actingVersion);
|
||||
ExecutionReportTradeAddendumOutright548 writer(
|
||||
_writer.m_buffer,
|
||||
_writer.m_offset,
|
||||
_writer.m_bufferLength,
|
||||
_writer.m_actingBlockLength,
|
||||
_writer.m_actingVersion);
|
||||
|
||||
builder << '{';
|
||||
builder << R"("Name": "ExecutionReportTradeAddendumOutright548", )";
|
||||
builder << R"("sbeTemplateId": )";
|
||||
@@ -4983,7 +4985,14 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("DiscretionPrice": )";
|
||||
builder << writer.discretionPrice();
|
||||
if (writer.discretionPriceInActingVersion())
|
||||
{
|
||||
builder << writer.discretionPrice();
|
||||
}
|
||||
else
|
||||
{
|
||||
builder << "{}";
|
||||
}
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("TrdType": )";
|
||||
@@ -5003,29 +5012,51 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("CalculatedCcyLastQty": )";
|
||||
builder << writer.calculatedCcyLastQty();
|
||||
if (writer.calculatedCcyLastQtyInActingVersion())
|
||||
{
|
||||
builder << writer.calculatedCcyLastQty();
|
||||
}
|
||||
else
|
||||
{
|
||||
builder << "{}";
|
||||
}
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("GrossTradeAmt": )";
|
||||
builder << writer.grossTradeAmt();
|
||||
if (writer.grossTradeAmtInActingVersion())
|
||||
{
|
||||
builder << writer.grossTradeAmt();
|
||||
}
|
||||
else
|
||||
{
|
||||
builder << "{}";
|
||||
}
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("BenchmarkPrice": )";
|
||||
builder << writer.benchmarkPrice();
|
||||
if (writer.benchmarkPriceInActingVersion())
|
||||
{
|
||||
builder << writer.benchmarkPrice();
|
||||
}
|
||||
else
|
||||
{
|
||||
builder << "{}";
|
||||
}
|
||||
|
||||
builder << ", ";
|
||||
{
|
||||
bool atLeastOne = false;
|
||||
builder << R"("NoFills": [)";
|
||||
writer.noFills().forEach([&](NoFills& noFills)
|
||||
{
|
||||
if (atLeastOne)
|
||||
writer.noFills().forEach(
|
||||
[&](NoFills &noFills)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noFills;
|
||||
});
|
||||
if (atLeastOne)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noFills;
|
||||
});
|
||||
builder << ']';
|
||||
}
|
||||
|
||||
@@ -5033,15 +5064,16 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
{
|
||||
bool atLeastOne = false;
|
||||
builder << R"("NoOrderEvents": [)";
|
||||
writer.noOrderEvents().forEach([&](NoOrderEvents& noOrderEvents)
|
||||
{
|
||||
if (atLeastOne)
|
||||
writer.noOrderEvents().forEach(
|
||||
[&](NoOrderEvents &noOrderEvents)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noOrderEvents;
|
||||
});
|
||||
if (atLeastOne)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noOrderEvents;
|
||||
});
|
||||
builder << ']';
|
||||
}
|
||||
|
||||
@@ -5052,14 +5084,16 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
|
||||
void skip()
|
||||
{
|
||||
noFills().forEach([](NoFills e)
|
||||
auto &noFillsGroup { noFills() };
|
||||
while (noFillsGroup.hasNext())
|
||||
{
|
||||
e.skip();
|
||||
});
|
||||
noOrderEvents().forEach([](NoOrderEvents e)
|
||||
noFillsGroup.next().skip();
|
||||
}
|
||||
auto &noOrderEventsGroup { noOrderEvents() };
|
||||
while (noOrderEventsGroup.hasNext())
|
||||
{
|
||||
e.skip();
|
||||
});
|
||||
noOrderEventsGroup.next().skip();
|
||||
}
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR bool isConstLength() SBE_NOEXCEPT
|
||||
|
||||
@@ -70,11 +70,11 @@
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (__builtin_expect(exp, c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
@@ -156,6 +156,7 @@ private:
|
||||
std::uint64_t m_bufferLength = 0;
|
||||
std::uint64_t m_offset = 0;
|
||||
std::uint64_t m_position = 0;
|
||||
std::uint64_t m_actingBlockLength = 0;
|
||||
std::uint64_t m_actingVersion = 0;
|
||||
|
||||
inline std::uint64_t *sbePositionPtr() SBE_NOEXCEPT
|
||||
@@ -167,7 +168,7 @@ public:
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(187);
|
||||
static const std::uint16_t SBE_TEMPLATE_ID = static_cast<std::uint16_t>(549);
|
||||
static const std::uint16_t SBE_SCHEMA_ID = static_cast<std::uint16_t>(8);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(7);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(8);
|
||||
|
||||
enum MetaAttribute
|
||||
{
|
||||
@@ -200,6 +201,7 @@ public:
|
||||
m_bufferLength(bufferLength),
|
||||
m_offset(offset),
|
||||
m_position(sbeCheckPosition(offset + actingBlockLength)),
|
||||
m_actingBlockLength(actingBlockLength),
|
||||
m_actingVersion(actingVersion)
|
||||
{
|
||||
}
|
||||
@@ -240,7 +242,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeSchemaVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(7);
|
||||
return static_cast<std::uint16_t>(8);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR const char *sbeSemanticType() SBE_NOEXCEPT
|
||||
@@ -286,6 +288,11 @@ public:
|
||||
return *this = ExecutionReportTradeAddendumSpread549(buffer, offset, bufferLength, actingBlockLength, actingVersion);
|
||||
}
|
||||
|
||||
ExecutionReportTradeAddendumSpread549 &sbeRewind()
|
||||
{
|
||||
return wrapForDecode(m_buffer, m_offset, m_actingBlockLength, m_actingVersion, m_bufferLength);
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::uint64_t sbePosition() const SBE_NOEXCEPT
|
||||
{
|
||||
return m_position;
|
||||
@@ -668,7 +675,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportTradeAddendumSpread549 &putExecID(const std::string& str)
|
||||
ExecutionReportTradeAddendumSpread549 &putExecID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 40)
|
||||
@@ -874,7 +881,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportTradeAddendumSpread549 &putSenderID(const std::string& str)
|
||||
ExecutionReportTradeAddendumSpread549 &putSenderID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -1080,7 +1087,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportTradeAddendumSpread549 &putClOrdID(const std::string& str)
|
||||
ExecutionReportTradeAddendumSpread549 &putClOrdID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -1759,7 +1766,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportTradeAddendumSpread549 &putLocation(const std::string& str)
|
||||
ExecutionReportTradeAddendumSpread549 &putLocation(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 5)
|
||||
@@ -3082,7 +3089,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
|
||||
inline std::uint64_t resetCountToIndex() SBE_NOEXCEPT
|
||||
inline std::uint64_t resetCountToIndex()
|
||||
{
|
||||
m_count = m_index;
|
||||
GroupSize dimensions(m_buffer, m_initialPosition, m_bufferLength, m_actingVersion);
|
||||
@@ -3090,8 +3097,7 @@ public:
|
||||
return m_count;
|
||||
}
|
||||
|
||||
#if __cplusplus < 201103L
|
||||
template<class Func> inline void forEach(Func& func)
|
||||
template<class Func> inline void forEach(Func &&func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
@@ -3100,17 +3106,6 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
#else
|
||||
template<class Func> inline void forEach(Func&& func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
next();
|
||||
func(*this);
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
SBE_NODISCARD static const char *FillPxMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
@@ -3430,7 +3425,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
NoFills &putFillExecID(const std::string& str)
|
||||
NoFills &putFillExecID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 2)
|
||||
@@ -3520,8 +3515,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, NoFills writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, NoFills writer)
|
||||
{
|
||||
builder << '{';
|
||||
builder << R"("FillPx": )";
|
||||
@@ -3733,7 +3728,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
|
||||
inline std::uint64_t resetCountToIndex() SBE_NOEXCEPT
|
||||
inline std::uint64_t resetCountToIndex()
|
||||
{
|
||||
m_count = m_index;
|
||||
GroupSize dimensions(m_buffer, m_initialPosition, m_bufferLength, m_actingVersion);
|
||||
@@ -3741,8 +3736,7 @@ public:
|
||||
return m_count;
|
||||
}
|
||||
|
||||
#if __cplusplus < 201103L
|
||||
template<class Func> inline void forEach(Func& func)
|
||||
template<class Func> inline void forEach(Func &&func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
@@ -3751,17 +3745,6 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
#else
|
||||
template<class Func> inline void forEach(Func&& func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
next();
|
||||
func(*this);
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
SBE_NODISCARD static const char *LegExecIDMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
@@ -4300,8 +4283,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, NoLegs writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, NoLegs writer)
|
||||
{
|
||||
builder << '{';
|
||||
builder << R"("LegExecID": )";
|
||||
@@ -4528,7 +4511,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
|
||||
inline std::uint64_t resetCountToIndex() SBE_NOEXCEPT
|
||||
inline std::uint64_t resetCountToIndex()
|
||||
{
|
||||
m_count = m_index;
|
||||
GroupSize dimensions(m_buffer, m_initialPosition, m_bufferLength, m_actingVersion);
|
||||
@@ -4536,8 +4519,7 @@ public:
|
||||
return m_count;
|
||||
}
|
||||
|
||||
#if __cplusplus < 201103L
|
||||
template<class Func> inline void forEach(Func& func)
|
||||
template<class Func> inline void forEach(Func &&func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
@@ -4546,17 +4528,6 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
#else
|
||||
template<class Func> inline void forEach(Func&& func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
next();
|
||||
func(*this);
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
SBE_NODISCARD static const char *OrderEventPxMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
@@ -4793,7 +4764,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
NoOrderEvents &putOrderEventText(const std::string& str)
|
||||
NoOrderEvents &putOrderEventText(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 5)
|
||||
@@ -5164,8 +5135,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, NoOrderEvents writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, NoOrderEvents writer)
|
||||
{
|
||||
builder << '{';
|
||||
builder << R"("OrderEventPx": )";
|
||||
@@ -5264,11 +5235,16 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, ExecutionReportTradeAddendumSpread549 _writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, ExecutionReportTradeAddendumSpread549 _writer)
|
||||
{
|
||||
ExecutionReportTradeAddendumSpread549 writer(_writer.m_buffer, _writer.m_offset,
|
||||
_writer.m_bufferLength, _writer.sbeBlockLength(), _writer.m_actingVersion);
|
||||
ExecutionReportTradeAddendumSpread549 writer(
|
||||
_writer.m_buffer,
|
||||
_writer.m_offset,
|
||||
_writer.m_bufferLength,
|
||||
_writer.m_actingBlockLength,
|
||||
_writer.m_actingVersion);
|
||||
|
||||
builder << '{';
|
||||
builder << R"("Name": "ExecutionReportTradeAddendumSpread549", )";
|
||||
builder << R"("sbeTemplateId": )";
|
||||
@@ -5406,15 +5382,16 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
{
|
||||
bool atLeastOne = false;
|
||||
builder << R"("NoFills": [)";
|
||||
writer.noFills().forEach([&](NoFills& noFills)
|
||||
{
|
||||
if (atLeastOne)
|
||||
writer.noFills().forEach(
|
||||
[&](NoFills &noFills)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noFills;
|
||||
});
|
||||
if (atLeastOne)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noFills;
|
||||
});
|
||||
builder << ']';
|
||||
}
|
||||
|
||||
@@ -5422,15 +5399,16 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
{
|
||||
bool atLeastOne = false;
|
||||
builder << R"("NoLegs": [)";
|
||||
writer.noLegs().forEach([&](NoLegs& noLegs)
|
||||
{
|
||||
if (atLeastOne)
|
||||
writer.noLegs().forEach(
|
||||
[&](NoLegs &noLegs)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noLegs;
|
||||
});
|
||||
if (atLeastOne)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noLegs;
|
||||
});
|
||||
builder << ']';
|
||||
}
|
||||
|
||||
@@ -5438,15 +5416,16 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
{
|
||||
bool atLeastOne = false;
|
||||
builder << R"("NoOrderEvents": [)";
|
||||
writer.noOrderEvents().forEach([&](NoOrderEvents& noOrderEvents)
|
||||
{
|
||||
if (atLeastOne)
|
||||
writer.noOrderEvents().forEach(
|
||||
[&](NoOrderEvents &noOrderEvents)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noOrderEvents;
|
||||
});
|
||||
if (atLeastOne)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noOrderEvents;
|
||||
});
|
||||
builder << ']';
|
||||
}
|
||||
|
||||
@@ -5457,18 +5436,21 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
|
||||
void skip()
|
||||
{
|
||||
noFills().forEach([](NoFills e)
|
||||
auto &noFillsGroup { noFills() };
|
||||
while (noFillsGroup.hasNext())
|
||||
{
|
||||
e.skip();
|
||||
});
|
||||
noLegs().forEach([](NoLegs e)
|
||||
noFillsGroup.next().skip();
|
||||
}
|
||||
auto &noLegsGroup { noLegs() };
|
||||
while (noLegsGroup.hasNext())
|
||||
{
|
||||
e.skip();
|
||||
});
|
||||
noOrderEvents().forEach([](NoOrderEvents e)
|
||||
noLegsGroup.next().skip();
|
||||
}
|
||||
auto &noOrderEventsGroup { noOrderEvents() };
|
||||
while (noOrderEventsGroup.hasNext())
|
||||
{
|
||||
e.skip();
|
||||
});
|
||||
noOrderEventsGroup.next().skip();
|
||||
}
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR bool isConstLength() SBE_NOEXCEPT
|
||||
|
||||
+77
-71
@@ -70,11 +70,11 @@
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (__builtin_expect(exp, c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
@@ -156,6 +156,7 @@ private:
|
||||
std::uint64_t m_bufferLength = 0;
|
||||
std::uint64_t m_offset = 0;
|
||||
std::uint64_t m_position = 0;
|
||||
std::uint64_t m_actingBlockLength = 0;
|
||||
std::uint64_t m_actingVersion = 0;
|
||||
|
||||
inline std::uint64_t *sbePositionPtr() SBE_NOEXCEPT
|
||||
@@ -167,7 +168,7 @@ public:
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(196);
|
||||
static const std::uint16_t SBE_TEMPLATE_ID = static_cast<std::uint16_t>(550);
|
||||
static const std::uint16_t SBE_SCHEMA_ID = static_cast<std::uint16_t>(8);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(7);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(8);
|
||||
|
||||
enum MetaAttribute
|
||||
{
|
||||
@@ -200,6 +201,7 @@ public:
|
||||
m_bufferLength(bufferLength),
|
||||
m_offset(offset),
|
||||
m_position(sbeCheckPosition(offset + actingBlockLength)),
|
||||
m_actingBlockLength(actingBlockLength),
|
||||
m_actingVersion(actingVersion)
|
||||
{
|
||||
}
|
||||
@@ -240,7 +242,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeSchemaVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(7);
|
||||
return static_cast<std::uint16_t>(8);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR const char *sbeSemanticType() SBE_NOEXCEPT
|
||||
@@ -286,6 +288,11 @@ public:
|
||||
return *this = ExecutionReportTradeAddendumSpreadLeg550(buffer, offset, bufferLength, actingBlockLength, actingVersion);
|
||||
}
|
||||
|
||||
ExecutionReportTradeAddendumSpreadLeg550 &sbeRewind()
|
||||
{
|
||||
return wrapForDecode(m_buffer, m_offset, m_actingBlockLength, m_actingVersion, m_bufferLength);
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::uint64_t sbePosition() const SBE_NOEXCEPT
|
||||
{
|
||||
return m_position;
|
||||
@@ -668,7 +675,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportTradeAddendumSpreadLeg550 &putExecID(const std::string& str)
|
||||
ExecutionReportTradeAddendumSpreadLeg550 &putExecID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 40)
|
||||
@@ -874,7 +881,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportTradeAddendumSpreadLeg550 &putSenderID(const std::string& str)
|
||||
ExecutionReportTradeAddendumSpreadLeg550 &putSenderID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -1080,7 +1087,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportTradeAddendumSpreadLeg550 &putClOrdID(const std::string& str)
|
||||
ExecutionReportTradeAddendumSpreadLeg550 &putClOrdID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -1759,7 +1766,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportTradeAddendumSpreadLeg550 &putLocation(const std::string& str)
|
||||
ExecutionReportTradeAddendumSpreadLeg550 &putLocation(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 5)
|
||||
@@ -2753,7 +2760,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
|
||||
inline std::uint64_t resetCountToIndex() SBE_NOEXCEPT
|
||||
inline std::uint64_t resetCountToIndex()
|
||||
{
|
||||
m_count = m_index;
|
||||
GroupSize dimensions(m_buffer, m_initialPosition, m_bufferLength, m_actingVersion);
|
||||
@@ -2761,8 +2768,7 @@ public:
|
||||
return m_count;
|
||||
}
|
||||
|
||||
#if __cplusplus < 201103L
|
||||
template<class Func> inline void forEach(Func& func)
|
||||
template<class Func> inline void forEach(Func &&func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
@@ -2771,17 +2777,6 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
#else
|
||||
template<class Func> inline void forEach(Func&& func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
next();
|
||||
func(*this);
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
SBE_NODISCARD static const char *FillPxMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
@@ -3101,7 +3096,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
NoFills &putFillExecID(const std::string& str)
|
||||
NoFills &putFillExecID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 2)
|
||||
@@ -3191,8 +3186,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, NoFills writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, NoFills writer)
|
||||
{
|
||||
builder << '{';
|
||||
builder << R"("FillPx": )";
|
||||
@@ -3404,7 +3399,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
|
||||
inline std::uint64_t resetCountToIndex() SBE_NOEXCEPT
|
||||
inline std::uint64_t resetCountToIndex()
|
||||
{
|
||||
m_count = m_index;
|
||||
GroupSize dimensions(m_buffer, m_initialPosition, m_bufferLength, m_actingVersion);
|
||||
@@ -3412,8 +3407,7 @@ public:
|
||||
return m_count;
|
||||
}
|
||||
|
||||
#if __cplusplus < 201103L
|
||||
template<class Func> inline void forEach(Func& func)
|
||||
template<class Func> inline void forEach(Func &&func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
@@ -3422,17 +3416,6 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
#else
|
||||
template<class Func> inline void forEach(Func&& func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
next();
|
||||
func(*this);
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
SBE_NODISCARD static const char *OrderEventPxMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
@@ -3669,7 +3652,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
NoOrderEvents &putOrderEventText(const std::string& str)
|
||||
NoOrderEvents &putOrderEventText(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 5)
|
||||
@@ -4040,8 +4023,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, NoOrderEvents writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, NoOrderEvents writer)
|
||||
{
|
||||
builder << '{';
|
||||
builder << R"("OrderEventPx": )";
|
||||
@@ -4140,11 +4123,16 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, ExecutionReportTradeAddendumSpreadLeg550 _writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, ExecutionReportTradeAddendumSpreadLeg550 _writer)
|
||||
{
|
||||
ExecutionReportTradeAddendumSpreadLeg550 writer(_writer.m_buffer, _writer.m_offset,
|
||||
_writer.m_bufferLength, _writer.sbeBlockLength(), _writer.m_actingVersion);
|
||||
ExecutionReportTradeAddendumSpreadLeg550 writer(
|
||||
_writer.m_buffer,
|
||||
_writer.m_offset,
|
||||
_writer.m_bufferLength,
|
||||
_writer.m_actingBlockLength,
|
||||
_writer.m_actingVersion);
|
||||
|
||||
builder << '{';
|
||||
builder << R"("Name": "ExecutionReportTradeAddendumSpreadLeg550", )";
|
||||
builder << R"("sbeTemplateId": )";
|
||||
@@ -4252,25 +4240,40 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("CalculatedCcyLastQty": )";
|
||||
builder << writer.calculatedCcyLastQty();
|
||||
if (writer.calculatedCcyLastQtyInActingVersion())
|
||||
{
|
||||
builder << writer.calculatedCcyLastQty();
|
||||
}
|
||||
else
|
||||
{
|
||||
builder << "{}";
|
||||
}
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("GrossTradeAmt": )";
|
||||
builder << writer.grossTradeAmt();
|
||||
if (writer.grossTradeAmtInActingVersion())
|
||||
{
|
||||
builder << writer.grossTradeAmt();
|
||||
}
|
||||
else
|
||||
{
|
||||
builder << "{}";
|
||||
}
|
||||
|
||||
builder << ", ";
|
||||
{
|
||||
bool atLeastOne = false;
|
||||
builder << R"("NoFills": [)";
|
||||
writer.noFills().forEach([&](NoFills& noFills)
|
||||
{
|
||||
if (atLeastOne)
|
||||
writer.noFills().forEach(
|
||||
[&](NoFills &noFills)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noFills;
|
||||
});
|
||||
if (atLeastOne)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noFills;
|
||||
});
|
||||
builder << ']';
|
||||
}
|
||||
|
||||
@@ -4278,15 +4281,16 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
{
|
||||
bool atLeastOne = false;
|
||||
builder << R"("NoOrderEvents": [)";
|
||||
writer.noOrderEvents().forEach([&](NoOrderEvents& noOrderEvents)
|
||||
{
|
||||
if (atLeastOne)
|
||||
writer.noOrderEvents().forEach(
|
||||
[&](NoOrderEvents &noOrderEvents)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noOrderEvents;
|
||||
});
|
||||
if (atLeastOne)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noOrderEvents;
|
||||
});
|
||||
builder << ']';
|
||||
}
|
||||
|
||||
@@ -4297,14 +4301,16 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
|
||||
void skip()
|
||||
{
|
||||
noFills().forEach([](NoFills e)
|
||||
auto &noFillsGroup { noFills() };
|
||||
while (noFillsGroup.hasNext())
|
||||
{
|
||||
e.skip();
|
||||
});
|
||||
noOrderEvents().forEach([](NoOrderEvents e)
|
||||
noFillsGroup.next().skip();
|
||||
}
|
||||
auto &noOrderEventsGroup { noOrderEvents() };
|
||||
while (noOrderEventsGroup.hasNext())
|
||||
{
|
||||
e.skip();
|
||||
});
|
||||
noOrderEventsGroup.next().skip();
|
||||
}
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR bool isConstLength() SBE_NOEXCEPT
|
||||
|
||||
@@ -70,11 +70,11 @@
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (__builtin_expect(exp, c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
@@ -156,6 +156,7 @@ private:
|
||||
std::uint64_t m_bufferLength = 0;
|
||||
std::uint64_t m_offset = 0;
|
||||
std::uint64_t m_position = 0;
|
||||
std::uint64_t m_actingBlockLength = 0;
|
||||
std::uint64_t m_actingVersion = 0;
|
||||
|
||||
inline std::uint64_t *sbePositionPtr() SBE_NOEXCEPT
|
||||
@@ -164,10 +165,10 @@ private:
|
||||
}
|
||||
|
||||
public:
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(276);
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(293);
|
||||
static const std::uint16_t SBE_TEMPLATE_ID = static_cast<std::uint16_t>(525);
|
||||
static const std::uint16_t SBE_SCHEMA_ID = static_cast<std::uint16_t>(8);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(7);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(8);
|
||||
|
||||
enum MetaAttribute
|
||||
{
|
||||
@@ -200,6 +201,7 @@ public:
|
||||
m_bufferLength(bufferLength),
|
||||
m_offset(offset),
|
||||
m_position(sbeCheckPosition(offset + actingBlockLength)),
|
||||
m_actingBlockLength(actingBlockLength),
|
||||
m_actingVersion(actingVersion)
|
||||
{
|
||||
}
|
||||
@@ -220,7 +222,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeBlockLength() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(276);
|
||||
return static_cast<std::uint16_t>(293);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint64_t sbeBlockAndHeaderLength() SBE_NOEXCEPT
|
||||
@@ -240,7 +242,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeSchemaVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(7);
|
||||
return static_cast<std::uint16_t>(8);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR const char *sbeSemanticType() SBE_NOEXCEPT
|
||||
@@ -286,6 +288,11 @@ public:
|
||||
return *this = ExecutionReportTradeOutright525(buffer, offset, bufferLength, actingBlockLength, actingVersion);
|
||||
}
|
||||
|
||||
ExecutionReportTradeOutright525 &sbeRewind()
|
||||
{
|
||||
return wrapForDecode(m_buffer, m_offset, m_actingBlockLength, m_actingVersion, m_bufferLength);
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::uint64_t sbePosition() const SBE_NOEXCEPT
|
||||
{
|
||||
return m_position;
|
||||
@@ -668,7 +675,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportTradeOutright525 &putExecID(const std::string& str)
|
||||
ExecutionReportTradeOutright525 &putExecID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 40)
|
||||
@@ -874,7 +881,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportTradeOutright525 &putSenderID(const std::string& str)
|
||||
ExecutionReportTradeOutright525 &putSenderID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -1080,7 +1087,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportTradeOutright525 &putClOrdID(const std::string& str)
|
||||
ExecutionReportTradeOutright525 &putClOrdID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -1995,7 +2002,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportTradeOutright525 &putLocation(const std::string& str)
|
||||
ExecutionReportTradeOutright525 &putLocation(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 5)
|
||||
@@ -4224,6 +4231,176 @@ public:
|
||||
return m_benchmarkPrice;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static const char *ReservationPriceMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
switch (metaAttribute)
|
||||
{
|
||||
case MetaAttribute::SEMANTIC_TYPE: return "Price";
|
||||
case MetaAttribute::PRESENCE: return "required";
|
||||
default: return "";
|
||||
}
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint16_t reservationPriceId() SBE_NOEXCEPT
|
||||
{
|
||||
return 9562;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint64_t reservationPriceSinceVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
SBE_NODISCARD bool reservationPriceInActingVersion() SBE_NOEXCEPT
|
||||
{
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic push
|
||||
#pragma clang diagnostic ignored "-Wtautological-compare"
|
||||
#endif
|
||||
return m_actingVersion >= reservationPriceSinceVersion();
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic pop
|
||||
#endif
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::size_t reservationPriceEncodingOffset() SBE_NOEXCEPT
|
||||
{
|
||||
return 276;
|
||||
}
|
||||
|
||||
private:
|
||||
PRICENULL9 m_reservationPrice;
|
||||
|
||||
public:
|
||||
SBE_NODISCARD PRICENULL9 &reservationPrice()
|
||||
{
|
||||
m_reservationPrice.wrap(m_buffer, m_offset + 276, m_actingVersion, m_bufferLength);
|
||||
return m_reservationPrice;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static const char *PriorityIndicatorMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
switch (metaAttribute)
|
||||
{
|
||||
case MetaAttribute::SEMANTIC_TYPE: return "int";
|
||||
case MetaAttribute::PRESENCE: return "optional";
|
||||
default: return "";
|
||||
}
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint16_t priorityIndicatorId() SBE_NOEXCEPT
|
||||
{
|
||||
return 638;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint64_t priorityIndicatorSinceVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
SBE_NODISCARD bool priorityIndicatorInActingVersion() SBE_NOEXCEPT
|
||||
{
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic push
|
||||
#pragma clang diagnostic ignored "-Wtautological-compare"
|
||||
#endif
|
||||
return m_actingVersion >= priorityIndicatorSinceVersion();
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic pop
|
||||
#endif
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::size_t priorityIndicatorEncodingOffset() SBE_NOEXCEPT
|
||||
{
|
||||
return 284;
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint8_t priorityIndicatorNullValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint8_t>(255);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint8_t priorityIndicatorMinValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint8_t>(0);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint8_t priorityIndicatorMaxValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint8_t>(254);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::size_t priorityIndicatorEncodingLength() SBE_NOEXCEPT
|
||||
{
|
||||
return 1;
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::uint8_t priorityIndicator() const SBE_NOEXCEPT
|
||||
{
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return static_cast<std::uint8_t>(255);
|
||||
}
|
||||
|
||||
std::uint8_t val;
|
||||
std::memcpy(&val, m_buffer + m_offset + 284, sizeof(std::uint8_t));
|
||||
return (val);
|
||||
}
|
||||
|
||||
ExecutionReportTradeOutright525 &priorityIndicator(const std::uint8_t value) SBE_NOEXCEPT
|
||||
{
|
||||
std::uint8_t val = (value);
|
||||
std::memcpy(m_buffer + m_offset + 284, &val, sizeof(std::uint8_t));
|
||||
return *this;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static const char *DisplayLimitPriceMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
switch (metaAttribute)
|
||||
{
|
||||
case MetaAttribute::SEMANTIC_TYPE: return "Price";
|
||||
case MetaAttribute::PRESENCE: return "required";
|
||||
default: return "";
|
||||
}
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint16_t displayLimitPriceId() SBE_NOEXCEPT
|
||||
{
|
||||
return 9264;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint64_t displayLimitPriceSinceVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
SBE_NODISCARD bool displayLimitPriceInActingVersion() SBE_NOEXCEPT
|
||||
{
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic push
|
||||
#pragma clang diagnostic ignored "-Wtautological-compare"
|
||||
#endif
|
||||
return m_actingVersion >= displayLimitPriceSinceVersion();
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic pop
|
||||
#endif
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::size_t displayLimitPriceEncodingOffset() SBE_NOEXCEPT
|
||||
{
|
||||
return 285;
|
||||
}
|
||||
|
||||
private:
|
||||
PRICENULL9 m_displayLimitPrice;
|
||||
|
||||
public:
|
||||
SBE_NODISCARD PRICENULL9 &displayLimitPrice()
|
||||
{
|
||||
m_displayLimitPrice.wrap(m_buffer, m_offset + 285, m_actingVersion, m_bufferLength);
|
||||
return m_displayLimitPrice;
|
||||
}
|
||||
|
||||
class NoFills
|
||||
{
|
||||
private:
|
||||
@@ -4350,7 +4527,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
|
||||
inline std::uint64_t resetCountToIndex() SBE_NOEXCEPT
|
||||
inline std::uint64_t resetCountToIndex()
|
||||
{
|
||||
m_count = m_index;
|
||||
GroupSize dimensions(m_buffer, m_initialPosition, m_bufferLength, m_actingVersion);
|
||||
@@ -4358,8 +4535,7 @@ public:
|
||||
return m_count;
|
||||
}
|
||||
|
||||
#if __cplusplus < 201103L
|
||||
template<class Func> inline void forEach(Func& func)
|
||||
template<class Func> inline void forEach(Func &&func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
@@ -4368,17 +4544,6 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
#else
|
||||
template<class Func> inline void forEach(Func&& func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
next();
|
||||
func(*this);
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
SBE_NODISCARD static const char *FillPxMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
@@ -4698,7 +4863,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
NoFills &putFillExecID(const std::string& str)
|
||||
NoFills &putFillExecID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 2)
|
||||
@@ -4788,8 +4953,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, NoFills writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, NoFills writer)
|
||||
{
|
||||
builder << '{';
|
||||
builder << R"("FillPx": )";
|
||||
@@ -5001,7 +5166,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
|
||||
inline std::uint64_t resetCountToIndex() SBE_NOEXCEPT
|
||||
inline std::uint64_t resetCountToIndex()
|
||||
{
|
||||
m_count = m_index;
|
||||
GroupSize dimensions(m_buffer, m_initialPosition, m_bufferLength, m_actingVersion);
|
||||
@@ -5009,8 +5174,7 @@ public:
|
||||
return m_count;
|
||||
}
|
||||
|
||||
#if __cplusplus < 201103L
|
||||
template<class Func> inline void forEach(Func& func)
|
||||
template<class Func> inline void forEach(Func &&func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
@@ -5019,17 +5183,6 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
#else
|
||||
template<class Func> inline void forEach(Func&& func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
next();
|
||||
func(*this);
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
SBE_NODISCARD static const char *OrderEventPxMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
@@ -5266,7 +5419,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
NoOrderEvents &putOrderEventText(const std::string& str)
|
||||
NoOrderEvents &putOrderEventText(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 5)
|
||||
@@ -5655,8 +5808,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, NoOrderEvents writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, NoOrderEvents writer)
|
||||
{
|
||||
builder << '{';
|
||||
builder << R"("OrderEventPx": )";
|
||||
@@ -5685,11 +5838,25 @@ public:
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("ContraGrossTradeAmt": )";
|
||||
builder << writer.contraGrossTradeAmt();
|
||||
if (writer.contraGrossTradeAmtInActingVersion())
|
||||
{
|
||||
builder << writer.contraGrossTradeAmt();
|
||||
}
|
||||
else
|
||||
{
|
||||
builder << "{}";
|
||||
}
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("ContraCalculatedCcyLastQty": )";
|
||||
builder << writer.contraCalculatedCcyLastQty();
|
||||
if (writer.contraCalculatedCcyLastQtyInActingVersion())
|
||||
{
|
||||
builder << writer.contraCalculatedCcyLastQty();
|
||||
}
|
||||
else
|
||||
{
|
||||
builder << "{}";
|
||||
}
|
||||
|
||||
builder << '}';
|
||||
|
||||
@@ -5759,11 +5926,16 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, ExecutionReportTradeOutright525 _writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, ExecutionReportTradeOutright525 _writer)
|
||||
{
|
||||
ExecutionReportTradeOutright525 writer(_writer.m_buffer, _writer.m_offset,
|
||||
_writer.m_bufferLength, _writer.sbeBlockLength(), _writer.m_actingVersion);
|
||||
ExecutionReportTradeOutright525 writer(
|
||||
_writer.m_buffer,
|
||||
_writer.m_offset,
|
||||
_writer.m_bufferLength,
|
||||
_writer.m_actingBlockLength,
|
||||
_writer.m_actingVersion);
|
||||
|
||||
builder << '{';
|
||||
builder << R"("Name": "ExecutionReportTradeOutright525", )";
|
||||
builder << R"("sbeTemplateId": )";
|
||||
@@ -5939,7 +6111,14 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("DiscretionPrice": )";
|
||||
builder << writer.discretionPrice();
|
||||
if (writer.discretionPriceInActingVersion())
|
||||
{
|
||||
builder << writer.discretionPrice();
|
||||
}
|
||||
else
|
||||
{
|
||||
builder << "{}";
|
||||
}
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("TrdType": )";
|
||||
@@ -5959,29 +6138,77 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("CalculatedCcyLastQty": )";
|
||||
builder << writer.calculatedCcyLastQty();
|
||||
if (writer.calculatedCcyLastQtyInActingVersion())
|
||||
{
|
||||
builder << writer.calculatedCcyLastQty();
|
||||
}
|
||||
else
|
||||
{
|
||||
builder << "{}";
|
||||
}
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("GrossTradeAmt": )";
|
||||
builder << writer.grossTradeAmt();
|
||||
if (writer.grossTradeAmtInActingVersion())
|
||||
{
|
||||
builder << writer.grossTradeAmt();
|
||||
}
|
||||
else
|
||||
{
|
||||
builder << "{}";
|
||||
}
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("BenchmarkPrice": )";
|
||||
builder << writer.benchmarkPrice();
|
||||
if (writer.benchmarkPriceInActingVersion())
|
||||
{
|
||||
builder << writer.benchmarkPrice();
|
||||
}
|
||||
else
|
||||
{
|
||||
builder << "{}";
|
||||
}
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("ReservationPrice": )";
|
||||
if (writer.reservationPriceInActingVersion())
|
||||
{
|
||||
builder << writer.reservationPrice();
|
||||
}
|
||||
else
|
||||
{
|
||||
builder << "{}";
|
||||
}
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("PriorityIndicator": )";
|
||||
builder << +writer.priorityIndicator();
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("DisplayLimitPrice": )";
|
||||
if (writer.displayLimitPriceInActingVersion())
|
||||
{
|
||||
builder << writer.displayLimitPrice();
|
||||
}
|
||||
else
|
||||
{
|
||||
builder << "{}";
|
||||
}
|
||||
|
||||
builder << ", ";
|
||||
{
|
||||
bool atLeastOne = false;
|
||||
builder << R"("NoFills": [)";
|
||||
writer.noFills().forEach([&](NoFills& noFills)
|
||||
{
|
||||
if (atLeastOne)
|
||||
writer.noFills().forEach(
|
||||
[&](NoFills &noFills)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noFills;
|
||||
});
|
||||
if (atLeastOne)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noFills;
|
||||
});
|
||||
builder << ']';
|
||||
}
|
||||
|
||||
@@ -5989,15 +6216,16 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
{
|
||||
bool atLeastOne = false;
|
||||
builder << R"("NoOrderEvents": [)";
|
||||
writer.noOrderEvents().forEach([&](NoOrderEvents& noOrderEvents)
|
||||
{
|
||||
if (atLeastOne)
|
||||
writer.noOrderEvents().forEach(
|
||||
[&](NoOrderEvents &noOrderEvents)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noOrderEvents;
|
||||
});
|
||||
if (atLeastOne)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noOrderEvents;
|
||||
});
|
||||
builder << ']';
|
||||
}
|
||||
|
||||
@@ -6008,14 +6236,16 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
|
||||
void skip()
|
||||
{
|
||||
noFills().forEach([](NoFills e)
|
||||
auto &noFillsGroup { noFills() };
|
||||
while (noFillsGroup.hasNext())
|
||||
{
|
||||
e.skip();
|
||||
});
|
||||
noOrderEvents().forEach([](NoOrderEvents e)
|
||||
noFillsGroup.next().skip();
|
||||
}
|
||||
auto &noOrderEventsGroup { noOrderEvents() };
|
||||
while (noOrderEventsGroup.hasNext())
|
||||
{
|
||||
e.skip();
|
||||
});
|
||||
noOrderEventsGroup.next().skip();
|
||||
}
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR bool isConstLength() SBE_NOEXCEPT
|
||||
|
||||
@@ -70,11 +70,11 @@
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (__builtin_expect(exp, c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
@@ -156,6 +156,7 @@ private:
|
||||
std::uint64_t m_bufferLength = 0;
|
||||
std::uint64_t m_offset = 0;
|
||||
std::uint64_t m_position = 0;
|
||||
std::uint64_t m_actingBlockLength = 0;
|
||||
std::uint64_t m_actingVersion = 0;
|
||||
|
||||
inline std::uint64_t *sbePositionPtr() SBE_NOEXCEPT
|
||||
@@ -167,7 +168,7 @@ public:
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(230);
|
||||
static const std::uint16_t SBE_TEMPLATE_ID = static_cast<std::uint16_t>(526);
|
||||
static const std::uint16_t SBE_SCHEMA_ID = static_cast<std::uint16_t>(8);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(7);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(8);
|
||||
|
||||
enum MetaAttribute
|
||||
{
|
||||
@@ -200,6 +201,7 @@ public:
|
||||
m_bufferLength(bufferLength),
|
||||
m_offset(offset),
|
||||
m_position(sbeCheckPosition(offset + actingBlockLength)),
|
||||
m_actingBlockLength(actingBlockLength),
|
||||
m_actingVersion(actingVersion)
|
||||
{
|
||||
}
|
||||
@@ -240,7 +242,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeSchemaVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(7);
|
||||
return static_cast<std::uint16_t>(8);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR const char *sbeSemanticType() SBE_NOEXCEPT
|
||||
@@ -286,6 +288,11 @@ public:
|
||||
return *this = ExecutionReportTradeSpread526(buffer, offset, bufferLength, actingBlockLength, actingVersion);
|
||||
}
|
||||
|
||||
ExecutionReportTradeSpread526 &sbeRewind()
|
||||
{
|
||||
return wrapForDecode(m_buffer, m_offset, m_actingBlockLength, m_actingVersion, m_bufferLength);
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::uint64_t sbePosition() const SBE_NOEXCEPT
|
||||
{
|
||||
return m_position;
|
||||
@@ -668,7 +675,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportTradeSpread526 &putExecID(const std::string& str)
|
||||
ExecutionReportTradeSpread526 &putExecID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 40)
|
||||
@@ -874,7 +881,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportTradeSpread526 &putSenderID(const std::string& str)
|
||||
ExecutionReportTradeSpread526 &putSenderID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -1080,7 +1087,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportTradeSpread526 &putClOrdID(const std::string& str)
|
||||
ExecutionReportTradeSpread526 &putClOrdID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -1995,7 +2002,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportTradeSpread526 &putLocation(const std::string& str)
|
||||
ExecutionReportTradeSpread526 &putLocation(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 5)
|
||||
@@ -3727,7 +3734,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
|
||||
inline std::uint64_t resetCountToIndex() SBE_NOEXCEPT
|
||||
inline std::uint64_t resetCountToIndex()
|
||||
{
|
||||
m_count = m_index;
|
||||
GroupSize dimensions(m_buffer, m_initialPosition, m_bufferLength, m_actingVersion);
|
||||
@@ -3735,8 +3742,7 @@ public:
|
||||
return m_count;
|
||||
}
|
||||
|
||||
#if __cplusplus < 201103L
|
||||
template<class Func> inline void forEach(Func& func)
|
||||
template<class Func> inline void forEach(Func &&func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
@@ -3745,17 +3751,6 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
#else
|
||||
template<class Func> inline void forEach(Func&& func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
next();
|
||||
func(*this);
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
SBE_NODISCARD static const char *FillPxMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
@@ -4075,7 +4070,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
NoFills &putFillExecID(const std::string& str)
|
||||
NoFills &putFillExecID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 2)
|
||||
@@ -4165,8 +4160,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, NoFills writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, NoFills writer)
|
||||
{
|
||||
builder << '{';
|
||||
builder << R"("FillPx": )";
|
||||
@@ -4378,7 +4373,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
|
||||
inline std::uint64_t resetCountToIndex() SBE_NOEXCEPT
|
||||
inline std::uint64_t resetCountToIndex()
|
||||
{
|
||||
m_count = m_index;
|
||||
GroupSize dimensions(m_buffer, m_initialPosition, m_bufferLength, m_actingVersion);
|
||||
@@ -4386,8 +4381,7 @@ public:
|
||||
return m_count;
|
||||
}
|
||||
|
||||
#if __cplusplus < 201103L
|
||||
template<class Func> inline void forEach(Func& func)
|
||||
template<class Func> inline void forEach(Func &&func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
@@ -4396,17 +4390,6 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
#else
|
||||
template<class Func> inline void forEach(Func&& func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
next();
|
||||
func(*this);
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
SBE_NODISCARD static const char *LegExecIDMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
@@ -4803,8 +4786,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, NoLegs writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, NoLegs writer)
|
||||
{
|
||||
builder << '{';
|
||||
builder << R"("LegExecID": )";
|
||||
@@ -5023,7 +5006,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
|
||||
inline std::uint64_t resetCountToIndex() SBE_NOEXCEPT
|
||||
inline std::uint64_t resetCountToIndex()
|
||||
{
|
||||
m_count = m_index;
|
||||
GroupSize dimensions(m_buffer, m_initialPosition, m_bufferLength, m_actingVersion);
|
||||
@@ -5031,8 +5014,7 @@ public:
|
||||
return m_count;
|
||||
}
|
||||
|
||||
#if __cplusplus < 201103L
|
||||
template<class Func> inline void forEach(Func& func)
|
||||
template<class Func> inline void forEach(Func &&func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
@@ -5041,17 +5023,6 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
#else
|
||||
template<class Func> inline void forEach(Func&& func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
next();
|
||||
func(*this);
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
SBE_NODISCARD static const char *OrderEventPxMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
@@ -5288,7 +5259,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
NoOrderEvents &putOrderEventText(const std::string& str)
|
||||
NoOrderEvents &putOrderEventText(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 5)
|
||||
@@ -5583,8 +5554,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, NoOrderEvents writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, NoOrderEvents writer)
|
||||
{
|
||||
builder << '{';
|
||||
builder << R"("OrderEventPx": )";
|
||||
@@ -5679,11 +5650,16 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, ExecutionReportTradeSpread526 _writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, ExecutionReportTradeSpread526 _writer)
|
||||
{
|
||||
ExecutionReportTradeSpread526 writer(_writer.m_buffer, _writer.m_offset,
|
||||
_writer.m_bufferLength, _writer.sbeBlockLength(), _writer.m_actingVersion);
|
||||
ExecutionReportTradeSpread526 writer(
|
||||
_writer.m_buffer,
|
||||
_writer.m_offset,
|
||||
_writer.m_bufferLength,
|
||||
_writer.m_actingBlockLength,
|
||||
_writer.m_actingVersion);
|
||||
|
||||
builder << '{';
|
||||
builder << R"("Name": "ExecutionReportTradeSpread526", )";
|
||||
builder << R"("sbeTemplateId": )";
|
||||
@@ -5853,15 +5829,16 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
{
|
||||
bool atLeastOne = false;
|
||||
builder << R"("NoFills": [)";
|
||||
writer.noFills().forEach([&](NoFills& noFills)
|
||||
{
|
||||
if (atLeastOne)
|
||||
writer.noFills().forEach(
|
||||
[&](NoFills &noFills)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noFills;
|
||||
});
|
||||
if (atLeastOne)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noFills;
|
||||
});
|
||||
builder << ']';
|
||||
}
|
||||
|
||||
@@ -5869,15 +5846,16 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
{
|
||||
bool atLeastOne = false;
|
||||
builder << R"("NoLegs": [)";
|
||||
writer.noLegs().forEach([&](NoLegs& noLegs)
|
||||
{
|
||||
if (atLeastOne)
|
||||
writer.noLegs().forEach(
|
||||
[&](NoLegs &noLegs)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noLegs;
|
||||
});
|
||||
if (atLeastOne)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noLegs;
|
||||
});
|
||||
builder << ']';
|
||||
}
|
||||
|
||||
@@ -5885,15 +5863,16 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
{
|
||||
bool atLeastOne = false;
|
||||
builder << R"("NoOrderEvents": [)";
|
||||
writer.noOrderEvents().forEach([&](NoOrderEvents& noOrderEvents)
|
||||
{
|
||||
if (atLeastOne)
|
||||
writer.noOrderEvents().forEach(
|
||||
[&](NoOrderEvents &noOrderEvents)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noOrderEvents;
|
||||
});
|
||||
if (atLeastOne)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noOrderEvents;
|
||||
});
|
||||
builder << ']';
|
||||
}
|
||||
|
||||
@@ -5904,18 +5883,21 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
|
||||
void skip()
|
||||
{
|
||||
noFills().forEach([](NoFills e)
|
||||
auto &noFillsGroup { noFills() };
|
||||
while (noFillsGroup.hasNext())
|
||||
{
|
||||
e.skip();
|
||||
});
|
||||
noLegs().forEach([](NoLegs e)
|
||||
noFillsGroup.next().skip();
|
||||
}
|
||||
auto &noLegsGroup { noLegs() };
|
||||
while (noLegsGroup.hasNext())
|
||||
{
|
||||
e.skip();
|
||||
});
|
||||
noOrderEvents().forEach([](NoOrderEvents e)
|
||||
noLegsGroup.next().skip();
|
||||
}
|
||||
auto &noOrderEventsGroup { noOrderEvents() };
|
||||
while (noOrderEventsGroup.hasNext())
|
||||
{
|
||||
e.skip();
|
||||
});
|
||||
noOrderEventsGroup.next().skip();
|
||||
}
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR bool isConstLength() SBE_NOEXCEPT
|
||||
|
||||
@@ -70,11 +70,11 @@
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (__builtin_expect(exp, c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
@@ -156,6 +156,7 @@ private:
|
||||
std::uint64_t m_bufferLength = 0;
|
||||
std::uint64_t m_offset = 0;
|
||||
std::uint64_t m_position = 0;
|
||||
std::uint64_t m_actingBlockLength = 0;
|
||||
std::uint64_t m_actingVersion = 0;
|
||||
|
||||
inline std::uint64_t *sbePositionPtr() SBE_NOEXCEPT
|
||||
@@ -167,7 +168,7 @@ public:
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(219);
|
||||
static const std::uint16_t SBE_TEMPLATE_ID = static_cast<std::uint16_t>(527);
|
||||
static const std::uint16_t SBE_SCHEMA_ID = static_cast<std::uint16_t>(8);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(7);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(8);
|
||||
|
||||
enum MetaAttribute
|
||||
{
|
||||
@@ -200,6 +201,7 @@ public:
|
||||
m_bufferLength(bufferLength),
|
||||
m_offset(offset),
|
||||
m_position(sbeCheckPosition(offset + actingBlockLength)),
|
||||
m_actingBlockLength(actingBlockLength),
|
||||
m_actingVersion(actingVersion)
|
||||
{
|
||||
}
|
||||
@@ -240,7 +242,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeSchemaVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(7);
|
||||
return static_cast<std::uint16_t>(8);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR const char *sbeSemanticType() SBE_NOEXCEPT
|
||||
@@ -286,6 +288,11 @@ public:
|
||||
return *this = ExecutionReportTradeSpreadLeg527(buffer, offset, bufferLength, actingBlockLength, actingVersion);
|
||||
}
|
||||
|
||||
ExecutionReportTradeSpreadLeg527 &sbeRewind()
|
||||
{
|
||||
return wrapForDecode(m_buffer, m_offset, m_actingBlockLength, m_actingVersion, m_bufferLength);
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::uint64_t sbePosition() const SBE_NOEXCEPT
|
||||
{
|
||||
return m_position;
|
||||
@@ -668,7 +675,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportTradeSpreadLeg527 &putExecID(const std::string& str)
|
||||
ExecutionReportTradeSpreadLeg527 &putExecID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 40)
|
||||
@@ -874,7 +881,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportTradeSpreadLeg527 &putSenderID(const std::string& str)
|
||||
ExecutionReportTradeSpreadLeg527 &putSenderID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -1080,7 +1087,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportTradeSpreadLeg527 &putClOrdID(const std::string& str)
|
||||
ExecutionReportTradeSpreadLeg527 &putClOrdID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -1782,7 +1789,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
ExecutionReportTradeSpreadLeg527 &putLocation(const std::string& str)
|
||||
ExecutionReportTradeSpreadLeg527 &putLocation(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 5)
|
||||
@@ -2969,7 +2976,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
|
||||
inline std::uint64_t resetCountToIndex() SBE_NOEXCEPT
|
||||
inline std::uint64_t resetCountToIndex()
|
||||
{
|
||||
m_count = m_index;
|
||||
GroupSize dimensions(m_buffer, m_initialPosition, m_bufferLength, m_actingVersion);
|
||||
@@ -2977,8 +2984,7 @@ public:
|
||||
return m_count;
|
||||
}
|
||||
|
||||
#if __cplusplus < 201103L
|
||||
template<class Func> inline void forEach(Func& func)
|
||||
template<class Func> inline void forEach(Func &&func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
@@ -2987,17 +2993,6 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
#else
|
||||
template<class Func> inline void forEach(Func&& func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
next();
|
||||
func(*this);
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
SBE_NODISCARD static const char *FillPxMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
@@ -3317,7 +3312,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
NoFills &putFillExecID(const std::string& str)
|
||||
NoFills &putFillExecID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 2)
|
||||
@@ -3407,8 +3402,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, NoFills writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, NoFills writer)
|
||||
{
|
||||
builder << '{';
|
||||
builder << R"("FillPx": )";
|
||||
@@ -3620,7 +3615,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
|
||||
inline std::uint64_t resetCountToIndex() SBE_NOEXCEPT
|
||||
inline std::uint64_t resetCountToIndex()
|
||||
{
|
||||
m_count = m_index;
|
||||
GroupSize dimensions(m_buffer, m_initialPosition, m_bufferLength, m_actingVersion);
|
||||
@@ -3628,8 +3623,7 @@ public:
|
||||
return m_count;
|
||||
}
|
||||
|
||||
#if __cplusplus < 201103L
|
||||
template<class Func> inline void forEach(Func& func)
|
||||
template<class Func> inline void forEach(Func &&func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
@@ -3638,17 +3632,6 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
#else
|
||||
template<class Func> inline void forEach(Func&& func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
next();
|
||||
func(*this);
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
SBE_NODISCARD static const char *OrderEventPxMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
@@ -3885,7 +3868,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
NoOrderEvents &putOrderEventText(const std::string& str)
|
||||
NoOrderEvents &putOrderEventText(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 5)
|
||||
@@ -4180,8 +4163,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, NoOrderEvents writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, NoOrderEvents writer)
|
||||
{
|
||||
builder << '{';
|
||||
builder << R"("OrderEventPx": )";
|
||||
@@ -4276,11 +4259,16 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, ExecutionReportTradeSpreadLeg527 _writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, ExecutionReportTradeSpreadLeg527 _writer)
|
||||
{
|
||||
ExecutionReportTradeSpreadLeg527 writer(_writer.m_buffer, _writer.m_offset,
|
||||
_writer.m_bufferLength, _writer.sbeBlockLength(), _writer.m_actingVersion);
|
||||
ExecutionReportTradeSpreadLeg527 writer(
|
||||
_writer.m_buffer,
|
||||
_writer.m_offset,
|
||||
_writer.m_bufferLength,
|
||||
_writer.m_actingBlockLength,
|
||||
_writer.m_actingVersion);
|
||||
|
||||
builder << '{';
|
||||
builder << R"("Name": "ExecutionReportTradeSpreadLeg527", )";
|
||||
builder << R"("sbeTemplateId": )";
|
||||
@@ -4400,25 +4388,40 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("CalculatedCcyLastQty": )";
|
||||
builder << writer.calculatedCcyLastQty();
|
||||
if (writer.calculatedCcyLastQtyInActingVersion())
|
||||
{
|
||||
builder << writer.calculatedCcyLastQty();
|
||||
}
|
||||
else
|
||||
{
|
||||
builder << "{}";
|
||||
}
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("GrossTradeAmt": )";
|
||||
builder << writer.grossTradeAmt();
|
||||
if (writer.grossTradeAmtInActingVersion())
|
||||
{
|
||||
builder << writer.grossTradeAmt();
|
||||
}
|
||||
else
|
||||
{
|
||||
builder << "{}";
|
||||
}
|
||||
|
||||
builder << ", ";
|
||||
{
|
||||
bool atLeastOne = false;
|
||||
builder << R"("NoFills": [)";
|
||||
writer.noFills().forEach([&](NoFills& noFills)
|
||||
{
|
||||
if (atLeastOne)
|
||||
writer.noFills().forEach(
|
||||
[&](NoFills &noFills)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noFills;
|
||||
});
|
||||
if (atLeastOne)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noFills;
|
||||
});
|
||||
builder << ']';
|
||||
}
|
||||
|
||||
@@ -4426,15 +4429,16 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
{
|
||||
bool atLeastOne = false;
|
||||
builder << R"("NoOrderEvents": [)";
|
||||
writer.noOrderEvents().forEach([&](NoOrderEvents& noOrderEvents)
|
||||
{
|
||||
if (atLeastOne)
|
||||
writer.noOrderEvents().forEach(
|
||||
[&](NoOrderEvents &noOrderEvents)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noOrderEvents;
|
||||
});
|
||||
if (atLeastOne)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noOrderEvents;
|
||||
});
|
||||
builder << ']';
|
||||
}
|
||||
|
||||
@@ -4445,14 +4449,16 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
|
||||
void skip()
|
||||
{
|
||||
noFills().forEach([](NoFills e)
|
||||
auto &noFillsGroup { noFills() };
|
||||
while (noFillsGroup.hasNext())
|
||||
{
|
||||
e.skip();
|
||||
});
|
||||
noOrderEvents().forEach([](NoOrderEvents e)
|
||||
noFillsGroup.next().skip();
|
||||
}
|
||||
auto &noOrderEventsGroup { noOrderEvents() };
|
||||
while (noOrderEventsGroup.hasNext())
|
||||
{
|
||||
e.skip();
|
||||
});
|
||||
noOrderEventsGroup.next().skip();
|
||||
}
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR bool isConstLength() SBE_NOEXCEPT
|
||||
|
||||
@@ -2,80 +2,17 @@
|
||||
#ifndef _ILINKBINARY_EXPCYCLE_H_
|
||||
#define _ILINKBINARY_EXPCYCLE_H_
|
||||
|
||||
#if defined(SBE_HAVE_CMATH)
|
||||
/* cmath needed for std::numeric_limits<double>::quiet_NaN() */
|
||||
# include <cmath>
|
||||
# define SBE_FLOAT_NAN std::numeric_limits<float>::quiet_NaN()
|
||||
# define SBE_DOUBLE_NAN std::numeric_limits<double>::quiet_NaN()
|
||||
#else
|
||||
/* math.h needed for NAN */
|
||||
# include <math.h>
|
||||
# define SBE_FLOAT_NAN NAN
|
||||
# define SBE_DOUBLE_NAN NAN
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201103L
|
||||
# define SBE_CONSTEXPR constexpr
|
||||
# define SBE_NOEXCEPT noexcept
|
||||
#else
|
||||
# define SBE_CONSTEXPR
|
||||
# define SBE_NOEXCEPT
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
# include <string_view>
|
||||
# define SBE_NODISCARD [[nodiscard]]
|
||||
#else
|
||||
# define SBE_NODISCARD
|
||||
#endif
|
||||
|
||||
#if !defined(__STDC_LIMIT_MACROS)
|
||||
# define __STDC_LIMIT_MACROS 1
|
||||
#endif
|
||||
|
||||
#include <cstdint>
|
||||
#include <cstring>
|
||||
#include <iomanip>
|
||||
#include <limits>
|
||||
#include <ostream>
|
||||
#include <stdexcept>
|
||||
#include <sstream>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <tuple>
|
||||
|
||||
#if defined(WIN32) || defined(_WIN32)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) _byteswap_ushort(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) _byteswap_ulong(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) _byteswap_uint64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) (v)
|
||||
#else
|
||||
# error "Byte Ordering of platform not determined. Set __BYTE_ORDER__ manually before including this file."
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
#define SBE_NULLVALUE_INT16 (std::numeric_limits<std::int16_t>::min)()
|
||||
@@ -86,7 +23,6 @@
|
||||
#define SBE_NULLVALUE_UINT32 (std::numeric_limits<std::uint32_t>::max)()
|
||||
#define SBE_NULLVALUE_UINT64 (std::numeric_limits<std::uint64_t>::max)()
|
||||
|
||||
|
||||
namespace iLinkBinary {
|
||||
|
||||
class ExpCycle
|
||||
@@ -124,8 +60,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& os, ExpCycle::Value m)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &os, ExpCycle::Value m)
|
||||
{
|
||||
return os << ExpCycle::c_str(m);
|
||||
}
|
||||
|
||||
@@ -2,80 +2,17 @@
|
||||
#ifndef _ILINKBINARY_FTI_H_
|
||||
#define _ILINKBINARY_FTI_H_
|
||||
|
||||
#if defined(SBE_HAVE_CMATH)
|
||||
/* cmath needed for std::numeric_limits<double>::quiet_NaN() */
|
||||
# include <cmath>
|
||||
# define SBE_FLOAT_NAN std::numeric_limits<float>::quiet_NaN()
|
||||
# define SBE_DOUBLE_NAN std::numeric_limits<double>::quiet_NaN()
|
||||
#else
|
||||
/* math.h needed for NAN */
|
||||
# include <math.h>
|
||||
# define SBE_FLOAT_NAN NAN
|
||||
# define SBE_DOUBLE_NAN NAN
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201103L
|
||||
# define SBE_CONSTEXPR constexpr
|
||||
# define SBE_NOEXCEPT noexcept
|
||||
#else
|
||||
# define SBE_CONSTEXPR
|
||||
# define SBE_NOEXCEPT
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
# include <string_view>
|
||||
# define SBE_NODISCARD [[nodiscard]]
|
||||
#else
|
||||
# define SBE_NODISCARD
|
||||
#endif
|
||||
|
||||
#if !defined(__STDC_LIMIT_MACROS)
|
||||
# define __STDC_LIMIT_MACROS 1
|
||||
#endif
|
||||
|
||||
#include <cstdint>
|
||||
#include <cstring>
|
||||
#include <iomanip>
|
||||
#include <limits>
|
||||
#include <ostream>
|
||||
#include <stdexcept>
|
||||
#include <sstream>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <tuple>
|
||||
|
||||
#if defined(WIN32) || defined(_WIN32)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) _byteswap_ushort(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) _byteswap_ulong(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) _byteswap_uint64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) (v)
|
||||
#else
|
||||
# error "Byte Ordering of platform not determined. Set __BYTE_ORDER__ manually before including this file."
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
#define SBE_NULLVALUE_INT16 (std::numeric_limits<std::int16_t>::min)()
|
||||
@@ -86,7 +23,6 @@
|
||||
#define SBE_NULLVALUE_UINT32 (std::numeric_limits<std::uint32_t>::max)()
|
||||
#define SBE_NULLVALUE_UINT64 (std::numeric_limits<std::uint64_t>::max)()
|
||||
|
||||
|
||||
namespace iLinkBinary {
|
||||
|
||||
class FTI
|
||||
@@ -124,8 +60,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& os, FTI::Value m)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &os, FTI::Value m)
|
||||
{
|
||||
return os << FTI::c_str(m);
|
||||
}
|
||||
|
||||
@@ -70,11 +70,11 @@
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (__builtin_expect(exp, c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
@@ -194,7 +194,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeSchemaVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(7);
|
||||
return static_cast<std::uint16_t>(8);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static const char *blockLengthMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
@@ -338,8 +338,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, GroupSize writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, GroupSize writer)
|
||||
{
|
||||
builder << '{';
|
||||
builder << R"("blockLength": )";
|
||||
|
||||
@@ -2,80 +2,17 @@
|
||||
#ifndef _ILINKBINARY_KEEPALIVELAPSED_H_
|
||||
#define _ILINKBINARY_KEEPALIVELAPSED_H_
|
||||
|
||||
#if defined(SBE_HAVE_CMATH)
|
||||
/* cmath needed for std::numeric_limits<double>::quiet_NaN() */
|
||||
# include <cmath>
|
||||
# define SBE_FLOAT_NAN std::numeric_limits<float>::quiet_NaN()
|
||||
# define SBE_DOUBLE_NAN std::numeric_limits<double>::quiet_NaN()
|
||||
#else
|
||||
/* math.h needed for NAN */
|
||||
# include <math.h>
|
||||
# define SBE_FLOAT_NAN NAN
|
||||
# define SBE_DOUBLE_NAN NAN
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201103L
|
||||
# define SBE_CONSTEXPR constexpr
|
||||
# define SBE_NOEXCEPT noexcept
|
||||
#else
|
||||
# define SBE_CONSTEXPR
|
||||
# define SBE_NOEXCEPT
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
# include <string_view>
|
||||
# define SBE_NODISCARD [[nodiscard]]
|
||||
#else
|
||||
# define SBE_NODISCARD
|
||||
#endif
|
||||
|
||||
#if !defined(__STDC_LIMIT_MACROS)
|
||||
# define __STDC_LIMIT_MACROS 1
|
||||
#endif
|
||||
|
||||
#include <cstdint>
|
||||
#include <cstring>
|
||||
#include <iomanip>
|
||||
#include <limits>
|
||||
#include <ostream>
|
||||
#include <stdexcept>
|
||||
#include <sstream>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <tuple>
|
||||
|
||||
#if defined(WIN32) || defined(_WIN32)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) _byteswap_ushort(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) _byteswap_ulong(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) _byteswap_uint64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) (v)
|
||||
#else
|
||||
# error "Byte Ordering of platform not determined. Set __BYTE_ORDER__ manually before including this file."
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
#define SBE_NULLVALUE_INT16 (std::numeric_limits<std::int16_t>::min)()
|
||||
@@ -86,7 +23,6 @@
|
||||
#define SBE_NULLVALUE_UINT32 (std::numeric_limits<std::uint32_t>::max)()
|
||||
#define SBE_NULLVALUE_UINT64 (std::numeric_limits<std::uint64_t>::max)()
|
||||
|
||||
|
||||
namespace iLinkBinary {
|
||||
|
||||
class KeepAliveLapsed
|
||||
@@ -124,8 +60,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& os, KeepAliveLapsed::Value m)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &os, KeepAliveLapsed::Value m)
|
||||
{
|
||||
return os << KeepAliveLapsed::c_str(m);
|
||||
}
|
||||
|
||||
@@ -2,80 +2,17 @@
|
||||
#ifndef _ILINKBINARY_LISTUPDACT_H_
|
||||
#define _ILINKBINARY_LISTUPDACT_H_
|
||||
|
||||
#if defined(SBE_HAVE_CMATH)
|
||||
/* cmath needed for std::numeric_limits<double>::quiet_NaN() */
|
||||
# include <cmath>
|
||||
# define SBE_FLOAT_NAN std::numeric_limits<float>::quiet_NaN()
|
||||
# define SBE_DOUBLE_NAN std::numeric_limits<double>::quiet_NaN()
|
||||
#else
|
||||
/* math.h needed for NAN */
|
||||
# include <math.h>
|
||||
# define SBE_FLOAT_NAN NAN
|
||||
# define SBE_DOUBLE_NAN NAN
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201103L
|
||||
# define SBE_CONSTEXPR constexpr
|
||||
# define SBE_NOEXCEPT noexcept
|
||||
#else
|
||||
# define SBE_CONSTEXPR
|
||||
# define SBE_NOEXCEPT
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
# include <string_view>
|
||||
# define SBE_NODISCARD [[nodiscard]]
|
||||
#else
|
||||
# define SBE_NODISCARD
|
||||
#endif
|
||||
|
||||
#if !defined(__STDC_LIMIT_MACROS)
|
||||
# define __STDC_LIMIT_MACROS 1
|
||||
#endif
|
||||
|
||||
#include <cstdint>
|
||||
#include <cstring>
|
||||
#include <iomanip>
|
||||
#include <limits>
|
||||
#include <ostream>
|
||||
#include <stdexcept>
|
||||
#include <sstream>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <tuple>
|
||||
|
||||
#if defined(WIN32) || defined(_WIN32)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) _byteswap_ushort(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) _byteswap_ulong(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) _byteswap_uint64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) (v)
|
||||
#else
|
||||
# error "Byte Ordering of platform not determined. Set __BYTE_ORDER__ manually before including this file."
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
#define SBE_NULLVALUE_INT16 (std::numeric_limits<std::int16_t>::min)()
|
||||
@@ -86,7 +23,6 @@
|
||||
#define SBE_NULLVALUE_UINT32 (std::numeric_limits<std::uint32_t>::max)()
|
||||
#define SBE_NULLVALUE_UINT64 (std::numeric_limits<std::uint64_t>::max)()
|
||||
|
||||
|
||||
namespace iLinkBinary {
|
||||
|
||||
class ListUpdAct
|
||||
@@ -124,8 +60,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& os, ListUpdAct::Value m)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &os, ListUpdAct::Value m)
|
||||
{
|
||||
return os << ListUpdAct::c_str(m);
|
||||
}
|
||||
|
||||
@@ -2,80 +2,17 @@
|
||||
#ifndef _ILINKBINARY_MANUALORDIND_H_
|
||||
#define _ILINKBINARY_MANUALORDIND_H_
|
||||
|
||||
#if defined(SBE_HAVE_CMATH)
|
||||
/* cmath needed for std::numeric_limits<double>::quiet_NaN() */
|
||||
# include <cmath>
|
||||
# define SBE_FLOAT_NAN std::numeric_limits<float>::quiet_NaN()
|
||||
# define SBE_DOUBLE_NAN std::numeric_limits<double>::quiet_NaN()
|
||||
#else
|
||||
/* math.h needed for NAN */
|
||||
# include <math.h>
|
||||
# define SBE_FLOAT_NAN NAN
|
||||
# define SBE_DOUBLE_NAN NAN
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201103L
|
||||
# define SBE_CONSTEXPR constexpr
|
||||
# define SBE_NOEXCEPT noexcept
|
||||
#else
|
||||
# define SBE_CONSTEXPR
|
||||
# define SBE_NOEXCEPT
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
# include <string_view>
|
||||
# define SBE_NODISCARD [[nodiscard]]
|
||||
#else
|
||||
# define SBE_NODISCARD
|
||||
#endif
|
||||
|
||||
#if !defined(__STDC_LIMIT_MACROS)
|
||||
# define __STDC_LIMIT_MACROS 1
|
||||
#endif
|
||||
|
||||
#include <cstdint>
|
||||
#include <cstring>
|
||||
#include <iomanip>
|
||||
#include <limits>
|
||||
#include <ostream>
|
||||
#include <stdexcept>
|
||||
#include <sstream>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <tuple>
|
||||
|
||||
#if defined(WIN32) || defined(_WIN32)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) _byteswap_ushort(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) _byteswap_ulong(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) _byteswap_uint64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) (v)
|
||||
#else
|
||||
# error "Byte Ordering of platform not determined. Set __BYTE_ORDER__ manually before including this file."
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
#define SBE_NULLVALUE_INT16 (std::numeric_limits<std::int16_t>::min)()
|
||||
@@ -86,7 +23,6 @@
|
||||
#define SBE_NULLVALUE_UINT32 (std::numeric_limits<std::uint32_t>::max)()
|
||||
#define SBE_NULLVALUE_UINT64 (std::numeric_limits<std::uint64_t>::max)()
|
||||
|
||||
|
||||
namespace iLinkBinary {
|
||||
|
||||
class ManualOrdInd
|
||||
@@ -124,8 +60,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& os, ManualOrdInd::Value m)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &os, ManualOrdInd::Value m)
|
||||
{
|
||||
return os << ManualOrdInd::c_str(m);
|
||||
}
|
||||
|
||||
@@ -2,80 +2,17 @@
|
||||
#ifndef _ILINKBINARY_MANUALORDINDREQ_H_
|
||||
#define _ILINKBINARY_MANUALORDINDREQ_H_
|
||||
|
||||
#if defined(SBE_HAVE_CMATH)
|
||||
/* cmath needed for std::numeric_limits<double>::quiet_NaN() */
|
||||
# include <cmath>
|
||||
# define SBE_FLOAT_NAN std::numeric_limits<float>::quiet_NaN()
|
||||
# define SBE_DOUBLE_NAN std::numeric_limits<double>::quiet_NaN()
|
||||
#else
|
||||
/* math.h needed for NAN */
|
||||
# include <math.h>
|
||||
# define SBE_FLOAT_NAN NAN
|
||||
# define SBE_DOUBLE_NAN NAN
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201103L
|
||||
# define SBE_CONSTEXPR constexpr
|
||||
# define SBE_NOEXCEPT noexcept
|
||||
#else
|
||||
# define SBE_CONSTEXPR
|
||||
# define SBE_NOEXCEPT
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
# include <string_view>
|
||||
# define SBE_NODISCARD [[nodiscard]]
|
||||
#else
|
||||
# define SBE_NODISCARD
|
||||
#endif
|
||||
|
||||
#if !defined(__STDC_LIMIT_MACROS)
|
||||
# define __STDC_LIMIT_MACROS 1
|
||||
#endif
|
||||
|
||||
#include <cstdint>
|
||||
#include <cstring>
|
||||
#include <iomanip>
|
||||
#include <limits>
|
||||
#include <ostream>
|
||||
#include <stdexcept>
|
||||
#include <sstream>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <tuple>
|
||||
|
||||
#if defined(WIN32) || defined(_WIN32)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) _byteswap_ushort(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) _byteswap_ulong(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) _byteswap_uint64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) (v)
|
||||
#else
|
||||
# error "Byte Ordering of platform not determined. Set __BYTE_ORDER__ manually before including this file."
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
#define SBE_NULLVALUE_INT16 (std::numeric_limits<std::int16_t>::min)()
|
||||
@@ -86,7 +23,6 @@
|
||||
#define SBE_NULLVALUE_UINT32 (std::numeric_limits<std::uint32_t>::max)()
|
||||
#define SBE_NULLVALUE_UINT64 (std::numeric_limits<std::uint64_t>::max)()
|
||||
|
||||
|
||||
namespace iLinkBinary {
|
||||
|
||||
class ManualOrdIndReq
|
||||
@@ -124,8 +60,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& os, ManualOrdIndReq::Value m)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &os, ManualOrdIndReq::Value m)
|
||||
{
|
||||
return os << ManualOrdIndReq::c_str(m);
|
||||
}
|
||||
|
||||
@@ -2,80 +2,17 @@
|
||||
#ifndef _ILINKBINARY_MASSACTIONORDTYP_H_
|
||||
#define _ILINKBINARY_MASSACTIONORDTYP_H_
|
||||
|
||||
#if defined(SBE_HAVE_CMATH)
|
||||
/* cmath needed for std::numeric_limits<double>::quiet_NaN() */
|
||||
# include <cmath>
|
||||
# define SBE_FLOAT_NAN std::numeric_limits<float>::quiet_NaN()
|
||||
# define SBE_DOUBLE_NAN std::numeric_limits<double>::quiet_NaN()
|
||||
#else
|
||||
/* math.h needed for NAN */
|
||||
# include <math.h>
|
||||
# define SBE_FLOAT_NAN NAN
|
||||
# define SBE_DOUBLE_NAN NAN
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201103L
|
||||
# define SBE_CONSTEXPR constexpr
|
||||
# define SBE_NOEXCEPT noexcept
|
||||
#else
|
||||
# define SBE_CONSTEXPR
|
||||
# define SBE_NOEXCEPT
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
# include <string_view>
|
||||
# define SBE_NODISCARD [[nodiscard]]
|
||||
#else
|
||||
# define SBE_NODISCARD
|
||||
#endif
|
||||
|
||||
#if !defined(__STDC_LIMIT_MACROS)
|
||||
# define __STDC_LIMIT_MACROS 1
|
||||
#endif
|
||||
|
||||
#include <cstdint>
|
||||
#include <cstring>
|
||||
#include <iomanip>
|
||||
#include <limits>
|
||||
#include <ostream>
|
||||
#include <stdexcept>
|
||||
#include <sstream>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <tuple>
|
||||
|
||||
#if defined(WIN32) || defined(_WIN32)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) _byteswap_ushort(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) _byteswap_ulong(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) _byteswap_uint64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) (v)
|
||||
#else
|
||||
# error "Byte Ordering of platform not determined. Set __BYTE_ORDER__ manually before including this file."
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
#define SBE_NULLVALUE_INT16 (std::numeric_limits<std::int16_t>::min)()
|
||||
@@ -86,7 +23,6 @@
|
||||
#define SBE_NULLVALUE_UINT32 (std::numeric_limits<std::uint32_t>::max)()
|
||||
#define SBE_NULLVALUE_UINT64 (std::numeric_limits<std::uint64_t>::max)()
|
||||
|
||||
|
||||
namespace iLinkBinary {
|
||||
|
||||
class MassActionOrdTyp
|
||||
@@ -96,7 +32,7 @@ public:
|
||||
{
|
||||
Limit = static_cast<char>(50),
|
||||
StopLimit = static_cast<char>(52),
|
||||
NULL_VALUE = static_cast<char>(0)
|
||||
NULL_VALUE = static_cast<char>(48)
|
||||
};
|
||||
|
||||
static MassActionOrdTyp::Value get(const char value)
|
||||
@@ -105,7 +41,7 @@ public:
|
||||
{
|
||||
case static_cast<char>(50): return Limit;
|
||||
case static_cast<char>(52): return StopLimit;
|
||||
case static_cast<char>(0): return NULL_VALUE;
|
||||
case static_cast<char>(48): return NULL_VALUE;
|
||||
}
|
||||
|
||||
throw std::runtime_error("unknown value for enum MassActionOrdTyp [E103]");
|
||||
@@ -124,8 +60,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& os, MassActionOrdTyp::Value m)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &os, MassActionOrdTyp::Value m)
|
||||
{
|
||||
return os << MassActionOrdTyp::c_str(m);
|
||||
}
|
||||
|
||||
@@ -2,80 +2,17 @@
|
||||
#ifndef _ILINKBINARY_MASSACTIONRESPONSE_H_
|
||||
#define _ILINKBINARY_MASSACTIONRESPONSE_H_
|
||||
|
||||
#if defined(SBE_HAVE_CMATH)
|
||||
/* cmath needed for std::numeric_limits<double>::quiet_NaN() */
|
||||
# include <cmath>
|
||||
# define SBE_FLOAT_NAN std::numeric_limits<float>::quiet_NaN()
|
||||
# define SBE_DOUBLE_NAN std::numeric_limits<double>::quiet_NaN()
|
||||
#else
|
||||
/* math.h needed for NAN */
|
||||
# include <math.h>
|
||||
# define SBE_FLOAT_NAN NAN
|
||||
# define SBE_DOUBLE_NAN NAN
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201103L
|
||||
# define SBE_CONSTEXPR constexpr
|
||||
# define SBE_NOEXCEPT noexcept
|
||||
#else
|
||||
# define SBE_CONSTEXPR
|
||||
# define SBE_NOEXCEPT
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
# include <string_view>
|
||||
# define SBE_NODISCARD [[nodiscard]]
|
||||
#else
|
||||
# define SBE_NODISCARD
|
||||
#endif
|
||||
|
||||
#if !defined(__STDC_LIMIT_MACROS)
|
||||
# define __STDC_LIMIT_MACROS 1
|
||||
#endif
|
||||
|
||||
#include <cstdint>
|
||||
#include <cstring>
|
||||
#include <iomanip>
|
||||
#include <limits>
|
||||
#include <ostream>
|
||||
#include <stdexcept>
|
||||
#include <sstream>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <tuple>
|
||||
|
||||
#if defined(WIN32) || defined(_WIN32)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) _byteswap_ushort(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) _byteswap_ulong(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) _byteswap_uint64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) (v)
|
||||
#else
|
||||
# error "Byte Ordering of platform not determined. Set __BYTE_ORDER__ manually before including this file."
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
#define SBE_NULLVALUE_INT16 (std::numeric_limits<std::int16_t>::min)()
|
||||
@@ -86,7 +23,6 @@
|
||||
#define SBE_NULLVALUE_UINT32 (std::numeric_limits<std::uint32_t>::max)()
|
||||
#define SBE_NULLVALUE_UINT64 (std::numeric_limits<std::uint64_t>::max)()
|
||||
|
||||
|
||||
namespace iLinkBinary {
|
||||
|
||||
class MassActionResponse
|
||||
@@ -124,8 +60,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& os, MassActionResponse::Value m)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &os, MassActionResponse::Value m)
|
||||
{
|
||||
return os << MassActionResponse::c_str(m);
|
||||
}
|
||||
|
||||
@@ -2,80 +2,17 @@
|
||||
#ifndef _ILINKBINARY_MASSACTIONSCOPE_H_
|
||||
#define _ILINKBINARY_MASSACTIONSCOPE_H_
|
||||
|
||||
#if defined(SBE_HAVE_CMATH)
|
||||
/* cmath needed for std::numeric_limits<double>::quiet_NaN() */
|
||||
# include <cmath>
|
||||
# define SBE_FLOAT_NAN std::numeric_limits<float>::quiet_NaN()
|
||||
# define SBE_DOUBLE_NAN std::numeric_limits<double>::quiet_NaN()
|
||||
#else
|
||||
/* math.h needed for NAN */
|
||||
# include <math.h>
|
||||
# define SBE_FLOAT_NAN NAN
|
||||
# define SBE_DOUBLE_NAN NAN
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201103L
|
||||
# define SBE_CONSTEXPR constexpr
|
||||
# define SBE_NOEXCEPT noexcept
|
||||
#else
|
||||
# define SBE_CONSTEXPR
|
||||
# define SBE_NOEXCEPT
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
# include <string_view>
|
||||
# define SBE_NODISCARD [[nodiscard]]
|
||||
#else
|
||||
# define SBE_NODISCARD
|
||||
#endif
|
||||
|
||||
#if !defined(__STDC_LIMIT_MACROS)
|
||||
# define __STDC_LIMIT_MACROS 1
|
||||
#endif
|
||||
|
||||
#include <cstdint>
|
||||
#include <cstring>
|
||||
#include <iomanip>
|
||||
#include <limits>
|
||||
#include <ostream>
|
||||
#include <stdexcept>
|
||||
#include <sstream>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <tuple>
|
||||
|
||||
#if defined(WIN32) || defined(_WIN32)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) _byteswap_ushort(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) _byteswap_ulong(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) _byteswap_uint64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) (v)
|
||||
#else
|
||||
# error "Byte Ordering of platform not determined. Set __BYTE_ORDER__ manually before including this file."
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
#define SBE_NULLVALUE_INT16 (std::numeric_limits<std::int16_t>::min)()
|
||||
@@ -86,7 +23,6 @@
|
||||
#define SBE_NULLVALUE_UINT32 (std::numeric_limits<std::uint32_t>::max)()
|
||||
#define SBE_NULLVALUE_UINT64 (std::numeric_limits<std::uint64_t>::max)()
|
||||
|
||||
|
||||
namespace iLinkBinary {
|
||||
|
||||
class MassActionScope
|
||||
@@ -133,8 +69,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& os, MassActionScope::Value m)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &os, MassActionScope::Value m)
|
||||
{
|
||||
return os << MassActionScope::c_str(m);
|
||||
}
|
||||
|
||||
@@ -2,80 +2,17 @@
|
||||
#ifndef _ILINKBINARY_MASSCANCELTIF_H_
|
||||
#define _ILINKBINARY_MASSCANCELTIF_H_
|
||||
|
||||
#if defined(SBE_HAVE_CMATH)
|
||||
/* cmath needed for std::numeric_limits<double>::quiet_NaN() */
|
||||
# include <cmath>
|
||||
# define SBE_FLOAT_NAN std::numeric_limits<float>::quiet_NaN()
|
||||
# define SBE_DOUBLE_NAN std::numeric_limits<double>::quiet_NaN()
|
||||
#else
|
||||
/* math.h needed for NAN */
|
||||
# include <math.h>
|
||||
# define SBE_FLOAT_NAN NAN
|
||||
# define SBE_DOUBLE_NAN NAN
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201103L
|
||||
# define SBE_CONSTEXPR constexpr
|
||||
# define SBE_NOEXCEPT noexcept
|
||||
#else
|
||||
# define SBE_CONSTEXPR
|
||||
# define SBE_NOEXCEPT
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
# include <string_view>
|
||||
# define SBE_NODISCARD [[nodiscard]]
|
||||
#else
|
||||
# define SBE_NODISCARD
|
||||
#endif
|
||||
|
||||
#if !defined(__STDC_LIMIT_MACROS)
|
||||
# define __STDC_LIMIT_MACROS 1
|
||||
#endif
|
||||
|
||||
#include <cstdint>
|
||||
#include <cstring>
|
||||
#include <iomanip>
|
||||
#include <limits>
|
||||
#include <ostream>
|
||||
#include <stdexcept>
|
||||
#include <sstream>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <tuple>
|
||||
|
||||
#if defined(WIN32) || defined(_WIN32)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) _byteswap_ushort(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) _byteswap_ulong(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) _byteswap_uint64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) (v)
|
||||
#else
|
||||
# error "Byte Ordering of platform not determined. Set __BYTE_ORDER__ manually before including this file."
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
#define SBE_NULLVALUE_INT16 (std::numeric_limits<std::int16_t>::min)()
|
||||
@@ -86,7 +23,6 @@
|
||||
#define SBE_NULLVALUE_UINT32 (std::numeric_limits<std::uint32_t>::max)()
|
||||
#define SBE_NULLVALUE_UINT64 (std::numeric_limits<std::uint64_t>::max)()
|
||||
|
||||
|
||||
namespace iLinkBinary {
|
||||
|
||||
class MassCancelTIF
|
||||
@@ -127,8 +63,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& os, MassCancelTIF::Value m)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &os, MassCancelTIF::Value m)
|
||||
{
|
||||
return os << MassCancelTIF::c_str(m);
|
||||
}
|
||||
|
||||
@@ -2,80 +2,17 @@
|
||||
#ifndef _ILINKBINARY_MASSCXLREQTYP_H_
|
||||
#define _ILINKBINARY_MASSCXLREQTYP_H_
|
||||
|
||||
#if defined(SBE_HAVE_CMATH)
|
||||
/* cmath needed for std::numeric_limits<double>::quiet_NaN() */
|
||||
# include <cmath>
|
||||
# define SBE_FLOAT_NAN std::numeric_limits<float>::quiet_NaN()
|
||||
# define SBE_DOUBLE_NAN std::numeric_limits<double>::quiet_NaN()
|
||||
#else
|
||||
/* math.h needed for NAN */
|
||||
# include <math.h>
|
||||
# define SBE_FLOAT_NAN NAN
|
||||
# define SBE_DOUBLE_NAN NAN
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201103L
|
||||
# define SBE_CONSTEXPR constexpr
|
||||
# define SBE_NOEXCEPT noexcept
|
||||
#else
|
||||
# define SBE_CONSTEXPR
|
||||
# define SBE_NOEXCEPT
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
# include <string_view>
|
||||
# define SBE_NODISCARD [[nodiscard]]
|
||||
#else
|
||||
# define SBE_NODISCARD
|
||||
#endif
|
||||
|
||||
#if !defined(__STDC_LIMIT_MACROS)
|
||||
# define __STDC_LIMIT_MACROS 1
|
||||
#endif
|
||||
|
||||
#include <cstdint>
|
||||
#include <cstring>
|
||||
#include <iomanip>
|
||||
#include <limits>
|
||||
#include <ostream>
|
||||
#include <stdexcept>
|
||||
#include <sstream>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <tuple>
|
||||
|
||||
#if defined(WIN32) || defined(_WIN32)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) _byteswap_ushort(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) _byteswap_ulong(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) _byteswap_uint64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) (v)
|
||||
#else
|
||||
# error "Byte Ordering of platform not determined. Set __BYTE_ORDER__ manually before including this file."
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
#define SBE_NULLVALUE_INT16 (std::numeric_limits<std::int16_t>::min)()
|
||||
@@ -86,7 +23,6 @@
|
||||
#define SBE_NULLVALUE_UINT32 (std::numeric_limits<std::uint32_t>::max)()
|
||||
#define SBE_NULLVALUE_UINT64 (std::numeric_limits<std::uint64_t>::max)()
|
||||
|
||||
|
||||
namespace iLinkBinary {
|
||||
|
||||
class MassCxlReqTyp
|
||||
@@ -124,8 +60,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& os, MassCxlReqTyp::Value m)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &os, MassCxlReqTyp::Value m)
|
||||
{
|
||||
return os << MassCxlReqTyp::c_str(m);
|
||||
}
|
||||
|
||||
@@ -70,11 +70,11 @@
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (__builtin_expect(exp, c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
@@ -156,6 +156,7 @@ private:
|
||||
std::uint64_t m_bufferLength = 0;
|
||||
std::uint64_t m_offset = 0;
|
||||
std::uint64_t m_position = 0;
|
||||
std::uint64_t m_actingBlockLength = 0;
|
||||
std::uint64_t m_actingVersion = 0;
|
||||
|
||||
inline std::uint64_t *sbePositionPtr() SBE_NOEXCEPT
|
||||
@@ -164,10 +165,10 @@ private:
|
||||
}
|
||||
|
||||
public:
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(92);
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(123);
|
||||
static const std::uint16_t SBE_TEMPLATE_ID = static_cast<std::uint16_t>(517);
|
||||
static const std::uint16_t SBE_SCHEMA_ID = static_cast<std::uint16_t>(8);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(7);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(8);
|
||||
|
||||
enum MetaAttribute
|
||||
{
|
||||
@@ -200,6 +201,7 @@ public:
|
||||
m_bufferLength(bufferLength),
|
||||
m_offset(offset),
|
||||
m_position(sbeCheckPosition(offset + actingBlockLength)),
|
||||
m_actingBlockLength(actingBlockLength),
|
||||
m_actingVersion(actingVersion)
|
||||
{
|
||||
}
|
||||
@@ -220,7 +222,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeBlockLength() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(92);
|
||||
return static_cast<std::uint16_t>(123);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint64_t sbeBlockAndHeaderLength() SBE_NOEXCEPT
|
||||
@@ -240,7 +242,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeSchemaVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(7);
|
||||
return static_cast<std::uint16_t>(8);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR const char *sbeSemanticType() SBE_NOEXCEPT
|
||||
@@ -286,6 +288,11 @@ public:
|
||||
return *this = MassQuote517(buffer, offset, bufferLength, actingBlockLength, actingVersion);
|
||||
}
|
||||
|
||||
MassQuote517 &sbeRewind()
|
||||
{
|
||||
return wrapForDecode(m_buffer, m_offset, m_actingBlockLength, m_actingVersion, m_bufferLength);
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::uint64_t sbePosition() const SBE_NOEXCEPT
|
||||
{
|
||||
return m_position;
|
||||
@@ -802,7 +809,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
MassQuote517 &putSenderID(const std::string& str)
|
||||
MassQuote517 &putSenderID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -1079,7 +1086,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
MassQuote517 &putLocation(const std::string& str)
|
||||
MassQuote517 &putLocation(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 5)
|
||||
@@ -1574,6 +1581,11 @@ public:
|
||||
|
||||
std::string getReservedAsJsonEscapedString()
|
||||
{
|
||||
if (m_actingVersion < 5)
|
||||
{
|
||||
return std::string("");
|
||||
}
|
||||
|
||||
std::ostringstream oss;
|
||||
std::string s = getReservedAsString();
|
||||
|
||||
@@ -1636,7 +1648,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
MassQuote517 &putReserved(const std::string& str)
|
||||
MassQuote517 &putReserved(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 30)
|
||||
@@ -1654,6 +1666,310 @@ public:
|
||||
}
|
||||
#endif
|
||||
|
||||
SBE_NODISCARD static const char *Reserved1MetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
switch (metaAttribute)
|
||||
{
|
||||
case MetaAttribute::SEMANTIC_TYPE: return "String";
|
||||
case MetaAttribute::PRESENCE: return "optional";
|
||||
default: return "";
|
||||
}
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint16_t reserved1Id() SBE_NOEXCEPT
|
||||
{
|
||||
return 5239;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint64_t reserved1SinceVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
SBE_NODISCARD bool reserved1InActingVersion() SBE_NOEXCEPT
|
||||
{
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic push
|
||||
#pragma clang diagnostic ignored "-Wtautological-compare"
|
||||
#endif
|
||||
return m_actingVersion >= reserved1SinceVersion();
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic pop
|
||||
#endif
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::size_t reserved1EncodingOffset() SBE_NOEXCEPT
|
||||
{
|
||||
return 92;
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR char reserved1NullValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<char>(0);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR char reserved1MinValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<char>(32);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR char reserved1MaxValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<char>(126);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::size_t reserved1EncodingLength() SBE_NOEXCEPT
|
||||
{
|
||||
return 30;
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint64_t reserved1Length() SBE_NOEXCEPT
|
||||
{
|
||||
return 30;
|
||||
}
|
||||
|
||||
SBE_NODISCARD const char *reserved1() const SBE_NOEXCEPT
|
||||
{
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
return m_buffer + m_offset + 92;
|
||||
}
|
||||
|
||||
SBE_NODISCARD char *reserved1() SBE_NOEXCEPT
|
||||
{
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
return m_buffer + m_offset + 92;
|
||||
}
|
||||
|
||||
SBE_NODISCARD char reserved1(const std::uint64_t index) const
|
||||
{
|
||||
if (index >= 30)
|
||||
{
|
||||
throw std::runtime_error("index out of range for reserved1 [E104]");
|
||||
}
|
||||
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return static_cast<char>(0);
|
||||
}
|
||||
|
||||
char val;
|
||||
std::memcpy(&val, m_buffer + m_offset + 92 + (index * 1), sizeof(char));
|
||||
return (val);
|
||||
}
|
||||
|
||||
MassQuote517 &reserved1(const std::uint64_t index, const char value)
|
||||
{
|
||||
if (index >= 30)
|
||||
{
|
||||
throw std::runtime_error("index out of range for reserved1 [E105]");
|
||||
}
|
||||
|
||||
char val = (value);
|
||||
std::memcpy(m_buffer + m_offset + 92 + (index * 1), &val, sizeof(char));
|
||||
return *this;
|
||||
}
|
||||
|
||||
std::uint64_t getReserved1(char *const dst, const std::uint64_t length) const
|
||||
{
|
||||
if (length > 30)
|
||||
{
|
||||
throw std::runtime_error("length too large for getReserved1 [E106]");
|
||||
}
|
||||
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
std::memcpy(dst, m_buffer + m_offset + 92, sizeof(char) * static_cast<std::size_t>(length));
|
||||
return length;
|
||||
}
|
||||
|
||||
MassQuote517 &putReserved1(const char *const src) SBE_NOEXCEPT
|
||||
{
|
||||
std::memcpy(m_buffer + m_offset + 92, src, sizeof(char) * 30);
|
||||
return *this;
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::string getReserved1AsString() const
|
||||
{
|
||||
const char *buffer = m_buffer + m_offset + 92;
|
||||
std::size_t length = 0;
|
||||
|
||||
for (; length < 30 && *(buffer + length) != '\0'; ++length);
|
||||
std::string result(buffer, length);
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
std::string getReserved1AsJsonEscapedString()
|
||||
{
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return std::string("");
|
||||
}
|
||||
|
||||
std::ostringstream oss;
|
||||
std::string s = getReserved1AsString();
|
||||
|
||||
for (const auto c : s)
|
||||
{
|
||||
switch (c)
|
||||
{
|
||||
case '"': oss << "\\\""; break;
|
||||
case '\\': oss << "\\\\"; break;
|
||||
case '\b': oss << "\\b"; break;
|
||||
case '\f': oss << "\\f"; break;
|
||||
case '\n': oss << "\\n"; break;
|
||||
case '\r': oss << "\\r"; break;
|
||||
case '\t': oss << "\\t"; break;
|
||||
|
||||
default:
|
||||
if ('\x00' <= c && c <= '\x1f')
|
||||
{
|
||||
oss << "\\u" << std::hex << std::setw(4)
|
||||
<< std::setfill('0') << (int)(c);
|
||||
}
|
||||
else
|
||||
{
|
||||
oss << c;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return oss.str();
|
||||
}
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
SBE_NODISCARD std::string_view getReserved1AsStringView() const SBE_NOEXCEPT
|
||||
{
|
||||
const char *buffer = m_buffer + m_offset + 92;
|
||||
std::size_t length = 0;
|
||||
|
||||
for (; length < 30 && *(buffer + length) != '\0'; ++length);
|
||||
std::string_view result(buffer, length);
|
||||
|
||||
return result;
|
||||
}
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
MassQuote517 &putReserved1(const std::string_view str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 30)
|
||||
{
|
||||
throw std::runtime_error("string too large for putReserved1 [E106]");
|
||||
}
|
||||
|
||||
std::memcpy(m_buffer + m_offset + 92, str.data(), srcLength);
|
||||
for (std::size_t start = srcLength; start < 30; ++start)
|
||||
{
|
||||
m_buffer[m_offset + 92 + start] = 0;
|
||||
}
|
||||
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
MassQuote517 &putReserved1(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 30)
|
||||
{
|
||||
throw std::runtime_error("string too large for putReserved1 [E106]");
|
||||
}
|
||||
|
||||
std::memcpy(m_buffer + m_offset + 92, str.c_str(), srcLength);
|
||||
for (std::size_t start = srcLength; start < 30; ++start)
|
||||
{
|
||||
m_buffer[m_offset + 92 + start] = 0;
|
||||
}
|
||||
|
||||
return *this;
|
||||
}
|
||||
#endif
|
||||
|
||||
SBE_NODISCARD static const char *QuoteEntryOpenMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
switch (metaAttribute)
|
||||
{
|
||||
case MetaAttribute::SEMANTIC_TYPE: return "int";
|
||||
case MetaAttribute::PRESENCE: return "required";
|
||||
default: return "";
|
||||
}
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint16_t quoteEntryOpenId() SBE_NOEXCEPT
|
||||
{
|
||||
return 9182;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint64_t quoteEntryOpenSinceVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
SBE_NODISCARD bool quoteEntryOpenInActingVersion() SBE_NOEXCEPT
|
||||
{
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic push
|
||||
#pragma clang diagnostic ignored "-Wtautological-compare"
|
||||
#endif
|
||||
return m_actingVersion >= quoteEntryOpenSinceVersion();
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic pop
|
||||
#endif
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::size_t quoteEntryOpenEncodingOffset() SBE_NOEXCEPT
|
||||
{
|
||||
return 122;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::size_t quoteEntryOpenEncodingLength() SBE_NOEXCEPT
|
||||
{
|
||||
return 1;
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::uint8_t quoteEntryOpenRaw() const SBE_NOEXCEPT
|
||||
{
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return static_cast<std::uint8_t>(255);
|
||||
}
|
||||
|
||||
std::uint8_t val;
|
||||
std::memcpy(&val, m_buffer + m_offset + 122, sizeof(std::uint8_t));
|
||||
return (val);
|
||||
}
|
||||
|
||||
SBE_NODISCARD BooleanNULL::Value quoteEntryOpen() const
|
||||
{
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return BooleanNULL::NULL_VALUE;
|
||||
}
|
||||
|
||||
std::uint8_t val;
|
||||
std::memcpy(&val, m_buffer + m_offset + 122, sizeof(std::uint8_t));
|
||||
return BooleanNULL::get((val));
|
||||
}
|
||||
|
||||
MassQuote517 "eEntryOpen(const BooleanNULL::Value value) SBE_NOEXCEPT
|
||||
{
|
||||
std::uint8_t val = (value);
|
||||
std::memcpy(m_buffer + m_offset + 122, &val, sizeof(std::uint8_t));
|
||||
return *this;
|
||||
}
|
||||
|
||||
class NoQuoteEntries
|
||||
{
|
||||
private:
|
||||
@@ -1780,7 +2096,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
|
||||
inline std::uint64_t resetCountToIndex() SBE_NOEXCEPT
|
||||
inline std::uint64_t resetCountToIndex()
|
||||
{
|
||||
m_count = m_index;
|
||||
GroupSize dimensions(m_buffer, m_initialPosition, m_bufferLength, m_actingVersion);
|
||||
@@ -1788,8 +2104,7 @@ public:
|
||||
return m_count;
|
||||
}
|
||||
|
||||
#if __cplusplus < 201103L
|
||||
template<class Func> inline void forEach(Func& func)
|
||||
template<class Func> inline void forEach(Func &&func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
@@ -1798,17 +2113,6 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
#else
|
||||
template<class Func> inline void forEach(Func&& func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
next();
|
||||
func(*this);
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
SBE_NODISCARD static const char *BidPxMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
@@ -2331,8 +2635,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, NoQuoteEntries writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, NoQuoteEntries writer)
|
||||
{
|
||||
builder << '{';
|
||||
builder << R"("BidPx": )";
|
||||
@@ -2434,11 +2738,16 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, MassQuote517 _writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, MassQuote517 _writer)
|
||||
{
|
||||
MassQuote517 writer(_writer.m_buffer, _writer.m_offset,
|
||||
_writer.m_bufferLength, _writer.sbeBlockLength(), _writer.m_actingVersion);
|
||||
MassQuote517 writer(
|
||||
_writer.m_buffer,
|
||||
_writer.m_offset,
|
||||
_writer.m_bufferLength,
|
||||
_writer.m_actingBlockLength,
|
||||
_writer.m_actingVersion);
|
||||
|
||||
builder << '{';
|
||||
builder << R"("Name": "MassQuote517", )";
|
||||
builder << R"("sbeTemplateId": )";
|
||||
@@ -2499,19 +2808,29 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
builder << '"' <<
|
||||
writer.getReservedAsJsonEscapedString().c_str() << '"';
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("Reserved1": )";
|
||||
builder << '"' <<
|
||||
writer.getReserved1AsJsonEscapedString().c_str() << '"';
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("QuoteEntryOpen": )";
|
||||
builder << '"' << writer.quoteEntryOpen() << '"';
|
||||
|
||||
builder << ", ";
|
||||
{
|
||||
bool atLeastOne = false;
|
||||
builder << R"("NoQuoteEntries": [)";
|
||||
writer.noQuoteEntries().forEach([&](NoQuoteEntries& noQuoteEntries)
|
||||
{
|
||||
if (atLeastOne)
|
||||
writer.noQuoteEntries().forEach(
|
||||
[&](NoQuoteEntries &noQuoteEntries)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noQuoteEntries;
|
||||
});
|
||||
if (atLeastOne)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noQuoteEntries;
|
||||
});
|
||||
builder << ']';
|
||||
}
|
||||
|
||||
@@ -2522,10 +2841,11 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
|
||||
void skip()
|
||||
{
|
||||
noQuoteEntries().forEach([](NoQuoteEntries e)
|
||||
auto &noQuoteEntriesGroup { noQuoteEntries() };
|
||||
while (noQuoteEntriesGroup.hasNext())
|
||||
{
|
||||
e.skip();
|
||||
});
|
||||
noQuoteEntriesGroup.next().skip();
|
||||
}
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR bool isConstLength() SBE_NOEXCEPT
|
||||
|
||||
@@ -70,11 +70,11 @@
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (__builtin_expect(exp, c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
@@ -156,6 +156,7 @@ private:
|
||||
std::uint64_t m_bufferLength = 0;
|
||||
std::uint64_t m_offset = 0;
|
||||
std::uint64_t m_position = 0;
|
||||
std::uint64_t m_actingBlockLength = 0;
|
||||
std::uint64_t m_actingVersion = 0;
|
||||
|
||||
inline std::uint64_t *sbePositionPtr() SBE_NOEXCEPT
|
||||
@@ -164,10 +165,10 @@ private:
|
||||
}
|
||||
|
||||
public:
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(350);
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(351);
|
||||
static const std::uint16_t SBE_TEMPLATE_ID = static_cast<std::uint16_t>(545);
|
||||
static const std::uint16_t SBE_SCHEMA_ID = static_cast<std::uint16_t>(8);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(7);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(8);
|
||||
|
||||
enum MetaAttribute
|
||||
{
|
||||
@@ -200,6 +201,7 @@ public:
|
||||
m_bufferLength(bufferLength),
|
||||
m_offset(offset),
|
||||
m_position(sbeCheckPosition(offset + actingBlockLength)),
|
||||
m_actingBlockLength(actingBlockLength),
|
||||
m_actingVersion(actingVersion)
|
||||
{
|
||||
}
|
||||
@@ -220,7 +222,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeBlockLength() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(350);
|
||||
return static_cast<std::uint16_t>(351);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint64_t sbeBlockAndHeaderLength() SBE_NOEXCEPT
|
||||
@@ -240,7 +242,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeSchemaVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(7);
|
||||
return static_cast<std::uint16_t>(8);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR const char *sbeSemanticType() SBE_NOEXCEPT
|
||||
@@ -286,6 +288,11 @@ public:
|
||||
return *this = MassQuoteAck545(buffer, offset, bufferLength, actingBlockLength, actingVersion);
|
||||
}
|
||||
|
||||
MassQuoteAck545 &sbeRewind()
|
||||
{
|
||||
return wrapForDecode(m_buffer, m_offset, m_actingBlockLength, m_actingVersion, m_bufferLength);
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::uint64_t sbePosition() const SBE_NOEXCEPT
|
||||
{
|
||||
return m_position;
|
||||
@@ -668,7 +675,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
MassQuoteAck545 &putText(const std::string& str)
|
||||
MassQuoteAck545 &putText(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 256)
|
||||
@@ -874,7 +881,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
MassQuoteAck545 &putSenderID(const std::string& str)
|
||||
MassQuoteAck545 &putSenderID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -1364,7 +1371,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
MassQuoteAck545 &putLocation(const std::string& str)
|
||||
MassQuoteAck545 &putLocation(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 5)
|
||||
@@ -2264,6 +2271,79 @@ public:
|
||||
return *this;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static const char *QuoteEntryOpenMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
switch (metaAttribute)
|
||||
{
|
||||
case MetaAttribute::SEMANTIC_TYPE: return "int";
|
||||
case MetaAttribute::PRESENCE: return "required";
|
||||
default: return "";
|
||||
}
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint16_t quoteEntryOpenId() SBE_NOEXCEPT
|
||||
{
|
||||
return 9182;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint64_t quoteEntryOpenSinceVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
SBE_NODISCARD bool quoteEntryOpenInActingVersion() SBE_NOEXCEPT
|
||||
{
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic push
|
||||
#pragma clang diagnostic ignored "-Wtautological-compare"
|
||||
#endif
|
||||
return m_actingVersion >= quoteEntryOpenSinceVersion();
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic pop
|
||||
#endif
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::size_t quoteEntryOpenEncodingOffset() SBE_NOEXCEPT
|
||||
{
|
||||
return 350;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::size_t quoteEntryOpenEncodingLength() SBE_NOEXCEPT
|
||||
{
|
||||
return 1;
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::uint8_t quoteEntryOpenRaw() const SBE_NOEXCEPT
|
||||
{
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return static_cast<std::uint8_t>(255);
|
||||
}
|
||||
|
||||
std::uint8_t val;
|
||||
std::memcpy(&val, m_buffer + m_offset + 350, sizeof(std::uint8_t));
|
||||
return (val);
|
||||
}
|
||||
|
||||
SBE_NODISCARD BooleanNULL::Value quoteEntryOpen() const
|
||||
{
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return BooleanNULL::NULL_VALUE;
|
||||
}
|
||||
|
||||
std::uint8_t val;
|
||||
std::memcpy(&val, m_buffer + m_offset + 350, sizeof(std::uint8_t));
|
||||
return BooleanNULL::get((val));
|
||||
}
|
||||
|
||||
MassQuoteAck545 "eEntryOpen(const BooleanNULL::Value value) SBE_NOEXCEPT
|
||||
{
|
||||
std::uint8_t val = (value);
|
||||
std::memcpy(m_buffer + m_offset + 350, &val, sizeof(std::uint8_t));
|
||||
return *this;
|
||||
}
|
||||
|
||||
class NoQuoteEntries
|
||||
{
|
||||
private:
|
||||
@@ -2390,7 +2470,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
|
||||
inline std::uint64_t resetCountToIndex() SBE_NOEXCEPT
|
||||
inline std::uint64_t resetCountToIndex()
|
||||
{
|
||||
m_count = m_index;
|
||||
GroupSize dimensions(m_buffer, m_initialPosition, m_bufferLength, m_actingVersion);
|
||||
@@ -2398,8 +2478,7 @@ public:
|
||||
return m_count;
|
||||
}
|
||||
|
||||
#if __cplusplus < 201103L
|
||||
template<class Func> inline void forEach(Func& func)
|
||||
template<class Func> inline void forEach(Func &&func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
@@ -2408,17 +2487,6 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
#else
|
||||
template<class Func> inline void forEach(Func&& func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
next();
|
||||
func(*this);
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
SBE_NODISCARD static const char *QuoteEntryIDMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
@@ -2705,8 +2773,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, NoQuoteEntries writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, NoQuoteEntries writer)
|
||||
{
|
||||
builder << '{';
|
||||
builder << R"("QuoteEntryID": )";
|
||||
@@ -2792,11 +2860,16 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, MassQuoteAck545 _writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, MassQuoteAck545 _writer)
|
||||
{
|
||||
MassQuoteAck545 writer(_writer.m_buffer, _writer.m_offset,
|
||||
_writer.m_bufferLength, _writer.sbeBlockLength(), _writer.m_actingVersion);
|
||||
MassQuoteAck545 writer(
|
||||
_writer.m_buffer,
|
||||
_writer.m_offset,
|
||||
_writer.m_bufferLength,
|
||||
_writer.m_actingBlockLength,
|
||||
_writer.m_actingVersion);
|
||||
|
||||
builder << '{';
|
||||
builder << R"("Name": "MassQuoteAck545", )";
|
||||
builder << R"("sbeTemplateId": )";
|
||||
@@ -2893,19 +2966,24 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
builder << R"("DelayToTime": )";
|
||||
builder << +writer.delayToTime();
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("QuoteEntryOpen": )";
|
||||
builder << '"' << writer.quoteEntryOpen() << '"';
|
||||
|
||||
builder << ", ";
|
||||
{
|
||||
bool atLeastOne = false;
|
||||
builder << R"("NoQuoteEntries": [)";
|
||||
writer.noQuoteEntries().forEach([&](NoQuoteEntries& noQuoteEntries)
|
||||
{
|
||||
if (atLeastOne)
|
||||
writer.noQuoteEntries().forEach(
|
||||
[&](NoQuoteEntries &noQuoteEntries)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noQuoteEntries;
|
||||
});
|
||||
if (atLeastOne)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noQuoteEntries;
|
||||
});
|
||||
builder << ']';
|
||||
}
|
||||
|
||||
@@ -2916,10 +2994,11 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
|
||||
void skip()
|
||||
{
|
||||
noQuoteEntries().forEach([](NoQuoteEntries e)
|
||||
auto &noQuoteEntriesGroup { noQuoteEntries() };
|
||||
while (noQuoteEntriesGroup.hasNext())
|
||||
{
|
||||
e.skip();
|
||||
});
|
||||
noQuoteEntriesGroup.next().skip();
|
||||
}
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR bool isConstLength() SBE_NOEXCEPT
|
||||
|
||||
@@ -2,80 +2,17 @@
|
||||
#ifndef _ILINKBINARY_MASSSTATUSORDTYP_H_
|
||||
#define _ILINKBINARY_MASSSTATUSORDTYP_H_
|
||||
|
||||
#if defined(SBE_HAVE_CMATH)
|
||||
/* cmath needed for std::numeric_limits<double>::quiet_NaN() */
|
||||
# include <cmath>
|
||||
# define SBE_FLOAT_NAN std::numeric_limits<float>::quiet_NaN()
|
||||
# define SBE_DOUBLE_NAN std::numeric_limits<double>::quiet_NaN()
|
||||
#else
|
||||
/* math.h needed for NAN */
|
||||
# include <math.h>
|
||||
# define SBE_FLOAT_NAN NAN
|
||||
# define SBE_DOUBLE_NAN NAN
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201103L
|
||||
# define SBE_CONSTEXPR constexpr
|
||||
# define SBE_NOEXCEPT noexcept
|
||||
#else
|
||||
# define SBE_CONSTEXPR
|
||||
# define SBE_NOEXCEPT
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
# include <string_view>
|
||||
# define SBE_NODISCARD [[nodiscard]]
|
||||
#else
|
||||
# define SBE_NODISCARD
|
||||
#endif
|
||||
|
||||
#if !defined(__STDC_LIMIT_MACROS)
|
||||
# define __STDC_LIMIT_MACROS 1
|
||||
#endif
|
||||
|
||||
#include <cstdint>
|
||||
#include <cstring>
|
||||
#include <iomanip>
|
||||
#include <limits>
|
||||
#include <ostream>
|
||||
#include <stdexcept>
|
||||
#include <sstream>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <tuple>
|
||||
|
||||
#if defined(WIN32) || defined(_WIN32)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) _byteswap_ushort(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) _byteswap_ulong(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) _byteswap_uint64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) (v)
|
||||
#else
|
||||
# error "Byte Ordering of platform not determined. Set __BYTE_ORDER__ manually before including this file."
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
#define SBE_NULLVALUE_INT16 (std::numeric_limits<std::int16_t>::min)()
|
||||
@@ -86,7 +23,6 @@
|
||||
#define SBE_NULLVALUE_UINT32 (std::numeric_limits<std::uint32_t>::max)()
|
||||
#define SBE_NULLVALUE_UINT64 (std::numeric_limits<std::uint64_t>::max)()
|
||||
|
||||
|
||||
namespace iLinkBinary {
|
||||
|
||||
class MassStatusOrdTyp
|
||||
@@ -124,8 +60,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& os, MassStatusOrdTyp::Value m)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &os, MassStatusOrdTyp::Value m)
|
||||
{
|
||||
return os << MassStatusOrdTyp::c_str(m);
|
||||
}
|
||||
|
||||
@@ -2,80 +2,17 @@
|
||||
#ifndef _ILINKBINARY_MASSSTATUSREQTYP_H_
|
||||
#define _ILINKBINARY_MASSSTATUSREQTYP_H_
|
||||
|
||||
#if defined(SBE_HAVE_CMATH)
|
||||
/* cmath needed for std::numeric_limits<double>::quiet_NaN() */
|
||||
# include <cmath>
|
||||
# define SBE_FLOAT_NAN std::numeric_limits<float>::quiet_NaN()
|
||||
# define SBE_DOUBLE_NAN std::numeric_limits<double>::quiet_NaN()
|
||||
#else
|
||||
/* math.h needed for NAN */
|
||||
# include <math.h>
|
||||
# define SBE_FLOAT_NAN NAN
|
||||
# define SBE_DOUBLE_NAN NAN
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201103L
|
||||
# define SBE_CONSTEXPR constexpr
|
||||
# define SBE_NOEXCEPT noexcept
|
||||
#else
|
||||
# define SBE_CONSTEXPR
|
||||
# define SBE_NOEXCEPT
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
# include <string_view>
|
||||
# define SBE_NODISCARD [[nodiscard]]
|
||||
#else
|
||||
# define SBE_NODISCARD
|
||||
#endif
|
||||
|
||||
#if !defined(__STDC_LIMIT_MACROS)
|
||||
# define __STDC_LIMIT_MACROS 1
|
||||
#endif
|
||||
|
||||
#include <cstdint>
|
||||
#include <cstring>
|
||||
#include <iomanip>
|
||||
#include <limits>
|
||||
#include <ostream>
|
||||
#include <stdexcept>
|
||||
#include <sstream>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <tuple>
|
||||
|
||||
#if defined(WIN32) || defined(_WIN32)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) _byteswap_ushort(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) _byteswap_ulong(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) _byteswap_uint64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) (v)
|
||||
#else
|
||||
# error "Byte Ordering of platform not determined. Set __BYTE_ORDER__ manually before including this file."
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
#define SBE_NULLVALUE_INT16 (std::numeric_limits<std::int16_t>::min)()
|
||||
@@ -86,7 +23,6 @@
|
||||
#define SBE_NULLVALUE_UINT32 (std::numeric_limits<std::uint32_t>::max)()
|
||||
#define SBE_NULLVALUE_UINT64 (std::numeric_limits<std::uint64_t>::max)()
|
||||
|
||||
|
||||
namespace iLinkBinary {
|
||||
|
||||
class MassStatusReqTyp
|
||||
@@ -96,6 +32,7 @@ public:
|
||||
{
|
||||
Instrument = static_cast<std::uint8_t>(1),
|
||||
InstrumentGroup = static_cast<std::uint8_t>(3),
|
||||
AllOrders = static_cast<std::uint8_t>(7),
|
||||
MarketSegment = static_cast<std::uint8_t>(100),
|
||||
NULL_VALUE = static_cast<std::uint8_t>(255)
|
||||
};
|
||||
@@ -106,6 +43,7 @@ public:
|
||||
{
|
||||
case static_cast<std::uint8_t>(1): return Instrument;
|
||||
case static_cast<std::uint8_t>(3): return InstrumentGroup;
|
||||
case static_cast<std::uint8_t>(7): return AllOrders;
|
||||
case static_cast<std::uint8_t>(100): return MarketSegment;
|
||||
case static_cast<std::uint8_t>(255): return NULL_VALUE;
|
||||
}
|
||||
@@ -119,6 +57,7 @@ public:
|
||||
{
|
||||
case Instrument: return "Instrument";
|
||||
case InstrumentGroup: return "InstrumentGroup";
|
||||
case AllOrders: return "AllOrders";
|
||||
case MarketSegment: return "MarketSegment";
|
||||
case NULL_VALUE: return "NULL_VALUE";
|
||||
}
|
||||
@@ -127,8 +66,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& os, MassStatusReqTyp::Value m)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &os, MassStatusReqTyp::Value m)
|
||||
{
|
||||
return os << MassStatusReqTyp::c_str(m);
|
||||
}
|
||||
|
||||
@@ -2,80 +2,17 @@
|
||||
#ifndef _ILINKBINARY_MASSSTATUSTIF_H_
|
||||
#define _ILINKBINARY_MASSSTATUSTIF_H_
|
||||
|
||||
#if defined(SBE_HAVE_CMATH)
|
||||
/* cmath needed for std::numeric_limits<double>::quiet_NaN() */
|
||||
# include <cmath>
|
||||
# define SBE_FLOAT_NAN std::numeric_limits<float>::quiet_NaN()
|
||||
# define SBE_DOUBLE_NAN std::numeric_limits<double>::quiet_NaN()
|
||||
#else
|
||||
/* math.h needed for NAN */
|
||||
# include <math.h>
|
||||
# define SBE_FLOAT_NAN NAN
|
||||
# define SBE_DOUBLE_NAN NAN
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201103L
|
||||
# define SBE_CONSTEXPR constexpr
|
||||
# define SBE_NOEXCEPT noexcept
|
||||
#else
|
||||
# define SBE_CONSTEXPR
|
||||
# define SBE_NOEXCEPT
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
# include <string_view>
|
||||
# define SBE_NODISCARD [[nodiscard]]
|
||||
#else
|
||||
# define SBE_NODISCARD
|
||||
#endif
|
||||
|
||||
#if !defined(__STDC_LIMIT_MACROS)
|
||||
# define __STDC_LIMIT_MACROS 1
|
||||
#endif
|
||||
|
||||
#include <cstdint>
|
||||
#include <cstring>
|
||||
#include <iomanip>
|
||||
#include <limits>
|
||||
#include <ostream>
|
||||
#include <stdexcept>
|
||||
#include <sstream>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <tuple>
|
||||
|
||||
#if defined(WIN32) || defined(_WIN32)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) _byteswap_ushort(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) _byteswap_ulong(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) _byteswap_uint64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) (v)
|
||||
#else
|
||||
# error "Byte Ordering of platform not determined. Set __BYTE_ORDER__ manually before including this file."
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
#define SBE_NULLVALUE_INT16 (std::numeric_limits<std::int16_t>::min)()
|
||||
@@ -86,7 +23,6 @@
|
||||
#define SBE_NULLVALUE_UINT32 (std::numeric_limits<std::uint32_t>::max)()
|
||||
#define SBE_NULLVALUE_UINT64 (std::numeric_limits<std::uint64_t>::max)()
|
||||
|
||||
|
||||
namespace iLinkBinary {
|
||||
|
||||
class MassStatusTIF
|
||||
@@ -130,8 +66,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& os, MassStatusTIF::Value m)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &os, MassStatusTIF::Value m)
|
||||
{
|
||||
return os << MassStatusTIF::c_str(m);
|
||||
}
|
||||
|
||||
@@ -70,11 +70,11 @@
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (__builtin_expect(exp, c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
@@ -194,7 +194,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeSchemaVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(7);
|
||||
return static_cast<std::uint16_t>(8);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static const char *yearMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
@@ -478,8 +478,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, MaturityMonthYear writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, MaturityMonthYear writer)
|
||||
{
|
||||
builder << '{';
|
||||
builder << R"("year": )";
|
||||
|
||||
@@ -70,11 +70,11 @@
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (__builtin_expect(exp, c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
@@ -194,7 +194,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeSchemaVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(7);
|
||||
return static_cast<std::uint16_t>(8);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static const char *blockLengthMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
@@ -478,8 +478,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, MessageHeader writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, MessageHeader writer)
|
||||
{
|
||||
builder << '{';
|
||||
builder << R"("blockLength": )";
|
||||
|
||||
@@ -70,11 +70,11 @@
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (__builtin_expect(exp, c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
@@ -156,6 +156,7 @@ private:
|
||||
std::uint64_t m_bufferLength = 0;
|
||||
std::uint64_t m_offset = 0;
|
||||
std::uint64_t m_position = 0;
|
||||
std::uint64_t m_actingBlockLength = 0;
|
||||
std::uint64_t m_actingVersion = 0;
|
||||
|
||||
inline std::uint64_t *sbePositionPtr() SBE_NOEXCEPT
|
||||
@@ -167,7 +168,7 @@ public:
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(76);
|
||||
static const std::uint16_t SBE_TEMPLATE_ID = static_cast<std::uint16_t>(500);
|
||||
static const std::uint16_t SBE_SCHEMA_ID = static_cast<std::uint16_t>(8);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(7);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(8);
|
||||
|
||||
enum MetaAttribute
|
||||
{
|
||||
@@ -200,6 +201,7 @@ public:
|
||||
m_bufferLength(bufferLength),
|
||||
m_offset(offset),
|
||||
m_position(sbeCheckPosition(offset + actingBlockLength)),
|
||||
m_actingBlockLength(actingBlockLength),
|
||||
m_actingVersion(actingVersion)
|
||||
{
|
||||
}
|
||||
@@ -240,7 +242,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeSchemaVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(7);
|
||||
return static_cast<std::uint16_t>(8);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR const char *sbeSemanticType() SBE_NOEXCEPT
|
||||
@@ -286,6 +288,11 @@ public:
|
||||
return *this = Negotiate500(buffer, offset, bufferLength, actingBlockLength, actingVersion);
|
||||
}
|
||||
|
||||
Negotiate500 &sbeRewind()
|
||||
{
|
||||
return wrapForDecode(m_buffer, m_offset, m_actingBlockLength, m_actingVersion, m_bufferLength);
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::uint64_t sbePosition() const SBE_NOEXCEPT
|
||||
{
|
||||
return m_position;
|
||||
@@ -776,7 +783,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
Negotiate500 &putHMACSignature(const std::string& str)
|
||||
Negotiate500 &putHMACSignature(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 32)
|
||||
@@ -982,7 +989,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
Negotiate500 &putAccessKeyID(const std::string& str)
|
||||
Negotiate500 &putAccessKeyID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -1345,7 +1352,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
Negotiate500 &putSession(const std::string& str)
|
||||
Negotiate500 &putSession(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 3)
|
||||
@@ -1551,7 +1558,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
Negotiate500 &putFirm(const std::string& str)
|
||||
Negotiate500 &putFirm(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 5)
|
||||
@@ -1732,7 +1739,7 @@ public:
|
||||
}
|
||||
#endif
|
||||
|
||||
Negotiate500 &putCredentials(const std::string& str)
|
||||
Negotiate500 &putCredentials(const std::string &str)
|
||||
{
|
||||
if (str.length() > 65534)
|
||||
{
|
||||
@@ -1753,11 +1760,16 @@ public:
|
||||
#endif
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, Negotiate500 _writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, Negotiate500 _writer)
|
||||
{
|
||||
Negotiate500 writer(_writer.m_buffer, _writer.m_offset,
|
||||
_writer.m_bufferLength, _writer.sbeBlockLength(), _writer.m_actingVersion);
|
||||
Negotiate500 writer(
|
||||
_writer.m_buffer,
|
||||
_writer.m_offset,
|
||||
_writer.m_bufferLength,
|
||||
_writer.m_actingBlockLength,
|
||||
_writer.m_actingVersion);
|
||||
|
||||
builder << '{';
|
||||
builder << R"("Name": "Negotiate500", )";
|
||||
builder << R"("sbeTemplateId": )";
|
||||
|
||||
@@ -70,11 +70,11 @@
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (__builtin_expect(exp, c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
@@ -156,6 +156,7 @@ private:
|
||||
std::uint64_t m_bufferLength = 0;
|
||||
std::uint64_t m_offset = 0;
|
||||
std::uint64_t m_position = 0;
|
||||
std::uint64_t m_actingBlockLength = 0;
|
||||
std::uint64_t m_actingVersion = 0;
|
||||
|
||||
inline std::uint64_t *sbePositionPtr() SBE_NOEXCEPT
|
||||
@@ -167,7 +168,7 @@ public:
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(68);
|
||||
static const std::uint16_t SBE_TEMPLATE_ID = static_cast<std::uint16_t>(502);
|
||||
static const std::uint16_t SBE_SCHEMA_ID = static_cast<std::uint16_t>(8);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(7);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(8);
|
||||
|
||||
enum MetaAttribute
|
||||
{
|
||||
@@ -200,6 +201,7 @@ public:
|
||||
m_bufferLength(bufferLength),
|
||||
m_offset(offset),
|
||||
m_position(sbeCheckPosition(offset + actingBlockLength)),
|
||||
m_actingBlockLength(actingBlockLength),
|
||||
m_actingVersion(actingVersion)
|
||||
{
|
||||
}
|
||||
@@ -240,7 +242,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeSchemaVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(7);
|
||||
return static_cast<std::uint16_t>(8);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR const char *sbeSemanticType() SBE_NOEXCEPT
|
||||
@@ -286,6 +288,11 @@ public:
|
||||
return *this = NegotiationReject502(buffer, offset, bufferLength, actingBlockLength, actingVersion);
|
||||
}
|
||||
|
||||
NegotiationReject502 &sbeRewind()
|
||||
{
|
||||
return wrapForDecode(m_buffer, m_offset, m_actingBlockLength, m_actingVersion, m_bufferLength);
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::uint64_t sbePosition() const SBE_NOEXCEPT
|
||||
{
|
||||
return m_position;
|
||||
@@ -526,7 +533,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
NegotiationReject502 &putReason(const std::string& str)
|
||||
NegotiationReject502 &putReason(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 48)
|
||||
@@ -884,11 +891,16 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, NegotiationReject502 _writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, NegotiationReject502 _writer)
|
||||
{
|
||||
NegotiationReject502 writer(_writer.m_buffer, _writer.m_offset,
|
||||
_writer.m_bufferLength, _writer.sbeBlockLength(), _writer.m_actingVersion);
|
||||
NegotiationReject502 writer(
|
||||
_writer.m_buffer,
|
||||
_writer.m_offset,
|
||||
_writer.m_bufferLength,
|
||||
_writer.m_actingBlockLength,
|
||||
_writer.m_actingVersion);
|
||||
|
||||
builder << '{';
|
||||
builder << R"("Name": "NegotiationReject502", )";
|
||||
builder << R"("sbeTemplateId": )";
|
||||
|
||||
@@ -70,11 +70,11 @@
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (__builtin_expect(exp, c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
@@ -156,6 +156,7 @@ private:
|
||||
std::uint64_t m_bufferLength = 0;
|
||||
std::uint64_t m_offset = 0;
|
||||
std::uint64_t m_position = 0;
|
||||
std::uint64_t m_actingBlockLength = 0;
|
||||
std::uint64_t m_actingVersion = 0;
|
||||
|
||||
inline std::uint64_t *sbePositionPtr() SBE_NOEXCEPT
|
||||
@@ -167,7 +168,7 @@ public:
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(32);
|
||||
static const std::uint16_t SBE_TEMPLATE_ID = static_cast<std::uint16_t>(501);
|
||||
static const std::uint16_t SBE_SCHEMA_ID = static_cast<std::uint16_t>(8);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(7);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(8);
|
||||
|
||||
enum MetaAttribute
|
||||
{
|
||||
@@ -200,6 +201,7 @@ public:
|
||||
m_bufferLength(bufferLength),
|
||||
m_offset(offset),
|
||||
m_position(sbeCheckPosition(offset + actingBlockLength)),
|
||||
m_actingBlockLength(actingBlockLength),
|
||||
m_actingVersion(actingVersion)
|
||||
{
|
||||
}
|
||||
@@ -240,7 +242,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeSchemaVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(7);
|
||||
return static_cast<std::uint16_t>(8);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR const char *sbeSemanticType() SBE_NOEXCEPT
|
||||
@@ -286,6 +288,11 @@ public:
|
||||
return *this = NegotiationResponse501(buffer, offset, bufferLength, actingBlockLength, actingVersion);
|
||||
}
|
||||
|
||||
NegotiationResponse501 &sbeRewind()
|
||||
{
|
||||
return wrapForDecode(m_buffer, m_offset, m_actingBlockLength, m_actingVersion, m_bufferLength);
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::uint64_t sbePosition() const SBE_NOEXCEPT
|
||||
{
|
||||
return m_position;
|
||||
@@ -1107,7 +1114,7 @@ public:
|
||||
}
|
||||
#endif
|
||||
|
||||
NegotiationResponse501 &putCredentials(const std::string& str)
|
||||
NegotiationResponse501 &putCredentials(const std::string &str)
|
||||
{
|
||||
if (str.length() > 65534)
|
||||
{
|
||||
@@ -1128,11 +1135,16 @@ public:
|
||||
#endif
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, NegotiationResponse501 _writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, NegotiationResponse501 _writer)
|
||||
{
|
||||
NegotiationResponse501 writer(_writer.m_buffer, _writer.m_offset,
|
||||
_writer.m_bufferLength, _writer.sbeBlockLength(), _writer.m_actingVersion);
|
||||
NegotiationResponse501 writer(
|
||||
_writer.m_buffer,
|
||||
_writer.m_offset,
|
||||
_writer.m_bufferLength,
|
||||
_writer.m_actingBlockLength,
|
||||
_writer.m_actingVersion);
|
||||
|
||||
builder << '{';
|
||||
builder << R"("Name": "NegotiationResponse501", )";
|
||||
builder << R"("sbeTemplateId": )";
|
||||
|
||||
@@ -70,11 +70,11 @@
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (__builtin_expect(exp, c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
@@ -156,6 +156,7 @@ private:
|
||||
std::uint64_t m_bufferLength = 0;
|
||||
std::uint64_t m_offset = 0;
|
||||
std::uint64_t m_position = 0;
|
||||
std::uint64_t m_actingBlockLength = 0;
|
||||
std::uint64_t m_actingVersion = 0;
|
||||
|
||||
inline std::uint64_t *sbePositionPtr() SBE_NOEXCEPT
|
||||
@@ -167,7 +168,7 @@ public:
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(74);
|
||||
static const std::uint16_t SBE_TEMPLATE_ID = static_cast<std::uint16_t>(544);
|
||||
static const std::uint16_t SBE_SCHEMA_ID = static_cast<std::uint16_t>(8);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(7);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(8);
|
||||
|
||||
enum MetaAttribute
|
||||
{
|
||||
@@ -200,6 +201,7 @@ public:
|
||||
m_bufferLength(bufferLength),
|
||||
m_offset(offset),
|
||||
m_position(sbeCheckPosition(offset + actingBlockLength)),
|
||||
m_actingBlockLength(actingBlockLength),
|
||||
m_actingVersion(actingVersion)
|
||||
{
|
||||
}
|
||||
@@ -240,7 +242,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeSchemaVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(7);
|
||||
return static_cast<std::uint16_t>(8);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR const char *sbeSemanticType() SBE_NOEXCEPT
|
||||
@@ -286,6 +288,11 @@ public:
|
||||
return *this = NewOrderCross544(buffer, offset, bufferLength, actingBlockLength, actingVersion);
|
||||
}
|
||||
|
||||
NewOrderCross544 &sbeRewind()
|
||||
{
|
||||
return wrapForDecode(m_buffer, m_offset, m_actingBlockLength, m_actingVersion, m_bufferLength);
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::uint64_t sbePosition() const SBE_NOEXCEPT
|
||||
{
|
||||
return m_position;
|
||||
@@ -802,7 +809,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
NewOrderCross544 &putSenderID(const std::string& str)
|
||||
NewOrderCross544 &putSenderID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -1572,7 +1579,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
NewOrderCross544 &putLocation(const std::string& str)
|
||||
NewOrderCross544 &putLocation(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 5)
|
||||
@@ -1787,7 +1794,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
|
||||
inline std::uint64_t resetCountToIndex() SBE_NOEXCEPT
|
||||
inline std::uint64_t resetCountToIndex()
|
||||
{
|
||||
m_count = m_index;
|
||||
GroupSize dimensions(m_buffer, m_initialPosition, m_bufferLength, m_actingVersion);
|
||||
@@ -1795,8 +1802,7 @@ public:
|
||||
return m_count;
|
||||
}
|
||||
|
||||
#if __cplusplus < 201103L
|
||||
template<class Func> inline void forEach(Func& func)
|
||||
template<class Func> inline void forEach(Func &&func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
@@ -1805,17 +1811,6 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
#else
|
||||
template<class Func> inline void forEach(Func&& func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
next();
|
||||
func(*this);
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
SBE_NODISCARD static const char *ClOrdIDMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
@@ -2005,7 +2000,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
NoSides &putClOrdID(const std::string& str)
|
||||
NoSides &putClOrdID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -2292,8 +2287,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, NoSides writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, NoSides writer)
|
||||
{
|
||||
builder << '{';
|
||||
builder << R"("ClOrdID": )";
|
||||
@@ -2384,11 +2379,16 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, NewOrderCross544 _writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, NewOrderCross544 _writer)
|
||||
{
|
||||
NewOrderCross544 writer(_writer.m_buffer, _writer.m_offset,
|
||||
_writer.m_bufferLength, _writer.sbeBlockLength(), _writer.m_actingVersion);
|
||||
NewOrderCross544 writer(
|
||||
_writer.m_buffer,
|
||||
_writer.m_offset,
|
||||
_writer.m_bufferLength,
|
||||
_writer.m_actingBlockLength,
|
||||
_writer.m_actingVersion);
|
||||
|
||||
builder << '{';
|
||||
builder << R"("Name": "NewOrderCross544", )";
|
||||
builder << R"("sbeTemplateId": )";
|
||||
@@ -2440,15 +2440,16 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
{
|
||||
bool atLeastOne = false;
|
||||
builder << R"("NoSides": [)";
|
||||
writer.noSides().forEach([&](NoSides& noSides)
|
||||
{
|
||||
if (atLeastOne)
|
||||
writer.noSides().forEach(
|
||||
[&](NoSides &noSides)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noSides;
|
||||
});
|
||||
if (atLeastOne)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noSides;
|
||||
});
|
||||
builder << ']';
|
||||
}
|
||||
|
||||
@@ -2459,10 +2460,11 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
|
||||
void skip()
|
||||
{
|
||||
noSides().forEach([](NoSides e)
|
||||
auto &noSidesGroup { noSides() };
|
||||
while (noSidesGroup.hasNext())
|
||||
{
|
||||
e.skip();
|
||||
});
|
||||
noSidesGroup.next().skip();
|
||||
}
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR bool isConstLength() SBE_NOEXCEPT
|
||||
|
||||
@@ -70,11 +70,11 @@
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (__builtin_expect(exp, c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
@@ -156,6 +156,7 @@ private:
|
||||
std::uint64_t m_bufferLength = 0;
|
||||
std::uint64_t m_offset = 0;
|
||||
std::uint64_t m_position = 0;
|
||||
std::uint64_t m_actingBlockLength = 0;
|
||||
std::uint64_t m_actingVersion = 0;
|
||||
|
||||
inline std::uint64_t *sbePositionPtr() SBE_NOEXCEPT
|
||||
@@ -164,10 +165,10 @@ private:
|
||||
}
|
||||
|
||||
public:
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(124);
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(132);
|
||||
static const std::uint16_t SBE_TEMPLATE_ID = static_cast<std::uint16_t>(514);
|
||||
static const std::uint16_t SBE_SCHEMA_ID = static_cast<std::uint16_t>(8);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(7);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(8);
|
||||
|
||||
enum MetaAttribute
|
||||
{
|
||||
@@ -200,6 +201,7 @@ public:
|
||||
m_bufferLength(bufferLength),
|
||||
m_offset(offset),
|
||||
m_position(sbeCheckPosition(offset + actingBlockLength)),
|
||||
m_actingBlockLength(actingBlockLength),
|
||||
m_actingVersion(actingVersion)
|
||||
{
|
||||
}
|
||||
@@ -220,7 +222,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeBlockLength() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(124);
|
||||
return static_cast<std::uint16_t>(132);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint64_t sbeBlockAndHeaderLength() SBE_NOEXCEPT
|
||||
@@ -240,7 +242,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeSchemaVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(7);
|
||||
return static_cast<std::uint16_t>(8);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR const char *sbeSemanticType() SBE_NOEXCEPT
|
||||
@@ -286,6 +288,11 @@ public:
|
||||
return *this = NewOrderSingle514(buffer, offset, bufferLength, actingBlockLength, actingVersion);
|
||||
}
|
||||
|
||||
NewOrderSingle514 &sbeRewind()
|
||||
{
|
||||
return wrapForDecode(m_buffer, m_offset, m_actingBlockLength, m_actingVersion, m_bufferLength);
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::uint64_t sbePosition() const SBE_NOEXCEPT
|
||||
{
|
||||
return m_position;
|
||||
@@ -849,7 +856,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
NewOrderSingle514 &putSenderID(const std::string& str)
|
||||
NewOrderSingle514 &putSenderID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -1055,7 +1062,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
NewOrderSingle514 &putClOrdID(const std::string& str)
|
||||
NewOrderSingle514 &putClOrdID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -1521,7 +1528,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
NewOrderSingle514 &putLocation(const std::string& str)
|
||||
NewOrderSingle514 &putLocation(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 5)
|
||||
@@ -2292,12 +2299,64 @@ public:
|
||||
return m_discretionPrice;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static const char *ReservationPriceMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
switch (metaAttribute)
|
||||
{
|
||||
case MetaAttribute::SEMANTIC_TYPE: return "Price";
|
||||
case MetaAttribute::PRESENCE: return "required";
|
||||
default: return "";
|
||||
}
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint16_t reservationPriceId() SBE_NOEXCEPT
|
||||
{
|
||||
return 9562;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint64_t reservationPriceSinceVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
SBE_NODISCARD bool reservationPriceInActingVersion() SBE_NOEXCEPT
|
||||
{
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic push
|
||||
#pragma clang diagnostic ignored "-Wtautological-compare"
|
||||
#endif
|
||||
return m_actingVersion >= reservationPriceSinceVersion();
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic pop
|
||||
#endif
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::size_t reservationPriceEncodingOffset() SBE_NOEXCEPT
|
||||
{
|
||||
return 124;
|
||||
}
|
||||
|
||||
private:
|
||||
PRICENULL9 m_reservationPrice;
|
||||
|
||||
public:
|
||||
SBE_NODISCARD PRICENULL9 &reservationPrice()
|
||||
{
|
||||
m_reservationPrice.wrap(m_buffer, m_offset + 124, m_actingVersion, m_bufferLength);
|
||||
return m_reservationPrice;
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, NewOrderSingle514 _writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, NewOrderSingle514 _writer)
|
||||
{
|
||||
NewOrderSingle514 writer(_writer.m_buffer, _writer.m_offset,
|
||||
_writer.m_bufferLength, _writer.sbeBlockLength(), _writer.m_actingVersion);
|
||||
NewOrderSingle514 writer(
|
||||
_writer.m_buffer,
|
||||
_writer.m_offset,
|
||||
_writer.m_bufferLength,
|
||||
_writer.m_actingBlockLength,
|
||||
_writer.m_actingVersion);
|
||||
|
||||
builder << '{';
|
||||
builder << R"("Name": "NewOrderSingle514", )";
|
||||
builder << R"("sbeTemplateId": )";
|
||||
@@ -2400,7 +2459,25 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("DiscretionPrice": )";
|
||||
builder << writer.discretionPrice();
|
||||
if (writer.discretionPriceInActingVersion())
|
||||
{
|
||||
builder << writer.discretionPrice();
|
||||
}
|
||||
else
|
||||
{
|
||||
builder << "{}";
|
||||
}
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("ReservationPrice": )";
|
||||
if (writer.reservationPriceInActingVersion())
|
||||
{
|
||||
builder << writer.reservationPrice();
|
||||
}
|
||||
else
|
||||
{
|
||||
builder << "{}";
|
||||
}
|
||||
|
||||
builder << '}';
|
||||
|
||||
|
||||
@@ -70,11 +70,11 @@
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (__builtin_expect(exp, c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
@@ -156,6 +156,7 @@ private:
|
||||
std::uint64_t m_bufferLength = 0;
|
||||
std::uint64_t m_offset = 0;
|
||||
std::uint64_t m_position = 0;
|
||||
std::uint64_t m_actingBlockLength = 0;
|
||||
std::uint64_t m_actingVersion = 0;
|
||||
|
||||
inline std::uint64_t *sbePositionPtr() SBE_NOEXCEPT
|
||||
@@ -167,7 +168,7 @@ public:
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(17);
|
||||
static const std::uint16_t SBE_TEMPLATE_ID = static_cast<std::uint16_t>(513);
|
||||
static const std::uint16_t SBE_SCHEMA_ID = static_cast<std::uint16_t>(8);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(7);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(8);
|
||||
|
||||
enum MetaAttribute
|
||||
{
|
||||
@@ -200,6 +201,7 @@ public:
|
||||
m_bufferLength(bufferLength),
|
||||
m_offset(offset),
|
||||
m_position(sbeCheckPosition(offset + actingBlockLength)),
|
||||
m_actingBlockLength(actingBlockLength),
|
||||
m_actingVersion(actingVersion)
|
||||
{
|
||||
}
|
||||
@@ -240,7 +242,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeSchemaVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(7);
|
||||
return static_cast<std::uint16_t>(8);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR const char *sbeSemanticType() SBE_NOEXCEPT
|
||||
@@ -286,6 +288,11 @@ public:
|
||||
return *this = NotApplied513(buffer, offset, bufferLength, actingBlockLength, actingVersion);
|
||||
}
|
||||
|
||||
NotApplied513 &sbeRewind()
|
||||
{
|
||||
return wrapForDecode(m_buffer, m_offset, m_actingBlockLength, m_actingVersion, m_bufferLength);
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::uint64_t sbePosition() const SBE_NOEXCEPT
|
||||
{
|
||||
return m_position;
|
||||
@@ -615,11 +622,16 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, NotApplied513 _writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, NotApplied513 _writer)
|
||||
{
|
||||
NotApplied513 writer(_writer.m_buffer, _writer.m_offset,
|
||||
_writer.m_bufferLength, _writer.sbeBlockLength(), _writer.m_actingVersion);
|
||||
NotApplied513 writer(
|
||||
_writer.m_buffer,
|
||||
_writer.m_offset,
|
||||
_writer.m_bufferLength,
|
||||
_writer.m_actingBlockLength,
|
||||
_writer.m_actingVersion);
|
||||
|
||||
builder << '{';
|
||||
builder << R"("Name": "NotApplied513", )";
|
||||
builder << R"("sbeTemplateId": )";
|
||||
|
||||
@@ -2,80 +2,17 @@
|
||||
#ifndef _ILINKBINARY_OFMOVERRIDEREQ_H_
|
||||
#define _ILINKBINARY_OFMOVERRIDEREQ_H_
|
||||
|
||||
#if defined(SBE_HAVE_CMATH)
|
||||
/* cmath needed for std::numeric_limits<double>::quiet_NaN() */
|
||||
# include <cmath>
|
||||
# define SBE_FLOAT_NAN std::numeric_limits<float>::quiet_NaN()
|
||||
# define SBE_DOUBLE_NAN std::numeric_limits<double>::quiet_NaN()
|
||||
#else
|
||||
/* math.h needed for NAN */
|
||||
# include <math.h>
|
||||
# define SBE_FLOAT_NAN NAN
|
||||
# define SBE_DOUBLE_NAN NAN
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201103L
|
||||
# define SBE_CONSTEXPR constexpr
|
||||
# define SBE_NOEXCEPT noexcept
|
||||
#else
|
||||
# define SBE_CONSTEXPR
|
||||
# define SBE_NOEXCEPT
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
# include <string_view>
|
||||
# define SBE_NODISCARD [[nodiscard]]
|
||||
#else
|
||||
# define SBE_NODISCARD
|
||||
#endif
|
||||
|
||||
#if !defined(__STDC_LIMIT_MACROS)
|
||||
# define __STDC_LIMIT_MACROS 1
|
||||
#endif
|
||||
|
||||
#include <cstdint>
|
||||
#include <cstring>
|
||||
#include <iomanip>
|
||||
#include <limits>
|
||||
#include <ostream>
|
||||
#include <stdexcept>
|
||||
#include <sstream>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <tuple>
|
||||
|
||||
#if defined(WIN32) || defined(_WIN32)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) _byteswap_ushort(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) _byteswap_ulong(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) _byteswap_uint64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) (v)
|
||||
#else
|
||||
# error "Byte Ordering of platform not determined. Set __BYTE_ORDER__ manually before including this file."
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
#define SBE_NULLVALUE_INT16 (std::numeric_limits<std::int16_t>::min)()
|
||||
@@ -86,7 +23,6 @@
|
||||
#define SBE_NULLVALUE_UINT32 (std::numeric_limits<std::uint32_t>::max)()
|
||||
#define SBE_NULLVALUE_UINT64 (std::numeric_limits<std::uint64_t>::max)()
|
||||
|
||||
|
||||
namespace iLinkBinary {
|
||||
|
||||
class OFMOverrideReq
|
||||
@@ -124,8 +60,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& os, OFMOverrideReq::Value m)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &os, OFMOverrideReq::Value m)
|
||||
{
|
||||
return os << OFMOverrideReq::c_str(m);
|
||||
}
|
||||
|
||||
@@ -2,80 +2,17 @@
|
||||
#ifndef _ILINKBINARY_ORDSTATUSTRD_H_
|
||||
#define _ILINKBINARY_ORDSTATUSTRD_H_
|
||||
|
||||
#if defined(SBE_HAVE_CMATH)
|
||||
/* cmath needed for std::numeric_limits<double>::quiet_NaN() */
|
||||
# include <cmath>
|
||||
# define SBE_FLOAT_NAN std::numeric_limits<float>::quiet_NaN()
|
||||
# define SBE_DOUBLE_NAN std::numeric_limits<double>::quiet_NaN()
|
||||
#else
|
||||
/* math.h needed for NAN */
|
||||
# include <math.h>
|
||||
# define SBE_FLOAT_NAN NAN
|
||||
# define SBE_DOUBLE_NAN NAN
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201103L
|
||||
# define SBE_CONSTEXPR constexpr
|
||||
# define SBE_NOEXCEPT noexcept
|
||||
#else
|
||||
# define SBE_CONSTEXPR
|
||||
# define SBE_NOEXCEPT
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
# include <string_view>
|
||||
# define SBE_NODISCARD [[nodiscard]]
|
||||
#else
|
||||
# define SBE_NODISCARD
|
||||
#endif
|
||||
|
||||
#if !defined(__STDC_LIMIT_MACROS)
|
||||
# define __STDC_LIMIT_MACROS 1
|
||||
#endif
|
||||
|
||||
#include <cstdint>
|
||||
#include <cstring>
|
||||
#include <iomanip>
|
||||
#include <limits>
|
||||
#include <ostream>
|
||||
#include <stdexcept>
|
||||
#include <sstream>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <tuple>
|
||||
|
||||
#if defined(WIN32) || defined(_WIN32)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) _byteswap_ushort(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) _byteswap_ulong(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) _byteswap_uint64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) (v)
|
||||
#else
|
||||
# error "Byte Ordering of platform not determined. Set __BYTE_ORDER__ manually before including this file."
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
#define SBE_NULLVALUE_INT16 (std::numeric_limits<std::int16_t>::min)()
|
||||
@@ -86,7 +23,6 @@
|
||||
#define SBE_NULLVALUE_UINT32 (std::numeric_limits<std::uint32_t>::max)()
|
||||
#define SBE_NULLVALUE_UINT64 (std::numeric_limits<std::uint64_t>::max)()
|
||||
|
||||
|
||||
namespace iLinkBinary {
|
||||
|
||||
class OrdStatusTrd
|
||||
@@ -124,8 +60,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& os, OrdStatusTrd::Value m)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &os, OrdStatusTrd::Value m)
|
||||
{
|
||||
return os << OrdStatusTrd::c_str(m);
|
||||
}
|
||||
|
||||
@@ -2,80 +2,17 @@
|
||||
#ifndef _ILINKBINARY_ORDSTATUSTRDCXL_H_
|
||||
#define _ILINKBINARY_ORDSTATUSTRDCXL_H_
|
||||
|
||||
#if defined(SBE_HAVE_CMATH)
|
||||
/* cmath needed for std::numeric_limits<double>::quiet_NaN() */
|
||||
# include <cmath>
|
||||
# define SBE_FLOAT_NAN std::numeric_limits<float>::quiet_NaN()
|
||||
# define SBE_DOUBLE_NAN std::numeric_limits<double>::quiet_NaN()
|
||||
#else
|
||||
/* math.h needed for NAN */
|
||||
# include <math.h>
|
||||
# define SBE_FLOAT_NAN NAN
|
||||
# define SBE_DOUBLE_NAN NAN
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201103L
|
||||
# define SBE_CONSTEXPR constexpr
|
||||
# define SBE_NOEXCEPT noexcept
|
||||
#else
|
||||
# define SBE_CONSTEXPR
|
||||
# define SBE_NOEXCEPT
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
# include <string_view>
|
||||
# define SBE_NODISCARD [[nodiscard]]
|
||||
#else
|
||||
# define SBE_NODISCARD
|
||||
#endif
|
||||
|
||||
#if !defined(__STDC_LIMIT_MACROS)
|
||||
# define __STDC_LIMIT_MACROS 1
|
||||
#endif
|
||||
|
||||
#include <cstdint>
|
||||
#include <cstring>
|
||||
#include <iomanip>
|
||||
#include <limits>
|
||||
#include <ostream>
|
||||
#include <stdexcept>
|
||||
#include <sstream>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <tuple>
|
||||
|
||||
#if defined(WIN32) || defined(_WIN32)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) _byteswap_ushort(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) _byteswap_ulong(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) _byteswap_uint64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) (v)
|
||||
#else
|
||||
# error "Byte Ordering of platform not determined. Set __BYTE_ORDER__ manually before including this file."
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
#define SBE_NULLVALUE_INT16 (std::numeric_limits<std::int16_t>::min)()
|
||||
@@ -86,7 +23,6 @@
|
||||
#define SBE_NULLVALUE_UINT32 (std::numeric_limits<std::uint32_t>::max)()
|
||||
#define SBE_NULLVALUE_UINT64 (std::numeric_limits<std::uint64_t>::max)()
|
||||
|
||||
|
||||
namespace iLinkBinary {
|
||||
|
||||
class OrdStatusTrdCxl
|
||||
@@ -124,8 +60,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& os, OrdStatusTrdCxl::Value m)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &os, OrdStatusTrdCxl::Value m)
|
||||
{
|
||||
return os << OrdStatusTrdCxl::c_str(m);
|
||||
}
|
||||
|
||||
@@ -70,11 +70,11 @@
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (__builtin_expect(exp, c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
@@ -156,6 +156,7 @@ private:
|
||||
std::uint64_t m_bufferLength = 0;
|
||||
std::uint64_t m_offset = 0;
|
||||
std::uint64_t m_position = 0;
|
||||
std::uint64_t m_actingBlockLength = 0;
|
||||
std::uint64_t m_actingVersion = 0;
|
||||
|
||||
inline std::uint64_t *sbePositionPtr() SBE_NOEXCEPT
|
||||
@@ -167,7 +168,7 @@ public:
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(409);
|
||||
static const std::uint16_t SBE_TEMPLATE_ID = static_cast<std::uint16_t>(535);
|
||||
static const std::uint16_t SBE_SCHEMA_ID = static_cast<std::uint16_t>(8);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(7);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(8);
|
||||
|
||||
enum MetaAttribute
|
||||
{
|
||||
@@ -200,6 +201,7 @@ public:
|
||||
m_bufferLength(bufferLength),
|
||||
m_offset(offset),
|
||||
m_position(sbeCheckPosition(offset + actingBlockLength)),
|
||||
m_actingBlockLength(actingBlockLength),
|
||||
m_actingVersion(actingVersion)
|
||||
{
|
||||
}
|
||||
@@ -240,7 +242,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeSchemaVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(7);
|
||||
return static_cast<std::uint16_t>(8);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR const char *sbeSemanticType() SBE_NOEXCEPT
|
||||
@@ -286,6 +288,11 @@ public:
|
||||
return *this = OrderCancelReject535(buffer, offset, bufferLength, actingBlockLength, actingVersion);
|
||||
}
|
||||
|
||||
OrderCancelReject535 &sbeRewind()
|
||||
{
|
||||
return wrapForDecode(m_buffer, m_offset, m_actingBlockLength, m_actingVersion, m_bufferLength);
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::uint64_t sbePosition() const SBE_NOEXCEPT
|
||||
{
|
||||
return m_position;
|
||||
@@ -668,7 +675,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
OrderCancelReject535 &putText(const std::string& str)
|
||||
OrderCancelReject535 &putText(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 256)
|
||||
@@ -874,7 +881,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
OrderCancelReject535 &putExecID(const std::string& str)
|
||||
OrderCancelReject535 &putExecID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 40)
|
||||
@@ -1080,7 +1087,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
OrderCancelReject535 &putSenderID(const std::string& str)
|
||||
OrderCancelReject535 &putSenderID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -1286,7 +1293,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
OrderCancelReject535 &putClOrdID(const std::string& str)
|
||||
OrderCancelReject535 &putClOrdID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -2097,7 +2104,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
OrderCancelReject535 &putLocation(const std::string& str)
|
||||
OrderCancelReject535 &putLocation(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 5)
|
||||
@@ -2586,11 +2593,16 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, OrderCancelReject535 _writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, OrderCancelReject535 _writer)
|
||||
{
|
||||
OrderCancelReject535 writer(_writer.m_buffer, _writer.m_offset,
|
||||
_writer.m_bufferLength, _writer.sbeBlockLength(), _writer.m_actingVersion);
|
||||
OrderCancelReject535 writer(
|
||||
_writer.m_buffer,
|
||||
_writer.m_offset,
|
||||
_writer.m_bufferLength,
|
||||
_writer.m_actingBlockLength,
|
||||
_writer.m_actingVersion);
|
||||
|
||||
builder << '{';
|
||||
builder << R"("Name": "OrderCancelReject535", )";
|
||||
builder << R"("sbeTemplateId": )";
|
||||
|
||||
@@ -70,11 +70,11 @@
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (__builtin_expect(exp, c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
@@ -156,6 +156,7 @@ private:
|
||||
std::uint64_t m_bufferLength = 0;
|
||||
std::uint64_t m_offset = 0;
|
||||
std::uint64_t m_position = 0;
|
||||
std::uint64_t m_actingBlockLength = 0;
|
||||
std::uint64_t m_actingVersion = 0;
|
||||
|
||||
inline std::uint64_t *sbePositionPtr() SBE_NOEXCEPT
|
||||
@@ -167,7 +168,7 @@ public:
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(409);
|
||||
static const std::uint16_t SBE_TEMPLATE_ID = static_cast<std::uint16_t>(536);
|
||||
static const std::uint16_t SBE_SCHEMA_ID = static_cast<std::uint16_t>(8);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(7);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(8);
|
||||
|
||||
enum MetaAttribute
|
||||
{
|
||||
@@ -200,6 +201,7 @@ public:
|
||||
m_bufferLength(bufferLength),
|
||||
m_offset(offset),
|
||||
m_position(sbeCheckPosition(offset + actingBlockLength)),
|
||||
m_actingBlockLength(actingBlockLength),
|
||||
m_actingVersion(actingVersion)
|
||||
{
|
||||
}
|
||||
@@ -240,7 +242,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeSchemaVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(7);
|
||||
return static_cast<std::uint16_t>(8);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR const char *sbeSemanticType() SBE_NOEXCEPT
|
||||
@@ -286,6 +288,11 @@ public:
|
||||
return *this = OrderCancelReplaceReject536(buffer, offset, bufferLength, actingBlockLength, actingVersion);
|
||||
}
|
||||
|
||||
OrderCancelReplaceReject536 &sbeRewind()
|
||||
{
|
||||
return wrapForDecode(m_buffer, m_offset, m_actingBlockLength, m_actingVersion, m_bufferLength);
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::uint64_t sbePosition() const SBE_NOEXCEPT
|
||||
{
|
||||
return m_position;
|
||||
@@ -668,7 +675,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
OrderCancelReplaceReject536 &putText(const std::string& str)
|
||||
OrderCancelReplaceReject536 &putText(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 256)
|
||||
@@ -874,7 +881,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
OrderCancelReplaceReject536 &putExecID(const std::string& str)
|
||||
OrderCancelReplaceReject536 &putExecID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 40)
|
||||
@@ -1080,7 +1087,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
OrderCancelReplaceReject536 &putSenderID(const std::string& str)
|
||||
OrderCancelReplaceReject536 &putSenderID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -1286,7 +1293,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
OrderCancelReplaceReject536 &putClOrdID(const std::string& str)
|
||||
OrderCancelReplaceReject536 &putClOrdID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -1847,7 +1854,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
OrderCancelReplaceReject536 &putLocation(const std::string& str)
|
||||
OrderCancelReplaceReject536 &putLocation(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 5)
|
||||
@@ -2586,11 +2593,16 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, OrderCancelReplaceReject536 _writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, OrderCancelReplaceReject536 _writer)
|
||||
{
|
||||
OrderCancelReplaceReject536 writer(_writer.m_buffer, _writer.m_offset,
|
||||
_writer.m_bufferLength, _writer.sbeBlockLength(), _writer.m_actingVersion);
|
||||
OrderCancelReplaceReject536 writer(
|
||||
_writer.m_buffer,
|
||||
_writer.m_offset,
|
||||
_writer.m_bufferLength,
|
||||
_writer.m_actingBlockLength,
|
||||
_writer.m_actingVersion);
|
||||
|
||||
builder << '{';
|
||||
builder << R"("Name": "OrderCancelReplaceReject536", )";
|
||||
builder << R"("sbeTemplateId": )";
|
||||
|
||||
@@ -70,11 +70,11 @@
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (__builtin_expect(exp, c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
@@ -156,6 +156,7 @@ private:
|
||||
std::uint64_t m_bufferLength = 0;
|
||||
std::uint64_t m_offset = 0;
|
||||
std::uint64_t m_position = 0;
|
||||
std::uint64_t m_actingBlockLength = 0;
|
||||
std::uint64_t m_actingVersion = 0;
|
||||
|
||||
inline std::uint64_t *sbePositionPtr() SBE_NOEXCEPT
|
||||
@@ -167,7 +168,7 @@ public:
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(133);
|
||||
static const std::uint16_t SBE_TEMPLATE_ID = static_cast<std::uint16_t>(515);
|
||||
static const std::uint16_t SBE_SCHEMA_ID = static_cast<std::uint16_t>(8);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(7);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(8);
|
||||
|
||||
enum MetaAttribute
|
||||
{
|
||||
@@ -200,6 +201,7 @@ public:
|
||||
m_bufferLength(bufferLength),
|
||||
m_offset(offset),
|
||||
m_position(sbeCheckPosition(offset + actingBlockLength)),
|
||||
m_actingBlockLength(actingBlockLength),
|
||||
m_actingVersion(actingVersion)
|
||||
{
|
||||
}
|
||||
@@ -240,7 +242,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeSchemaVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(7);
|
||||
return static_cast<std::uint16_t>(8);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR const char *sbeSemanticType() SBE_NOEXCEPT
|
||||
@@ -286,6 +288,11 @@ public:
|
||||
return *this = OrderCancelReplaceRequest515(buffer, offset, bufferLength, actingBlockLength, actingVersion);
|
||||
}
|
||||
|
||||
OrderCancelReplaceRequest515 &sbeRewind()
|
||||
{
|
||||
return wrapForDecode(m_buffer, m_offset, m_actingBlockLength, m_actingVersion, m_bufferLength);
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::uint64_t sbePosition() const SBE_NOEXCEPT
|
||||
{
|
||||
return m_position;
|
||||
@@ -849,7 +856,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
OrderCancelReplaceRequest515 &putSenderID(const std::string& str)
|
||||
OrderCancelReplaceRequest515 &putSenderID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -1055,7 +1062,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
OrderCancelReplaceRequest515 &putClOrdID(const std::string& str)
|
||||
OrderCancelReplaceRequest515 &putClOrdID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -1592,7 +1599,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
OrderCancelReplaceRequest515 &putLocation(const std::string& str)
|
||||
OrderCancelReplaceRequest515 &putLocation(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 5)
|
||||
@@ -2427,11 +2434,16 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, OrderCancelReplaceRequest515 _writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, OrderCancelReplaceRequest515 _writer)
|
||||
{
|
||||
OrderCancelReplaceRequest515 writer(_writer.m_buffer, _writer.m_offset,
|
||||
_writer.m_bufferLength, _writer.sbeBlockLength(), _writer.m_actingVersion);
|
||||
OrderCancelReplaceRequest515 writer(
|
||||
_writer.m_buffer,
|
||||
_writer.m_offset,
|
||||
_writer.m_bufferLength,
|
||||
_writer.m_actingBlockLength,
|
||||
_writer.m_actingVersion);
|
||||
|
||||
builder << '{';
|
||||
builder << R"("Name": "OrderCancelReplaceRequest515", )";
|
||||
builder << R"("sbeTemplateId": )";
|
||||
@@ -2542,7 +2554,14 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("DiscretionPrice": )";
|
||||
builder << writer.discretionPrice();
|
||||
if (writer.discretionPriceInActingVersion())
|
||||
{
|
||||
builder << writer.discretionPrice();
|
||||
}
|
||||
else
|
||||
{
|
||||
builder << "{}";
|
||||
}
|
||||
|
||||
builder << '}';
|
||||
|
||||
|
||||
@@ -70,11 +70,11 @@
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (__builtin_expect(exp, c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
@@ -156,6 +156,7 @@ private:
|
||||
std::uint64_t m_bufferLength = 0;
|
||||
std::uint64_t m_offset = 0;
|
||||
std::uint64_t m_position = 0;
|
||||
std::uint64_t m_actingBlockLength = 0;
|
||||
std::uint64_t m_actingVersion = 0;
|
||||
|
||||
inline std::uint64_t *sbePositionPtr() SBE_NOEXCEPT
|
||||
@@ -164,10 +165,10 @@ private:
|
||||
}
|
||||
|
||||
public:
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(88);
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(96);
|
||||
static const std::uint16_t SBE_TEMPLATE_ID = static_cast<std::uint16_t>(516);
|
||||
static const std::uint16_t SBE_SCHEMA_ID = static_cast<std::uint16_t>(8);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(7);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(8);
|
||||
|
||||
enum MetaAttribute
|
||||
{
|
||||
@@ -200,6 +201,7 @@ public:
|
||||
m_bufferLength(bufferLength),
|
||||
m_offset(offset),
|
||||
m_position(sbeCheckPosition(offset + actingBlockLength)),
|
||||
m_actingBlockLength(actingBlockLength),
|
||||
m_actingVersion(actingVersion)
|
||||
{
|
||||
}
|
||||
@@ -220,7 +222,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeBlockLength() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(88);
|
||||
return static_cast<std::uint16_t>(96);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint64_t sbeBlockAndHeaderLength() SBE_NOEXCEPT
|
||||
@@ -240,7 +242,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeSchemaVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(7);
|
||||
return static_cast<std::uint16_t>(8);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR const char *sbeSemanticType() SBE_NOEXCEPT
|
||||
@@ -286,6 +288,11 @@ public:
|
||||
return *this = OrderCancelRequest516(buffer, offset, bufferLength, actingBlockLength, actingVersion);
|
||||
}
|
||||
|
||||
OrderCancelRequest516 &sbeRewind()
|
||||
{
|
||||
return wrapForDecode(m_buffer, m_offset, m_actingBlockLength, m_actingVersion, m_bufferLength);
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::uint64_t sbePosition() const SBE_NOEXCEPT
|
||||
{
|
||||
return m_position;
|
||||
@@ -802,7 +809,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
OrderCancelRequest516 &putSenderID(const std::string& str)
|
||||
OrderCancelRequest516 &putSenderID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -1008,7 +1015,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
OrderCancelRequest516 &putClOrdID(const std::string& str)
|
||||
OrderCancelRequest516 &putClOrdID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -1356,7 +1363,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
OrderCancelRequest516 &putLocation(const std::string& str)
|
||||
OrderCancelRequest516 &putLocation(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 5)
|
||||
@@ -1571,12 +1578,248 @@ public:
|
||||
return *this;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static const char *OrigOrderUserMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
switch (metaAttribute)
|
||||
{
|
||||
case MetaAttribute::SEMANTIC_TYPE: return "String";
|
||||
case MetaAttribute::PRESENCE: return "optional";
|
||||
default: return "";
|
||||
}
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint16_t origOrderUserId() SBE_NOEXCEPT
|
||||
{
|
||||
return 9937;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint64_t origOrderUserSinceVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
SBE_NODISCARD bool origOrderUserInActingVersion() SBE_NOEXCEPT
|
||||
{
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic push
|
||||
#pragma clang diagnostic ignored "-Wtautological-compare"
|
||||
#endif
|
||||
return m_actingVersion >= origOrderUserSinceVersion();
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic pop
|
||||
#endif
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::size_t origOrderUserEncodingOffset() SBE_NOEXCEPT
|
||||
{
|
||||
return 88;
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR char origOrderUserNullValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<char>(0);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR char origOrderUserMinValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<char>(32);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR char origOrderUserMaxValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<char>(126);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::size_t origOrderUserEncodingLength() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint64_t origOrderUserLength() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
SBE_NODISCARD const char *origOrderUser() const SBE_NOEXCEPT
|
||||
{
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
return m_buffer + m_offset + 88;
|
||||
}
|
||||
|
||||
SBE_NODISCARD char *origOrderUser() SBE_NOEXCEPT
|
||||
{
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
return m_buffer + m_offset + 88;
|
||||
}
|
||||
|
||||
SBE_NODISCARD char origOrderUser(const std::uint64_t index) const
|
||||
{
|
||||
if (index >= 8)
|
||||
{
|
||||
throw std::runtime_error("index out of range for origOrderUser [E104]");
|
||||
}
|
||||
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return static_cast<char>(0);
|
||||
}
|
||||
|
||||
char val;
|
||||
std::memcpy(&val, m_buffer + m_offset + 88 + (index * 1), sizeof(char));
|
||||
return (val);
|
||||
}
|
||||
|
||||
OrderCancelRequest516 &origOrderUser(const std::uint64_t index, const char value)
|
||||
{
|
||||
if (index >= 8)
|
||||
{
|
||||
throw std::runtime_error("index out of range for origOrderUser [E105]");
|
||||
}
|
||||
|
||||
char val = (value);
|
||||
std::memcpy(m_buffer + m_offset + 88 + (index * 1), &val, sizeof(char));
|
||||
return *this;
|
||||
}
|
||||
|
||||
std::uint64_t getOrigOrderUser(char *const dst, const std::uint64_t length) const
|
||||
{
|
||||
if (length > 8)
|
||||
{
|
||||
throw std::runtime_error("length too large for getOrigOrderUser [E106]");
|
||||
}
|
||||
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
std::memcpy(dst, m_buffer + m_offset + 88, sizeof(char) * static_cast<std::size_t>(length));
|
||||
return length;
|
||||
}
|
||||
|
||||
OrderCancelRequest516 &putOrigOrderUser(const char *const src) SBE_NOEXCEPT
|
||||
{
|
||||
std::memcpy(m_buffer + m_offset + 88, src, sizeof(char) * 8);
|
||||
return *this;
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::string getOrigOrderUserAsString() const
|
||||
{
|
||||
const char *buffer = m_buffer + m_offset + 88;
|
||||
std::size_t length = 0;
|
||||
|
||||
for (; length < 8 && *(buffer + length) != '\0'; ++length);
|
||||
std::string result(buffer, length);
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
std::string getOrigOrderUserAsJsonEscapedString()
|
||||
{
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return std::string("");
|
||||
}
|
||||
|
||||
std::ostringstream oss;
|
||||
std::string s = getOrigOrderUserAsString();
|
||||
|
||||
for (const auto c : s)
|
||||
{
|
||||
switch (c)
|
||||
{
|
||||
case '"': oss << "\\\""; break;
|
||||
case '\\': oss << "\\\\"; break;
|
||||
case '\b': oss << "\\b"; break;
|
||||
case '\f': oss << "\\f"; break;
|
||||
case '\n': oss << "\\n"; break;
|
||||
case '\r': oss << "\\r"; break;
|
||||
case '\t': oss << "\\t"; break;
|
||||
|
||||
default:
|
||||
if ('\x00' <= c && c <= '\x1f')
|
||||
{
|
||||
oss << "\\u" << std::hex << std::setw(4)
|
||||
<< std::setfill('0') << (int)(c);
|
||||
}
|
||||
else
|
||||
{
|
||||
oss << c;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return oss.str();
|
||||
}
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
SBE_NODISCARD std::string_view getOrigOrderUserAsStringView() const SBE_NOEXCEPT
|
||||
{
|
||||
const char *buffer = m_buffer + m_offset + 88;
|
||||
std::size_t length = 0;
|
||||
|
||||
for (; length < 8 && *(buffer + length) != '\0'; ++length);
|
||||
std::string_view result(buffer, length);
|
||||
|
||||
return result;
|
||||
}
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
OrderCancelRequest516 &putOrigOrderUser(const std::string_view str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 8)
|
||||
{
|
||||
throw std::runtime_error("string too large for putOrigOrderUser [E106]");
|
||||
}
|
||||
|
||||
std::memcpy(m_buffer + m_offset + 88, str.data(), srcLength);
|
||||
for (std::size_t start = srcLength; start < 8; ++start)
|
||||
{
|
||||
m_buffer[m_offset + 88 + start] = 0;
|
||||
}
|
||||
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
OrderCancelRequest516 &putOrigOrderUser(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 8)
|
||||
{
|
||||
throw std::runtime_error("string too large for putOrigOrderUser [E106]");
|
||||
}
|
||||
|
||||
std::memcpy(m_buffer + m_offset + 88, str.c_str(), srcLength);
|
||||
for (std::size_t start = srcLength; start < 8; ++start)
|
||||
{
|
||||
m_buffer[m_offset + 88 + start] = 0;
|
||||
}
|
||||
|
||||
return *this;
|
||||
}
|
||||
#endif
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, OrderCancelRequest516 _writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, OrderCancelRequest516 _writer)
|
||||
{
|
||||
OrderCancelRequest516 writer(_writer.m_buffer, _writer.m_offset,
|
||||
_writer.m_bufferLength, _writer.sbeBlockLength(), _writer.m_actingVersion);
|
||||
OrderCancelRequest516 writer(
|
||||
_writer.m_buffer,
|
||||
_writer.m_offset,
|
||||
_writer.m_bufferLength,
|
||||
_writer.m_actingBlockLength,
|
||||
_writer.m_actingVersion);
|
||||
|
||||
builder << '{';
|
||||
builder << R"("Name": "OrderCancelRequest516", )";
|
||||
builder << R"("sbeTemplateId": )";
|
||||
@@ -1633,6 +1876,11 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
builder << R"("LiquidityFlag": )";
|
||||
builder << '"' << writer.liquidityFlag() << '"';
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("OrigOrderUser": )";
|
||||
builder << '"' <<
|
||||
writer.getOrigOrderUserAsJsonEscapedString().c_str() << '"';
|
||||
|
||||
builder << '}';
|
||||
|
||||
return builder;
|
||||
|
||||
@@ -2,80 +2,17 @@
|
||||
#ifndef _ILINKBINARY_ORDEREVENTTYPE_H_
|
||||
#define _ILINKBINARY_ORDEREVENTTYPE_H_
|
||||
|
||||
#if defined(SBE_HAVE_CMATH)
|
||||
/* cmath needed for std::numeric_limits<double>::quiet_NaN() */
|
||||
# include <cmath>
|
||||
# define SBE_FLOAT_NAN std::numeric_limits<float>::quiet_NaN()
|
||||
# define SBE_DOUBLE_NAN std::numeric_limits<double>::quiet_NaN()
|
||||
#else
|
||||
/* math.h needed for NAN */
|
||||
# include <math.h>
|
||||
# define SBE_FLOAT_NAN NAN
|
||||
# define SBE_DOUBLE_NAN NAN
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201103L
|
||||
# define SBE_CONSTEXPR constexpr
|
||||
# define SBE_NOEXCEPT noexcept
|
||||
#else
|
||||
# define SBE_CONSTEXPR
|
||||
# define SBE_NOEXCEPT
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
# include <string_view>
|
||||
# define SBE_NODISCARD [[nodiscard]]
|
||||
#else
|
||||
# define SBE_NODISCARD
|
||||
#endif
|
||||
|
||||
#if !defined(__STDC_LIMIT_MACROS)
|
||||
# define __STDC_LIMIT_MACROS 1
|
||||
#endif
|
||||
|
||||
#include <cstdint>
|
||||
#include <cstring>
|
||||
#include <iomanip>
|
||||
#include <limits>
|
||||
#include <ostream>
|
||||
#include <stdexcept>
|
||||
#include <sstream>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <tuple>
|
||||
|
||||
#if defined(WIN32) || defined(_WIN32)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) _byteswap_ushort(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) _byteswap_ulong(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) _byteswap_uint64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) (v)
|
||||
#else
|
||||
# error "Byte Ordering of platform not determined. Set __BYTE_ORDER__ manually before including this file."
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
#define SBE_NULLVALUE_INT16 (std::numeric_limits<std::int16_t>::min)()
|
||||
@@ -86,7 +23,6 @@
|
||||
#define SBE_NULLVALUE_UINT32 (std::numeric_limits<std::uint32_t>::max)()
|
||||
#define SBE_NULLVALUE_UINT64 (std::numeric_limits<std::uint64_t>::max)()
|
||||
|
||||
|
||||
namespace iLinkBinary {
|
||||
|
||||
class OrderEventType
|
||||
@@ -124,8 +60,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& os, OrderEventType::Value m)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &os, OrderEventType::Value m)
|
||||
{
|
||||
return os << OrderEventType::c_str(m);
|
||||
}
|
||||
|
||||
@@ -70,11 +70,11 @@
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (__builtin_expect(exp, c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
@@ -156,6 +156,7 @@ private:
|
||||
std::uint64_t m_bufferLength = 0;
|
||||
std::uint64_t m_offset = 0;
|
||||
std::uint64_t m_position = 0;
|
||||
std::uint64_t m_actingBlockLength = 0;
|
||||
std::uint64_t m_actingVersion = 0;
|
||||
|
||||
inline std::uint64_t *sbePositionPtr() SBE_NOEXCEPT
|
||||
@@ -164,10 +165,10 @@ private:
|
||||
}
|
||||
|
||||
public:
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(114);
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(130);
|
||||
static const std::uint16_t SBE_TEMPLATE_ID = static_cast<std::uint16_t>(562);
|
||||
static const std::uint16_t SBE_SCHEMA_ID = static_cast<std::uint16_t>(8);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(7);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(8);
|
||||
|
||||
enum MetaAttribute
|
||||
{
|
||||
@@ -200,6 +201,7 @@ public:
|
||||
m_bufferLength(bufferLength),
|
||||
m_offset(offset),
|
||||
m_position(sbeCheckPosition(offset + actingBlockLength)),
|
||||
m_actingBlockLength(actingBlockLength),
|
||||
m_actingVersion(actingVersion)
|
||||
{
|
||||
}
|
||||
@@ -220,7 +222,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeBlockLength() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(114);
|
||||
return static_cast<std::uint16_t>(130);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint64_t sbeBlockAndHeaderLength() SBE_NOEXCEPT
|
||||
@@ -240,7 +242,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeSchemaVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(7);
|
||||
return static_cast<std::uint16_t>(8);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR const char *sbeSemanticType() SBE_NOEXCEPT
|
||||
@@ -286,6 +288,11 @@ public:
|
||||
return *this = OrderMassActionReport562(buffer, offset, bufferLength, actingBlockLength, actingVersion);
|
||||
}
|
||||
|
||||
OrderMassActionReport562 &sbeRewind()
|
||||
{
|
||||
return wrapForDecode(m_buffer, m_offset, m_actingBlockLength, m_actingVersion, m_bufferLength);
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::uint64_t sbePosition() const SBE_NOEXCEPT
|
||||
{
|
||||
return m_position;
|
||||
@@ -668,7 +675,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
OrderMassActionReport562 &putSenderID(const std::string& str)
|
||||
OrderMassActionReport562 &putSenderID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -1354,7 +1361,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
OrderMassActionReport562 &putSecurityGroup(const std::string& str)
|
||||
OrderMassActionReport562 &putSecurityGroup(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 6)
|
||||
@@ -1560,7 +1567,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
OrderMassActionReport562 &putLocation(const std::string& str)
|
||||
OrderMassActionReport562 &putLocation(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 5)
|
||||
@@ -2697,6 +2704,468 @@ public:
|
||||
return *this;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static const char *OrigOrderUserMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
switch (metaAttribute)
|
||||
{
|
||||
case MetaAttribute::SEMANTIC_TYPE: return "String";
|
||||
case MetaAttribute::PRESENCE: return "optional";
|
||||
default: return "";
|
||||
}
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint16_t origOrderUserId() SBE_NOEXCEPT
|
||||
{
|
||||
return 9937;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint64_t origOrderUserSinceVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
SBE_NODISCARD bool origOrderUserInActingVersion() SBE_NOEXCEPT
|
||||
{
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic push
|
||||
#pragma clang diagnostic ignored "-Wtautological-compare"
|
||||
#endif
|
||||
return m_actingVersion >= origOrderUserSinceVersion();
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic pop
|
||||
#endif
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::size_t origOrderUserEncodingOffset() SBE_NOEXCEPT
|
||||
{
|
||||
return 114;
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR char origOrderUserNullValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<char>(0);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR char origOrderUserMinValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<char>(32);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR char origOrderUserMaxValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<char>(126);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::size_t origOrderUserEncodingLength() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint64_t origOrderUserLength() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
SBE_NODISCARD const char *origOrderUser() const SBE_NOEXCEPT
|
||||
{
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
return m_buffer + m_offset + 114;
|
||||
}
|
||||
|
||||
SBE_NODISCARD char *origOrderUser() SBE_NOEXCEPT
|
||||
{
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
return m_buffer + m_offset + 114;
|
||||
}
|
||||
|
||||
SBE_NODISCARD char origOrderUser(const std::uint64_t index) const
|
||||
{
|
||||
if (index >= 8)
|
||||
{
|
||||
throw std::runtime_error("index out of range for origOrderUser [E104]");
|
||||
}
|
||||
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return static_cast<char>(0);
|
||||
}
|
||||
|
||||
char val;
|
||||
std::memcpy(&val, m_buffer + m_offset + 114 + (index * 1), sizeof(char));
|
||||
return (val);
|
||||
}
|
||||
|
||||
OrderMassActionReport562 &origOrderUser(const std::uint64_t index, const char value)
|
||||
{
|
||||
if (index >= 8)
|
||||
{
|
||||
throw std::runtime_error("index out of range for origOrderUser [E105]");
|
||||
}
|
||||
|
||||
char val = (value);
|
||||
std::memcpy(m_buffer + m_offset + 114 + (index * 1), &val, sizeof(char));
|
||||
return *this;
|
||||
}
|
||||
|
||||
std::uint64_t getOrigOrderUser(char *const dst, const std::uint64_t length) const
|
||||
{
|
||||
if (length > 8)
|
||||
{
|
||||
throw std::runtime_error("length too large for getOrigOrderUser [E106]");
|
||||
}
|
||||
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
std::memcpy(dst, m_buffer + m_offset + 114, sizeof(char) * static_cast<std::size_t>(length));
|
||||
return length;
|
||||
}
|
||||
|
||||
OrderMassActionReport562 &putOrigOrderUser(const char *const src) SBE_NOEXCEPT
|
||||
{
|
||||
std::memcpy(m_buffer + m_offset + 114, src, sizeof(char) * 8);
|
||||
return *this;
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::string getOrigOrderUserAsString() const
|
||||
{
|
||||
const char *buffer = m_buffer + m_offset + 114;
|
||||
std::size_t length = 0;
|
||||
|
||||
for (; length < 8 && *(buffer + length) != '\0'; ++length);
|
||||
std::string result(buffer, length);
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
std::string getOrigOrderUserAsJsonEscapedString()
|
||||
{
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return std::string("");
|
||||
}
|
||||
|
||||
std::ostringstream oss;
|
||||
std::string s = getOrigOrderUserAsString();
|
||||
|
||||
for (const auto c : s)
|
||||
{
|
||||
switch (c)
|
||||
{
|
||||
case '"': oss << "\\\""; break;
|
||||
case '\\': oss << "\\\\"; break;
|
||||
case '\b': oss << "\\b"; break;
|
||||
case '\f': oss << "\\f"; break;
|
||||
case '\n': oss << "\\n"; break;
|
||||
case '\r': oss << "\\r"; break;
|
||||
case '\t': oss << "\\t"; break;
|
||||
|
||||
default:
|
||||
if ('\x00' <= c && c <= '\x1f')
|
||||
{
|
||||
oss << "\\u" << std::hex << std::setw(4)
|
||||
<< std::setfill('0') << (int)(c);
|
||||
}
|
||||
else
|
||||
{
|
||||
oss << c;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return oss.str();
|
||||
}
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
SBE_NODISCARD std::string_view getOrigOrderUserAsStringView() const SBE_NOEXCEPT
|
||||
{
|
||||
const char *buffer = m_buffer + m_offset + 114;
|
||||
std::size_t length = 0;
|
||||
|
||||
for (; length < 8 && *(buffer + length) != '\0'; ++length);
|
||||
std::string_view result(buffer, length);
|
||||
|
||||
return result;
|
||||
}
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
OrderMassActionReport562 &putOrigOrderUser(const std::string_view str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 8)
|
||||
{
|
||||
throw std::runtime_error("string too large for putOrigOrderUser [E106]");
|
||||
}
|
||||
|
||||
std::memcpy(m_buffer + m_offset + 114, str.data(), srcLength);
|
||||
for (std::size_t start = srcLength; start < 8; ++start)
|
||||
{
|
||||
m_buffer[m_offset + 114 + start] = 0;
|
||||
}
|
||||
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
OrderMassActionReport562 &putOrigOrderUser(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 8)
|
||||
{
|
||||
throw std::runtime_error("string too large for putOrigOrderUser [E106]");
|
||||
}
|
||||
|
||||
std::memcpy(m_buffer + m_offset + 114, str.c_str(), srcLength);
|
||||
for (std::size_t start = srcLength; start < 8; ++start)
|
||||
{
|
||||
m_buffer[m_offset + 114 + start] = 0;
|
||||
}
|
||||
|
||||
return *this;
|
||||
}
|
||||
#endif
|
||||
|
||||
SBE_NODISCARD static const char *CancelTextMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
switch (metaAttribute)
|
||||
{
|
||||
case MetaAttribute::SEMANTIC_TYPE: return "String";
|
||||
case MetaAttribute::PRESENCE: return "optional";
|
||||
default: return "";
|
||||
}
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint16_t cancelTextId() SBE_NOEXCEPT
|
||||
{
|
||||
return 2807;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint64_t cancelTextSinceVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
SBE_NODISCARD bool cancelTextInActingVersion() SBE_NOEXCEPT
|
||||
{
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic push
|
||||
#pragma clang diagnostic ignored "-Wtautological-compare"
|
||||
#endif
|
||||
return m_actingVersion >= cancelTextSinceVersion();
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic pop
|
||||
#endif
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::size_t cancelTextEncodingOffset() SBE_NOEXCEPT
|
||||
{
|
||||
return 122;
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR char cancelTextNullValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<char>(0);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR char cancelTextMinValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<char>(32);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR char cancelTextMaxValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<char>(126);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::size_t cancelTextEncodingLength() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint64_t cancelTextLength() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
SBE_NODISCARD const char *cancelText() const SBE_NOEXCEPT
|
||||
{
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
return m_buffer + m_offset + 122;
|
||||
}
|
||||
|
||||
SBE_NODISCARD char *cancelText() SBE_NOEXCEPT
|
||||
{
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
return m_buffer + m_offset + 122;
|
||||
}
|
||||
|
||||
SBE_NODISCARD char cancelText(const std::uint64_t index) const
|
||||
{
|
||||
if (index >= 8)
|
||||
{
|
||||
throw std::runtime_error("index out of range for cancelText [E104]");
|
||||
}
|
||||
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return static_cast<char>(0);
|
||||
}
|
||||
|
||||
char val;
|
||||
std::memcpy(&val, m_buffer + m_offset + 122 + (index * 1), sizeof(char));
|
||||
return (val);
|
||||
}
|
||||
|
||||
OrderMassActionReport562 &cancelText(const std::uint64_t index, const char value)
|
||||
{
|
||||
if (index >= 8)
|
||||
{
|
||||
throw std::runtime_error("index out of range for cancelText [E105]");
|
||||
}
|
||||
|
||||
char val = (value);
|
||||
std::memcpy(m_buffer + m_offset + 122 + (index * 1), &val, sizeof(char));
|
||||
return *this;
|
||||
}
|
||||
|
||||
std::uint64_t getCancelText(char *const dst, const std::uint64_t length) const
|
||||
{
|
||||
if (length > 8)
|
||||
{
|
||||
throw std::runtime_error("length too large for getCancelText [E106]");
|
||||
}
|
||||
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
std::memcpy(dst, m_buffer + m_offset + 122, sizeof(char) * static_cast<std::size_t>(length));
|
||||
return length;
|
||||
}
|
||||
|
||||
OrderMassActionReport562 &putCancelText(const char *const src) SBE_NOEXCEPT
|
||||
{
|
||||
std::memcpy(m_buffer + m_offset + 122, src, sizeof(char) * 8);
|
||||
return *this;
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::string getCancelTextAsString() const
|
||||
{
|
||||
const char *buffer = m_buffer + m_offset + 122;
|
||||
std::size_t length = 0;
|
||||
|
||||
for (; length < 8 && *(buffer + length) != '\0'; ++length);
|
||||
std::string result(buffer, length);
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
std::string getCancelTextAsJsonEscapedString()
|
||||
{
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return std::string("");
|
||||
}
|
||||
|
||||
std::ostringstream oss;
|
||||
std::string s = getCancelTextAsString();
|
||||
|
||||
for (const auto c : s)
|
||||
{
|
||||
switch (c)
|
||||
{
|
||||
case '"': oss << "\\\""; break;
|
||||
case '\\': oss << "\\\\"; break;
|
||||
case '\b': oss << "\\b"; break;
|
||||
case '\f': oss << "\\f"; break;
|
||||
case '\n': oss << "\\n"; break;
|
||||
case '\r': oss << "\\r"; break;
|
||||
case '\t': oss << "\\t"; break;
|
||||
|
||||
default:
|
||||
if ('\x00' <= c && c <= '\x1f')
|
||||
{
|
||||
oss << "\\u" << std::hex << std::setw(4)
|
||||
<< std::setfill('0') << (int)(c);
|
||||
}
|
||||
else
|
||||
{
|
||||
oss << c;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return oss.str();
|
||||
}
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
SBE_NODISCARD std::string_view getCancelTextAsStringView() const SBE_NOEXCEPT
|
||||
{
|
||||
const char *buffer = m_buffer + m_offset + 122;
|
||||
std::size_t length = 0;
|
||||
|
||||
for (; length < 8 && *(buffer + length) != '\0'; ++length);
|
||||
std::string_view result(buffer, length);
|
||||
|
||||
return result;
|
||||
}
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
OrderMassActionReport562 &putCancelText(const std::string_view str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 8)
|
||||
{
|
||||
throw std::runtime_error("string too large for putCancelText [E106]");
|
||||
}
|
||||
|
||||
std::memcpy(m_buffer + m_offset + 122, str.data(), srcLength);
|
||||
for (std::size_t start = srcLength; start < 8; ++start)
|
||||
{
|
||||
m_buffer[m_offset + 122 + start] = 0;
|
||||
}
|
||||
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
OrderMassActionReport562 &putCancelText(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 8)
|
||||
{
|
||||
throw std::runtime_error("string too large for putCancelText [E106]");
|
||||
}
|
||||
|
||||
std::memcpy(m_buffer + m_offset + 122, str.c_str(), srcLength);
|
||||
for (std::size_t start = srcLength; start < 8; ++start)
|
||||
{
|
||||
m_buffer[m_offset + 122 + start] = 0;
|
||||
}
|
||||
|
||||
return *this;
|
||||
}
|
||||
#endif
|
||||
|
||||
class NoAffectedOrders
|
||||
{
|
||||
private:
|
||||
@@ -2823,7 +3292,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
|
||||
inline std::uint64_t resetCountToIndex() SBE_NOEXCEPT
|
||||
inline std::uint64_t resetCountToIndex()
|
||||
{
|
||||
m_count = m_index;
|
||||
GroupSize dimensions(m_buffer, m_initialPosition, m_bufferLength, m_actingVersion);
|
||||
@@ -2831,8 +3300,7 @@ public:
|
||||
return m_count;
|
||||
}
|
||||
|
||||
#if __cplusplus < 201103L
|
||||
template<class Func> inline void forEach(Func& func)
|
||||
template<class Func> inline void forEach(Func &&func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
@@ -2841,17 +3309,6 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
#else
|
||||
template<class Func> inline void forEach(Func&& func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
next();
|
||||
func(*this);
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
SBE_NODISCARD static const char *OrigCIOrdIDMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
@@ -3041,7 +3498,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
NoAffectedOrders &putOrigCIOrdID(const std::string& str)
|
||||
NoAffectedOrders &putOrigCIOrdID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -3202,8 +3659,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, NoAffectedOrders writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, NoAffectedOrders writer)
|
||||
{
|
||||
builder << '{';
|
||||
builder << R"("OrigCIOrdID": )";
|
||||
@@ -3286,11 +3743,16 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, OrderMassActionReport562 _writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, OrderMassActionReport562 _writer)
|
||||
{
|
||||
OrderMassActionReport562 writer(_writer.m_buffer, _writer.m_offset,
|
||||
_writer.m_bufferLength, _writer.sbeBlockLength(), _writer.m_actingVersion);
|
||||
OrderMassActionReport562 writer(
|
||||
_writer.m_buffer,
|
||||
_writer.m_offset,
|
||||
_writer.m_bufferLength,
|
||||
_writer.m_actingBlockLength,
|
||||
_writer.m_actingVersion);
|
||||
|
||||
builder << '{';
|
||||
builder << R"("Name": "OrderMassActionReport562", )";
|
||||
builder << R"("sbeTemplateId": )";
|
||||
@@ -3407,19 +3869,30 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
builder << R"("DelayToTime": )";
|
||||
builder << +writer.delayToTime();
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("OrigOrderUser": )";
|
||||
builder << '"' <<
|
||||
writer.getOrigOrderUserAsJsonEscapedString().c_str() << '"';
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("CancelText": )";
|
||||
builder << '"' <<
|
||||
writer.getCancelTextAsJsonEscapedString().c_str() << '"';
|
||||
|
||||
builder << ", ";
|
||||
{
|
||||
bool atLeastOne = false;
|
||||
builder << R"("NoAffectedOrders": [)";
|
||||
writer.noAffectedOrders().forEach([&](NoAffectedOrders& noAffectedOrders)
|
||||
{
|
||||
if (atLeastOne)
|
||||
writer.noAffectedOrders().forEach(
|
||||
[&](NoAffectedOrders &noAffectedOrders)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noAffectedOrders;
|
||||
});
|
||||
if (atLeastOne)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noAffectedOrders;
|
||||
});
|
||||
builder << ']';
|
||||
}
|
||||
|
||||
@@ -3430,10 +3903,11 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
|
||||
void skip()
|
||||
{
|
||||
noAffectedOrders().forEach([](NoAffectedOrders e)
|
||||
auto &noAffectedOrdersGroup { noAffectedOrders() };
|
||||
while (noAffectedOrdersGroup.hasNext())
|
||||
{
|
||||
e.skip();
|
||||
});
|
||||
noAffectedOrdersGroup.next().skip();
|
||||
}
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR bool isConstLength() SBE_NOEXCEPT
|
||||
|
||||
@@ -70,11 +70,11 @@
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (__builtin_expect(exp, c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
@@ -156,6 +156,7 @@ private:
|
||||
std::uint64_t m_bufferLength = 0;
|
||||
std::uint64_t m_offset = 0;
|
||||
std::uint64_t m_position = 0;
|
||||
std::uint64_t m_actingBlockLength = 0;
|
||||
std::uint64_t m_actingVersion = 0;
|
||||
|
||||
inline std::uint64_t *sbePositionPtr() SBE_NOEXCEPT
|
||||
@@ -164,10 +165,10 @@ private:
|
||||
}
|
||||
|
||||
public:
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(71);
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(79);
|
||||
static const std::uint16_t SBE_TEMPLATE_ID = static_cast<std::uint16_t>(529);
|
||||
static const std::uint16_t SBE_SCHEMA_ID = static_cast<std::uint16_t>(8);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(7);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(8);
|
||||
|
||||
enum MetaAttribute
|
||||
{
|
||||
@@ -200,6 +201,7 @@ public:
|
||||
m_bufferLength(bufferLength),
|
||||
m_offset(offset),
|
||||
m_position(sbeCheckPosition(offset + actingBlockLength)),
|
||||
m_actingBlockLength(actingBlockLength),
|
||||
m_actingVersion(actingVersion)
|
||||
{
|
||||
}
|
||||
@@ -220,7 +222,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeBlockLength() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(71);
|
||||
return static_cast<std::uint16_t>(79);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint64_t sbeBlockAndHeaderLength() SBE_NOEXCEPT
|
||||
@@ -240,7 +242,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeSchemaVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(7);
|
||||
return static_cast<std::uint16_t>(8);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR const char *sbeSemanticType() SBE_NOEXCEPT
|
||||
@@ -286,6 +288,11 @@ public:
|
||||
return *this = OrderMassActionRequest529(buffer, offset, bufferLength, actingBlockLength, actingVersion);
|
||||
}
|
||||
|
||||
OrderMassActionRequest529 &sbeRewind()
|
||||
{
|
||||
return wrapForDecode(m_buffer, m_offset, m_actingBlockLength, m_actingVersion, m_bufferLength);
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::uint64_t sbePosition() const SBE_NOEXCEPT
|
||||
{
|
||||
return m_position;
|
||||
@@ -802,7 +809,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
OrderMassActionRequest529 &putSenderID(const std::string& str)
|
||||
OrderMassActionRequest529 &putSenderID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -1204,7 +1211,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
OrderMassActionRequest529 &putSecurityGroup(const std::string& str)
|
||||
OrderMassActionRequest529 &putSecurityGroup(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 6)
|
||||
@@ -1410,7 +1417,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
OrderMassActionRequest529 &putLocation(const std::string& str)
|
||||
OrderMassActionRequest529 &putLocation(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 5)
|
||||
@@ -1948,12 +1955,248 @@ public:
|
||||
return *this;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static const char *OrigOrderUserMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
switch (metaAttribute)
|
||||
{
|
||||
case MetaAttribute::SEMANTIC_TYPE: return "String";
|
||||
case MetaAttribute::PRESENCE: return "optional";
|
||||
default: return "";
|
||||
}
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint16_t origOrderUserId() SBE_NOEXCEPT
|
||||
{
|
||||
return 9937;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint64_t origOrderUserSinceVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
SBE_NODISCARD bool origOrderUserInActingVersion() SBE_NOEXCEPT
|
||||
{
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic push
|
||||
#pragma clang diagnostic ignored "-Wtautological-compare"
|
||||
#endif
|
||||
return m_actingVersion >= origOrderUserSinceVersion();
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic pop
|
||||
#endif
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::size_t origOrderUserEncodingOffset() SBE_NOEXCEPT
|
||||
{
|
||||
return 71;
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR char origOrderUserNullValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<char>(0);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR char origOrderUserMinValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<char>(32);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR char origOrderUserMaxValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<char>(126);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::size_t origOrderUserEncodingLength() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint64_t origOrderUserLength() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
SBE_NODISCARD const char *origOrderUser() const SBE_NOEXCEPT
|
||||
{
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
return m_buffer + m_offset + 71;
|
||||
}
|
||||
|
||||
SBE_NODISCARD char *origOrderUser() SBE_NOEXCEPT
|
||||
{
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
return m_buffer + m_offset + 71;
|
||||
}
|
||||
|
||||
SBE_NODISCARD char origOrderUser(const std::uint64_t index) const
|
||||
{
|
||||
if (index >= 8)
|
||||
{
|
||||
throw std::runtime_error("index out of range for origOrderUser [E104]");
|
||||
}
|
||||
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return static_cast<char>(0);
|
||||
}
|
||||
|
||||
char val;
|
||||
std::memcpy(&val, m_buffer + m_offset + 71 + (index * 1), sizeof(char));
|
||||
return (val);
|
||||
}
|
||||
|
||||
OrderMassActionRequest529 &origOrderUser(const std::uint64_t index, const char value)
|
||||
{
|
||||
if (index >= 8)
|
||||
{
|
||||
throw std::runtime_error("index out of range for origOrderUser [E105]");
|
||||
}
|
||||
|
||||
char val = (value);
|
||||
std::memcpy(m_buffer + m_offset + 71 + (index * 1), &val, sizeof(char));
|
||||
return *this;
|
||||
}
|
||||
|
||||
std::uint64_t getOrigOrderUser(char *const dst, const std::uint64_t length) const
|
||||
{
|
||||
if (length > 8)
|
||||
{
|
||||
throw std::runtime_error("length too large for getOrigOrderUser [E106]");
|
||||
}
|
||||
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
std::memcpy(dst, m_buffer + m_offset + 71, sizeof(char) * static_cast<std::size_t>(length));
|
||||
return length;
|
||||
}
|
||||
|
||||
OrderMassActionRequest529 &putOrigOrderUser(const char *const src) SBE_NOEXCEPT
|
||||
{
|
||||
std::memcpy(m_buffer + m_offset + 71, src, sizeof(char) * 8);
|
||||
return *this;
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::string getOrigOrderUserAsString() const
|
||||
{
|
||||
const char *buffer = m_buffer + m_offset + 71;
|
||||
std::size_t length = 0;
|
||||
|
||||
for (; length < 8 && *(buffer + length) != '\0'; ++length);
|
||||
std::string result(buffer, length);
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
std::string getOrigOrderUserAsJsonEscapedString()
|
||||
{
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return std::string("");
|
||||
}
|
||||
|
||||
std::ostringstream oss;
|
||||
std::string s = getOrigOrderUserAsString();
|
||||
|
||||
for (const auto c : s)
|
||||
{
|
||||
switch (c)
|
||||
{
|
||||
case '"': oss << "\\\""; break;
|
||||
case '\\': oss << "\\\\"; break;
|
||||
case '\b': oss << "\\b"; break;
|
||||
case '\f': oss << "\\f"; break;
|
||||
case '\n': oss << "\\n"; break;
|
||||
case '\r': oss << "\\r"; break;
|
||||
case '\t': oss << "\\t"; break;
|
||||
|
||||
default:
|
||||
if ('\x00' <= c && c <= '\x1f')
|
||||
{
|
||||
oss << "\\u" << std::hex << std::setw(4)
|
||||
<< std::setfill('0') << (int)(c);
|
||||
}
|
||||
else
|
||||
{
|
||||
oss << c;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return oss.str();
|
||||
}
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
SBE_NODISCARD std::string_view getOrigOrderUserAsStringView() const SBE_NOEXCEPT
|
||||
{
|
||||
const char *buffer = m_buffer + m_offset + 71;
|
||||
std::size_t length = 0;
|
||||
|
||||
for (; length < 8 && *(buffer + length) != '\0'; ++length);
|
||||
std::string_view result(buffer, length);
|
||||
|
||||
return result;
|
||||
}
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
OrderMassActionRequest529 &putOrigOrderUser(const std::string_view str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 8)
|
||||
{
|
||||
throw std::runtime_error("string too large for putOrigOrderUser [E106]");
|
||||
}
|
||||
|
||||
std::memcpy(m_buffer + m_offset + 71, str.data(), srcLength);
|
||||
for (std::size_t start = srcLength; start < 8; ++start)
|
||||
{
|
||||
m_buffer[m_offset + 71 + start] = 0;
|
||||
}
|
||||
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
OrderMassActionRequest529 &putOrigOrderUser(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 8)
|
||||
{
|
||||
throw std::runtime_error("string too large for putOrigOrderUser [E106]");
|
||||
}
|
||||
|
||||
std::memcpy(m_buffer + m_offset + 71, str.c_str(), srcLength);
|
||||
for (std::size_t start = srcLength; start < 8; ++start)
|
||||
{
|
||||
m_buffer[m_offset + 71 + start] = 0;
|
||||
}
|
||||
|
||||
return *this;
|
||||
}
|
||||
#endif
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, OrderMassActionRequest529 _writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, OrderMassActionRequest529 _writer)
|
||||
{
|
||||
OrderMassActionRequest529 writer(_writer.m_buffer, _writer.m_offset,
|
||||
_writer.m_bufferLength, _writer.sbeBlockLength(), _writer.m_actingVersion);
|
||||
OrderMassActionRequest529 writer(
|
||||
_writer.m_buffer,
|
||||
_writer.m_offset,
|
||||
_writer.m_bufferLength,
|
||||
_writer.m_actingBlockLength,
|
||||
_writer.m_actingVersion);
|
||||
|
||||
builder << '{';
|
||||
builder << R"("Name": "OrderMassActionRequest529", )";
|
||||
builder << R"("sbeTemplateId": )";
|
||||
@@ -2026,6 +2269,11 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
builder << R"("LiquidityFlag": )";
|
||||
builder << '"' << writer.liquidityFlag() << '"';
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("OrigOrderUser": )";
|
||||
builder << '"' <<
|
||||
writer.getOrigOrderUserAsJsonEscapedString().c_str() << '"';
|
||||
|
||||
builder << '}';
|
||||
|
||||
return builder;
|
||||
|
||||
@@ -70,11 +70,11 @@
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (__builtin_expect(exp, c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
@@ -156,6 +156,7 @@ private:
|
||||
std::uint64_t m_bufferLength = 0;
|
||||
std::uint64_t m_offset = 0;
|
||||
std::uint64_t m_position = 0;
|
||||
std::uint64_t m_actingBlockLength = 0;
|
||||
std::uint64_t m_actingVersion = 0;
|
||||
|
||||
inline std::uint64_t *sbePositionPtr() SBE_NOEXCEPT
|
||||
@@ -167,7 +168,7 @@ public:
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(68);
|
||||
static const std::uint16_t SBE_TEMPLATE_ID = static_cast<std::uint16_t>(530);
|
||||
static const std::uint16_t SBE_SCHEMA_ID = static_cast<std::uint16_t>(8);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(7);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(8);
|
||||
|
||||
enum MetaAttribute
|
||||
{
|
||||
@@ -200,6 +201,7 @@ public:
|
||||
m_bufferLength(bufferLength),
|
||||
m_offset(offset),
|
||||
m_position(sbeCheckPosition(offset + actingBlockLength)),
|
||||
m_actingBlockLength(actingBlockLength),
|
||||
m_actingVersion(actingVersion)
|
||||
{
|
||||
}
|
||||
@@ -240,7 +242,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeSchemaVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(7);
|
||||
return static_cast<std::uint16_t>(8);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR const char *sbeSemanticType() SBE_NOEXCEPT
|
||||
@@ -286,6 +288,11 @@ public:
|
||||
return *this = OrderMassStatusRequest530(buffer, offset, bufferLength, actingBlockLength, actingVersion);
|
||||
}
|
||||
|
||||
OrderMassStatusRequest530 &sbeRewind()
|
||||
{
|
||||
return wrapForDecode(m_buffer, m_offset, m_actingBlockLength, m_actingVersion, m_bufferLength);
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::uint64_t sbePosition() const SBE_NOEXCEPT
|
||||
{
|
||||
return m_position;
|
||||
@@ -802,7 +809,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
OrderMassStatusRequest530 &putSenderID(const std::string& str)
|
||||
OrderMassStatusRequest530 &putSenderID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -1079,7 +1086,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
OrderMassStatusRequest530 &putSecurityGroup(const std::string& str)
|
||||
OrderMassStatusRequest530 &putSecurityGroup(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 6)
|
||||
@@ -1285,7 +1292,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
OrderMassStatusRequest530 &putLocation(const std::string& str)
|
||||
OrderMassStatusRequest530 &putLocation(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 5)
|
||||
@@ -1635,11 +1642,16 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, OrderMassStatusRequest530 _writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, OrderMassStatusRequest530 _writer)
|
||||
{
|
||||
OrderMassStatusRequest530 writer(_writer.m_buffer, _writer.m_offset,
|
||||
_writer.m_bufferLength, _writer.sbeBlockLength(), _writer.m_actingVersion);
|
||||
OrderMassStatusRequest530 writer(
|
||||
_writer.m_buffer,
|
||||
_writer.m_offset,
|
||||
_writer.m_bufferLength,
|
||||
_writer.m_actingBlockLength,
|
||||
_writer.m_actingVersion);
|
||||
|
||||
builder << '{';
|
||||
builder << R"("Name": "OrderMassStatusRequest530", )";
|
||||
builder << R"("sbeTemplateId": )";
|
||||
|
||||
@@ -2,80 +2,17 @@
|
||||
#ifndef _ILINKBINARY_ORDERSTATUS_H_
|
||||
#define _ILINKBINARY_ORDERSTATUS_H_
|
||||
|
||||
#if defined(SBE_HAVE_CMATH)
|
||||
/* cmath needed for std::numeric_limits<double>::quiet_NaN() */
|
||||
# include <cmath>
|
||||
# define SBE_FLOAT_NAN std::numeric_limits<float>::quiet_NaN()
|
||||
# define SBE_DOUBLE_NAN std::numeric_limits<double>::quiet_NaN()
|
||||
#else
|
||||
/* math.h needed for NAN */
|
||||
# include <math.h>
|
||||
# define SBE_FLOAT_NAN NAN
|
||||
# define SBE_DOUBLE_NAN NAN
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201103L
|
||||
# define SBE_CONSTEXPR constexpr
|
||||
# define SBE_NOEXCEPT noexcept
|
||||
#else
|
||||
# define SBE_CONSTEXPR
|
||||
# define SBE_NOEXCEPT
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
# include <string_view>
|
||||
# define SBE_NODISCARD [[nodiscard]]
|
||||
#else
|
||||
# define SBE_NODISCARD
|
||||
#endif
|
||||
|
||||
#if !defined(__STDC_LIMIT_MACROS)
|
||||
# define __STDC_LIMIT_MACROS 1
|
||||
#endif
|
||||
|
||||
#include <cstdint>
|
||||
#include <cstring>
|
||||
#include <iomanip>
|
||||
#include <limits>
|
||||
#include <ostream>
|
||||
#include <stdexcept>
|
||||
#include <sstream>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <tuple>
|
||||
|
||||
#if defined(WIN32) || defined(_WIN32)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) _byteswap_ushort(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) _byteswap_ulong(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) _byteswap_uint64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) (v)
|
||||
#else
|
||||
# error "Byte Ordering of platform not determined. Set __BYTE_ORDER__ manually before including this file."
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
#define SBE_NULLVALUE_INT16 (std::numeric_limits<std::int16_t>::min)()
|
||||
@@ -86,7 +23,6 @@
|
||||
#define SBE_NULLVALUE_UINT32 (std::numeric_limits<std::uint32_t>::max)()
|
||||
#define SBE_NULLVALUE_UINT64 (std::numeric_limits<std::uint64_t>::max)()
|
||||
|
||||
|
||||
namespace iLinkBinary {
|
||||
|
||||
class OrderStatus
|
||||
@@ -148,8 +84,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& os, OrderStatus::Value m)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &os, OrderStatus::Value m)
|
||||
{
|
||||
return os << OrderStatus::c_str(m);
|
||||
}
|
||||
|
||||
@@ -70,11 +70,11 @@
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (__builtin_expect(exp, c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
@@ -156,6 +156,7 @@ private:
|
||||
std::uint64_t m_bufferLength = 0;
|
||||
std::uint64_t m_offset = 0;
|
||||
std::uint64_t m_position = 0;
|
||||
std::uint64_t m_actingBlockLength = 0;
|
||||
std::uint64_t m_actingVersion = 0;
|
||||
|
||||
inline std::uint64_t *sbePositionPtr() SBE_NOEXCEPT
|
||||
@@ -167,7 +168,7 @@ public:
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(62);
|
||||
static const std::uint16_t SBE_TEMPLATE_ID = static_cast<std::uint16_t>(533);
|
||||
static const std::uint16_t SBE_SCHEMA_ID = static_cast<std::uint16_t>(8);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(7);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(8);
|
||||
|
||||
enum MetaAttribute
|
||||
{
|
||||
@@ -200,6 +201,7 @@ public:
|
||||
m_bufferLength(bufferLength),
|
||||
m_offset(offset),
|
||||
m_position(sbeCheckPosition(offset + actingBlockLength)),
|
||||
m_actingBlockLength(actingBlockLength),
|
||||
m_actingVersion(actingVersion)
|
||||
{
|
||||
}
|
||||
@@ -240,7 +242,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeSchemaVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(7);
|
||||
return static_cast<std::uint16_t>(8);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR const char *sbeSemanticType() SBE_NOEXCEPT
|
||||
@@ -286,6 +288,11 @@ public:
|
||||
return *this = OrderStatusRequest533(buffer, offset, bufferLength, actingBlockLength, actingVersion);
|
||||
}
|
||||
|
||||
OrderStatusRequest533 &sbeRewind()
|
||||
{
|
||||
return wrapForDecode(m_buffer, m_offset, m_actingBlockLength, m_actingVersion, m_bufferLength);
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::uint64_t sbePosition() const SBE_NOEXCEPT
|
||||
{
|
||||
return m_position;
|
||||
@@ -802,7 +809,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
OrderStatusRequest533 &putSenderID(const std::string& str)
|
||||
OrderStatusRequest533 &putSenderID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -1150,7 +1157,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
OrderStatusRequest533 &putLocation(const std::string& str)
|
||||
OrderStatusRequest533 &putLocation(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 5)
|
||||
@@ -1169,11 +1176,16 @@ public:
|
||||
#endif
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, OrderStatusRequest533 _writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, OrderStatusRequest533 _writer)
|
||||
{
|
||||
OrderStatusRequest533 writer(_writer.m_buffer, _writer.m_offset,
|
||||
_writer.m_bufferLength, _writer.sbeBlockLength(), _writer.m_actingVersion);
|
||||
OrderStatusRequest533 writer(
|
||||
_writer.m_buffer,
|
||||
_writer.m_offset,
|
||||
_writer.m_bufferLength,
|
||||
_writer.m_actingBlockLength,
|
||||
_writer.m_actingVersion);
|
||||
|
||||
builder << '{';
|
||||
builder << R"("Name": "OrderStatusRequest533", )";
|
||||
builder << R"("sbeTemplateId": )";
|
||||
|
||||
@@ -2,80 +2,17 @@
|
||||
#ifndef _ILINKBINARY_ORDERTYPE_H_
|
||||
#define _ILINKBINARY_ORDERTYPE_H_
|
||||
|
||||
#if defined(SBE_HAVE_CMATH)
|
||||
/* cmath needed for std::numeric_limits<double>::quiet_NaN() */
|
||||
# include <cmath>
|
||||
# define SBE_FLOAT_NAN std::numeric_limits<float>::quiet_NaN()
|
||||
# define SBE_DOUBLE_NAN std::numeric_limits<double>::quiet_NaN()
|
||||
#else
|
||||
/* math.h needed for NAN */
|
||||
# include <math.h>
|
||||
# define SBE_FLOAT_NAN NAN
|
||||
# define SBE_DOUBLE_NAN NAN
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201103L
|
||||
# define SBE_CONSTEXPR constexpr
|
||||
# define SBE_NOEXCEPT noexcept
|
||||
#else
|
||||
# define SBE_CONSTEXPR
|
||||
# define SBE_NOEXCEPT
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
# include <string_view>
|
||||
# define SBE_NODISCARD [[nodiscard]]
|
||||
#else
|
||||
# define SBE_NODISCARD
|
||||
#endif
|
||||
|
||||
#if !defined(__STDC_LIMIT_MACROS)
|
||||
# define __STDC_LIMIT_MACROS 1
|
||||
#endif
|
||||
|
||||
#include <cstdint>
|
||||
#include <cstring>
|
||||
#include <iomanip>
|
||||
#include <limits>
|
||||
#include <ostream>
|
||||
#include <stdexcept>
|
||||
#include <sstream>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <tuple>
|
||||
|
||||
#if defined(WIN32) || defined(_WIN32)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) _byteswap_ushort(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) _byteswap_ulong(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) _byteswap_uint64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) (v)
|
||||
#else
|
||||
# error "Byte Ordering of platform not determined. Set __BYTE_ORDER__ manually before including this file."
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
#define SBE_NULLVALUE_INT16 (std::numeric_limits<std::int16_t>::min)()
|
||||
@@ -86,7 +23,6 @@
|
||||
#define SBE_NULLVALUE_UINT32 (std::numeric_limits<std::uint32_t>::max)()
|
||||
#define SBE_NULLVALUE_UINT64 (std::numeric_limits<std::uint64_t>::max)()
|
||||
|
||||
|
||||
namespace iLinkBinary {
|
||||
|
||||
class OrderType
|
||||
@@ -98,7 +34,7 @@ public:
|
||||
Limit = static_cast<char>(50),
|
||||
StopLimit = static_cast<char>(52),
|
||||
MarketWithLeftoverAsLimit = static_cast<char>(75),
|
||||
NULL_VALUE = static_cast<char>(0)
|
||||
NULL_VALUE = static_cast<char>(48)
|
||||
};
|
||||
|
||||
static OrderType::Value get(const char value)
|
||||
@@ -109,7 +45,7 @@ public:
|
||||
case static_cast<char>(50): return Limit;
|
||||
case static_cast<char>(52): return StopLimit;
|
||||
case static_cast<char>(75): return MarketWithLeftoverAsLimit;
|
||||
case static_cast<char>(0): return NULL_VALUE;
|
||||
case static_cast<char>(48): return NULL_VALUE;
|
||||
}
|
||||
|
||||
throw std::runtime_error("unknown value for enum OrderType [E103]");
|
||||
@@ -130,8 +66,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& os, OrderType::Value m)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &os, OrderType::Value m)
|
||||
{
|
||||
return os << OrderType::c_str(m);
|
||||
}
|
||||
|
||||
@@ -2,80 +2,17 @@
|
||||
#ifndef _ILINKBINARY_ORDERTYPEREQ_H_
|
||||
#define _ILINKBINARY_ORDERTYPEREQ_H_
|
||||
|
||||
#if defined(SBE_HAVE_CMATH)
|
||||
/* cmath needed for std::numeric_limits<double>::quiet_NaN() */
|
||||
# include <cmath>
|
||||
# define SBE_FLOAT_NAN std::numeric_limits<float>::quiet_NaN()
|
||||
# define SBE_DOUBLE_NAN std::numeric_limits<double>::quiet_NaN()
|
||||
#else
|
||||
/* math.h needed for NAN */
|
||||
# include <math.h>
|
||||
# define SBE_FLOAT_NAN NAN
|
||||
# define SBE_DOUBLE_NAN NAN
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201103L
|
||||
# define SBE_CONSTEXPR constexpr
|
||||
# define SBE_NOEXCEPT noexcept
|
||||
#else
|
||||
# define SBE_CONSTEXPR
|
||||
# define SBE_NOEXCEPT
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
# include <string_view>
|
||||
# define SBE_NODISCARD [[nodiscard]]
|
||||
#else
|
||||
# define SBE_NODISCARD
|
||||
#endif
|
||||
|
||||
#if !defined(__STDC_LIMIT_MACROS)
|
||||
# define __STDC_LIMIT_MACROS 1
|
||||
#endif
|
||||
|
||||
#include <cstdint>
|
||||
#include <cstring>
|
||||
#include <iomanip>
|
||||
#include <limits>
|
||||
#include <ostream>
|
||||
#include <stdexcept>
|
||||
#include <sstream>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <tuple>
|
||||
|
||||
#if defined(WIN32) || defined(_WIN32)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) _byteswap_ushort(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) _byteswap_ulong(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) _byteswap_uint64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) (v)
|
||||
#else
|
||||
# error "Byte Ordering of platform not determined. Set __BYTE_ORDER__ manually before including this file."
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
#define SBE_NULLVALUE_INT16 (std::numeric_limits<std::int16_t>::min)()
|
||||
@@ -86,7 +23,6 @@
|
||||
#define SBE_NULLVALUE_UINT32 (std::numeric_limits<std::uint32_t>::max)()
|
||||
#define SBE_NULLVALUE_UINT64 (std::numeric_limits<std::uint64_t>::max)()
|
||||
|
||||
|
||||
namespace iLinkBinary {
|
||||
|
||||
class OrderTypeReq
|
||||
@@ -133,8 +69,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& os, OrderTypeReq::Value m)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &os, OrderTypeReq::Value m)
|
||||
{
|
||||
return os << OrderTypeReq::c_str(m);
|
||||
}
|
||||
|
||||
@@ -70,11 +70,11 @@
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (__builtin_expect(exp, c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
@@ -194,7 +194,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeSchemaVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(7);
|
||||
return static_cast<std::uint16_t>(8);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static const char *mantissaMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
@@ -329,8 +329,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, PRICE9 writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, PRICE9 writer)
|
||||
{
|
||||
builder << '{';
|
||||
builder << R"("mantissa": )";
|
||||
|
||||
@@ -70,11 +70,11 @@
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (__builtin_expect(exp, c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
@@ -194,7 +194,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeSchemaVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(7);
|
||||
return static_cast<std::uint16_t>(8);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static const char *mantissaMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
@@ -329,8 +329,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, PRICENULL9 writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, PRICENULL9 writer)
|
||||
{
|
||||
builder << '{';
|
||||
builder << R"("mantissa": )";
|
||||
|
||||
@@ -2,80 +2,17 @@
|
||||
#ifndef _ILINKBINARY_PARTYDETAILROLE_H_
|
||||
#define _ILINKBINARY_PARTYDETAILROLE_H_
|
||||
|
||||
#if defined(SBE_HAVE_CMATH)
|
||||
/* cmath needed for std::numeric_limits<double>::quiet_NaN() */
|
||||
# include <cmath>
|
||||
# define SBE_FLOAT_NAN std::numeric_limits<float>::quiet_NaN()
|
||||
# define SBE_DOUBLE_NAN std::numeric_limits<double>::quiet_NaN()
|
||||
#else
|
||||
/* math.h needed for NAN */
|
||||
# include <math.h>
|
||||
# define SBE_FLOAT_NAN NAN
|
||||
# define SBE_DOUBLE_NAN NAN
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201103L
|
||||
# define SBE_CONSTEXPR constexpr
|
||||
# define SBE_NOEXCEPT noexcept
|
||||
#else
|
||||
# define SBE_CONSTEXPR
|
||||
# define SBE_NOEXCEPT
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
# include <string_view>
|
||||
# define SBE_NODISCARD [[nodiscard]]
|
||||
#else
|
||||
# define SBE_NODISCARD
|
||||
#endif
|
||||
|
||||
#if !defined(__STDC_LIMIT_MACROS)
|
||||
# define __STDC_LIMIT_MACROS 1
|
||||
#endif
|
||||
|
||||
#include <cstdint>
|
||||
#include <cstring>
|
||||
#include <iomanip>
|
||||
#include <limits>
|
||||
#include <ostream>
|
||||
#include <stdexcept>
|
||||
#include <sstream>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <tuple>
|
||||
|
||||
#if defined(WIN32) || defined(_WIN32)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) _byteswap_ushort(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) _byteswap_ulong(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) _byteswap_uint64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) (v)
|
||||
#else
|
||||
# error "Byte Ordering of platform not determined. Set __BYTE_ORDER__ manually before including this file."
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
#define SBE_NULLVALUE_INT16 (std::numeric_limits<std::int16_t>::min)()
|
||||
@@ -86,7 +23,6 @@
|
||||
#define SBE_NULLVALUE_UINT32 (std::numeric_limits<std::uint32_t>::max)()
|
||||
#define SBE_NULLVALUE_UINT64 (std::numeric_limits<std::uint64_t>::max)()
|
||||
|
||||
|
||||
namespace iLinkBinary {
|
||||
|
||||
class PartyDetailRole
|
||||
@@ -133,8 +69,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& os, PartyDetailRole::Value m)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &os, PartyDetailRole::Value m)
|
||||
{
|
||||
return os << PartyDetailRole::c_str(m);
|
||||
}
|
||||
|
||||
@@ -70,11 +70,11 @@
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (__builtin_expect(exp, c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
@@ -156,6 +156,7 @@ private:
|
||||
std::uint64_t m_bufferLength = 0;
|
||||
std::uint64_t m_offset = 0;
|
||||
std::uint64_t m_position = 0;
|
||||
std::uint64_t m_actingBlockLength = 0;
|
||||
std::uint64_t m_actingVersion = 0;
|
||||
|
||||
inline std::uint64_t *sbePositionPtr() SBE_NOEXCEPT
|
||||
@@ -167,7 +168,7 @@ public:
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(147);
|
||||
static const std::uint16_t SBE_TEMPLATE_ID = static_cast<std::uint16_t>(518);
|
||||
static const std::uint16_t SBE_SCHEMA_ID = static_cast<std::uint16_t>(8);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(7);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(8);
|
||||
|
||||
enum MetaAttribute
|
||||
{
|
||||
@@ -200,6 +201,7 @@ public:
|
||||
m_bufferLength(bufferLength),
|
||||
m_offset(offset),
|
||||
m_position(sbeCheckPosition(offset + actingBlockLength)),
|
||||
m_actingBlockLength(actingBlockLength),
|
||||
m_actingVersion(actingVersion)
|
||||
{
|
||||
}
|
||||
@@ -240,7 +242,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeSchemaVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(7);
|
||||
return static_cast<std::uint16_t>(8);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR const char *sbeSemanticType() SBE_NOEXCEPT
|
||||
@@ -286,6 +288,11 @@ public:
|
||||
return *this = PartyDetailsDefinitionRequest518(buffer, offset, bufferLength, actingBlockLength, actingVersion);
|
||||
}
|
||||
|
||||
PartyDetailsDefinitionRequest518 &sbeRewind()
|
||||
{
|
||||
return wrapForDecode(m_buffer, m_offset, m_actingBlockLength, m_actingVersion, m_bufferLength);
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::uint64_t sbePosition() const SBE_NOEXCEPT
|
||||
{
|
||||
return m_position;
|
||||
@@ -802,7 +809,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
PartyDetailsDefinitionRequest518 &putMemo(const std::string& str)
|
||||
PartyDetailsDefinitionRequest518 &putMemo(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 75)
|
||||
@@ -1008,7 +1015,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
PartyDetailsDefinitionRequest518 &putAvgPxGroupID(const std::string& str)
|
||||
PartyDetailsDefinitionRequest518 &putAvgPxGroupID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -1868,7 +1875,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
|
||||
inline std::uint64_t resetCountToIndex() SBE_NOEXCEPT
|
||||
inline std::uint64_t resetCountToIndex()
|
||||
{
|
||||
m_count = m_index;
|
||||
GroupSize dimensions(m_buffer, m_initialPosition, m_bufferLength, m_actingVersion);
|
||||
@@ -1876,8 +1883,7 @@ public:
|
||||
return m_count;
|
||||
}
|
||||
|
||||
#if __cplusplus < 201103L
|
||||
template<class Func> inline void forEach(Func& func)
|
||||
template<class Func> inline void forEach(Func &&func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
@@ -1886,17 +1892,6 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
#else
|
||||
template<class Func> inline void forEach(Func&& func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
next();
|
||||
func(*this);
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
SBE_NODISCARD static const char *PartyDetailIDMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
@@ -2086,7 +2081,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
NoPartyDetails &putPartyDetailID(const std::string& str)
|
||||
NoPartyDetails &putPartyDetailID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -2293,8 +2288,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, NoPartyDetails writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, NoPartyDetails writer)
|
||||
{
|
||||
builder << '{';
|
||||
builder << R"("PartyDetailID": )";
|
||||
@@ -2498,7 +2493,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
|
||||
inline std::uint64_t resetCountToIndex() SBE_NOEXCEPT
|
||||
inline std::uint64_t resetCountToIndex()
|
||||
{
|
||||
m_count = m_index;
|
||||
GroupSize dimensions(m_buffer, m_initialPosition, m_bufferLength, m_actingVersion);
|
||||
@@ -2506,8 +2501,7 @@ public:
|
||||
return m_count;
|
||||
}
|
||||
|
||||
#if __cplusplus < 201103L
|
||||
template<class Func> inline void forEach(Func& func)
|
||||
template<class Func> inline void forEach(Func &&func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
@@ -2516,17 +2510,6 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
#else
|
||||
template<class Func> inline void forEach(Func&& func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
next();
|
||||
func(*this);
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
SBE_NODISCARD static const char *TrdRegPublicationTypeMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
@@ -2671,8 +2654,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, NoTrdRegPublications writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, NoTrdRegPublications writer)
|
||||
{
|
||||
builder << '{';
|
||||
builder << R"("TrdRegPublicationType": )";
|
||||
@@ -2750,11 +2733,16 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, PartyDetailsDefinitionRequest518 _writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, PartyDetailsDefinitionRequest518 _writer)
|
||||
{
|
||||
PartyDetailsDefinitionRequest518 writer(_writer.m_buffer, _writer.m_offset,
|
||||
_writer.m_bufferLength, _writer.sbeBlockLength(), _writer.m_actingVersion);
|
||||
PartyDetailsDefinitionRequest518 writer(
|
||||
_writer.m_buffer,
|
||||
_writer.m_offset,
|
||||
_writer.m_bufferLength,
|
||||
_writer.m_actingBlockLength,
|
||||
_writer.m_actingVersion);
|
||||
|
||||
builder << '{';
|
||||
builder << R"("Name": "PartyDetailsDefinitionRequest518", )";
|
||||
builder << R"("sbeTemplateId": )";
|
||||
@@ -2830,15 +2818,16 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
{
|
||||
bool atLeastOne = false;
|
||||
builder << R"("NoPartyDetails": [)";
|
||||
writer.noPartyDetails().forEach([&](NoPartyDetails& noPartyDetails)
|
||||
{
|
||||
if (atLeastOne)
|
||||
writer.noPartyDetails().forEach(
|
||||
[&](NoPartyDetails &noPartyDetails)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noPartyDetails;
|
||||
});
|
||||
if (atLeastOne)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noPartyDetails;
|
||||
});
|
||||
builder << ']';
|
||||
}
|
||||
|
||||
@@ -2846,15 +2835,16 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
{
|
||||
bool atLeastOne = false;
|
||||
builder << R"("NoTrdRegPublications": [)";
|
||||
writer.noTrdRegPublications().forEach([&](NoTrdRegPublications& noTrdRegPublications)
|
||||
{
|
||||
if (atLeastOne)
|
||||
writer.noTrdRegPublications().forEach(
|
||||
[&](NoTrdRegPublications &noTrdRegPublications)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noTrdRegPublications;
|
||||
});
|
||||
if (atLeastOne)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noTrdRegPublications;
|
||||
});
|
||||
builder << ']';
|
||||
}
|
||||
|
||||
@@ -2865,14 +2855,16 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
|
||||
void skip()
|
||||
{
|
||||
noPartyDetails().forEach([](NoPartyDetails e)
|
||||
auto &noPartyDetailsGroup { noPartyDetails() };
|
||||
while (noPartyDetailsGroup.hasNext())
|
||||
{
|
||||
e.skip();
|
||||
});
|
||||
noTrdRegPublications().forEach([](NoTrdRegPublications e)
|
||||
noPartyDetailsGroup.next().skip();
|
||||
}
|
||||
auto &noTrdRegPublicationsGroup { noTrdRegPublications() };
|
||||
while (noTrdRegPublicationsGroup.hasNext())
|
||||
{
|
||||
e.skip();
|
||||
});
|
||||
noTrdRegPublicationsGroup.next().skip();
|
||||
}
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR bool isConstLength() SBE_NOEXCEPT
|
||||
|
||||
@@ -70,11 +70,11 @@
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (__builtin_expect(exp, c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
@@ -156,6 +156,7 @@ private:
|
||||
std::uint64_t m_bufferLength = 0;
|
||||
std::uint64_t m_offset = 0;
|
||||
std::uint64_t m_position = 0;
|
||||
std::uint64_t m_actingBlockLength = 0;
|
||||
std::uint64_t m_actingVersion = 0;
|
||||
|
||||
inline std::uint64_t *sbePositionPtr() SBE_NOEXCEPT
|
||||
@@ -167,7 +168,7 @@ public:
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(159);
|
||||
static const std::uint16_t SBE_TEMPLATE_ID = static_cast<std::uint16_t>(519);
|
||||
static const std::uint16_t SBE_SCHEMA_ID = static_cast<std::uint16_t>(8);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(7);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(8);
|
||||
|
||||
enum MetaAttribute
|
||||
{
|
||||
@@ -200,6 +201,7 @@ public:
|
||||
m_bufferLength(bufferLength),
|
||||
m_offset(offset),
|
||||
m_position(sbeCheckPosition(offset + actingBlockLength)),
|
||||
m_actingBlockLength(actingBlockLength),
|
||||
m_actingVersion(actingVersion)
|
||||
{
|
||||
}
|
||||
@@ -240,7 +242,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeSchemaVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(7);
|
||||
return static_cast<std::uint16_t>(8);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR const char *sbeSemanticType() SBE_NOEXCEPT
|
||||
@@ -286,6 +288,11 @@ public:
|
||||
return *this = PartyDetailsDefinitionRequestAck519(buffer, offset, bufferLength, actingBlockLength, actingVersion);
|
||||
}
|
||||
|
||||
PartyDetailsDefinitionRequestAck519 &sbeRewind()
|
||||
{
|
||||
return wrapForDecode(m_buffer, m_offset, m_actingBlockLength, m_actingVersion, m_bufferLength);
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::uint64_t sbePosition() const SBE_NOEXCEPT
|
||||
{
|
||||
return m_position;
|
||||
@@ -668,7 +675,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
PartyDetailsDefinitionRequestAck519 &putMemo(const std::string& str)
|
||||
PartyDetailsDefinitionRequestAck519 &putMemo(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 75)
|
||||
@@ -874,7 +881,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
PartyDetailsDefinitionRequestAck519 &putAvgPxGroupID(const std::string& str)
|
||||
PartyDetailsDefinitionRequestAck519 &putAvgPxGroupID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -2207,7 +2214,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
|
||||
inline std::uint64_t resetCountToIndex() SBE_NOEXCEPT
|
||||
inline std::uint64_t resetCountToIndex()
|
||||
{
|
||||
m_count = m_index;
|
||||
GroupSize dimensions(m_buffer, m_initialPosition, m_bufferLength, m_actingVersion);
|
||||
@@ -2215,8 +2222,7 @@ public:
|
||||
return m_count;
|
||||
}
|
||||
|
||||
#if __cplusplus < 201103L
|
||||
template<class Func> inline void forEach(Func& func)
|
||||
template<class Func> inline void forEach(Func &&func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
@@ -2225,17 +2231,6 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
#else
|
||||
template<class Func> inline void forEach(Func&& func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
next();
|
||||
func(*this);
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
SBE_NODISCARD static const char *PartyDetailIDMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
@@ -2425,7 +2420,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
NoPartyDetails &putPartyDetailID(const std::string& str)
|
||||
NoPartyDetails &putPartyDetailID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -2632,8 +2627,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, NoPartyDetails writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, NoPartyDetails writer)
|
||||
{
|
||||
builder << '{';
|
||||
builder << R"("PartyDetailID": )";
|
||||
@@ -2837,7 +2832,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
|
||||
inline std::uint64_t resetCountToIndex() SBE_NOEXCEPT
|
||||
inline std::uint64_t resetCountToIndex()
|
||||
{
|
||||
m_count = m_index;
|
||||
GroupSize dimensions(m_buffer, m_initialPosition, m_bufferLength, m_actingVersion);
|
||||
@@ -2845,8 +2840,7 @@ public:
|
||||
return m_count;
|
||||
}
|
||||
|
||||
#if __cplusplus < 201103L
|
||||
template<class Func> inline void forEach(Func& func)
|
||||
template<class Func> inline void forEach(Func &&func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
@@ -2855,17 +2849,6 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
#else
|
||||
template<class Func> inline void forEach(Func&& func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
next();
|
||||
func(*this);
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
SBE_NODISCARD static const char *TrdRegPublicationTypeMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
@@ -3010,8 +2993,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, NoTrdRegPublications writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, NoTrdRegPublications writer)
|
||||
{
|
||||
builder << '{';
|
||||
builder << R"("TrdRegPublicationType": )";
|
||||
@@ -3089,11 +3072,16 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, PartyDetailsDefinitionRequestAck519 _writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, PartyDetailsDefinitionRequestAck519 _writer)
|
||||
{
|
||||
PartyDetailsDefinitionRequestAck519 writer(_writer.m_buffer, _writer.m_offset,
|
||||
_writer.m_bufferLength, _writer.sbeBlockLength(), _writer.m_actingVersion);
|
||||
PartyDetailsDefinitionRequestAck519 writer(
|
||||
_writer.m_buffer,
|
||||
_writer.m_offset,
|
||||
_writer.m_bufferLength,
|
||||
_writer.m_actingBlockLength,
|
||||
_writer.m_actingVersion);
|
||||
|
||||
builder << '{';
|
||||
builder << R"("Name": "PartyDetailsDefinitionRequestAck519", )";
|
||||
builder << R"("sbeTemplateId": )";
|
||||
@@ -3189,15 +3177,16 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
{
|
||||
bool atLeastOne = false;
|
||||
builder << R"("NoPartyDetails": [)";
|
||||
writer.noPartyDetails().forEach([&](NoPartyDetails& noPartyDetails)
|
||||
{
|
||||
if (atLeastOne)
|
||||
writer.noPartyDetails().forEach(
|
||||
[&](NoPartyDetails &noPartyDetails)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noPartyDetails;
|
||||
});
|
||||
if (atLeastOne)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noPartyDetails;
|
||||
});
|
||||
builder << ']';
|
||||
}
|
||||
|
||||
@@ -3205,15 +3194,16 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
{
|
||||
bool atLeastOne = false;
|
||||
builder << R"("NoTrdRegPublications": [)";
|
||||
writer.noTrdRegPublications().forEach([&](NoTrdRegPublications& noTrdRegPublications)
|
||||
{
|
||||
if (atLeastOne)
|
||||
writer.noTrdRegPublications().forEach(
|
||||
[&](NoTrdRegPublications &noTrdRegPublications)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noTrdRegPublications;
|
||||
});
|
||||
if (atLeastOne)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noTrdRegPublications;
|
||||
});
|
||||
builder << ']';
|
||||
}
|
||||
|
||||
@@ -3224,14 +3214,16 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
|
||||
void skip()
|
||||
{
|
||||
noPartyDetails().forEach([](NoPartyDetails e)
|
||||
auto &noPartyDetailsGroup { noPartyDetails() };
|
||||
while (noPartyDetailsGroup.hasNext())
|
||||
{
|
||||
e.skip();
|
||||
});
|
||||
noTrdRegPublications().forEach([](NoTrdRegPublications e)
|
||||
noPartyDetailsGroup.next().skip();
|
||||
}
|
||||
auto &noTrdRegPublicationsGroup { noTrdRegPublications() };
|
||||
while (noTrdRegPublicationsGroup.hasNext())
|
||||
{
|
||||
e.skip();
|
||||
});
|
||||
noTrdRegPublicationsGroup.next().skip();
|
||||
}
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR bool isConstLength() SBE_NOEXCEPT
|
||||
|
||||
@@ -70,11 +70,11 @@
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (__builtin_expect(exp, c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
@@ -156,6 +156,7 @@ private:
|
||||
std::uint64_t m_bufferLength = 0;
|
||||
std::uint64_t m_offset = 0;
|
||||
std::uint64_t m_position = 0;
|
||||
std::uint64_t m_actingBlockLength = 0;
|
||||
std::uint64_t m_actingVersion = 0;
|
||||
|
||||
inline std::uint64_t *sbePositionPtr() SBE_NOEXCEPT
|
||||
@@ -167,7 +168,7 @@ public:
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(93);
|
||||
static const std::uint16_t SBE_TEMPLATE_ID = static_cast<std::uint16_t>(538);
|
||||
static const std::uint16_t SBE_SCHEMA_ID = static_cast<std::uint16_t>(8);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(7);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(8);
|
||||
|
||||
enum MetaAttribute
|
||||
{
|
||||
@@ -200,6 +201,7 @@ public:
|
||||
m_bufferLength(bufferLength),
|
||||
m_offset(offset),
|
||||
m_position(sbeCheckPosition(offset + actingBlockLength)),
|
||||
m_actingBlockLength(actingBlockLength),
|
||||
m_actingVersion(actingVersion)
|
||||
{
|
||||
}
|
||||
@@ -240,7 +242,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeSchemaVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(7);
|
||||
return static_cast<std::uint16_t>(8);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR const char *sbeSemanticType() SBE_NOEXCEPT
|
||||
@@ -286,6 +288,11 @@ public:
|
||||
return *this = PartyDetailsListReport538(buffer, offset, bufferLength, actingBlockLength, actingVersion);
|
||||
}
|
||||
|
||||
PartyDetailsListReport538 &sbeRewind()
|
||||
{
|
||||
return wrapForDecode(m_buffer, m_offset, m_actingBlockLength, m_actingVersion, m_bufferLength);
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::uint64_t sbePosition() const SBE_NOEXCEPT
|
||||
{
|
||||
return m_position;
|
||||
@@ -668,7 +675,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
PartyDetailsListReport538 &putAvgPxGroupID(const std::string& str)
|
||||
PartyDetailsListReport538 &putAvgPxGroupID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -2002,7 +2009,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
|
||||
inline std::uint64_t resetCountToIndex() SBE_NOEXCEPT
|
||||
inline std::uint64_t resetCountToIndex()
|
||||
{
|
||||
m_count = m_index;
|
||||
GroupSize dimensions(m_buffer, m_initialPosition, m_bufferLength, m_actingVersion);
|
||||
@@ -2010,8 +2017,7 @@ public:
|
||||
return m_count;
|
||||
}
|
||||
|
||||
#if __cplusplus < 201103L
|
||||
template<class Func> inline void forEach(Func& func)
|
||||
template<class Func> inline void forEach(Func &&func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
@@ -2020,17 +2026,6 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
#else
|
||||
template<class Func> inline void forEach(Func&& func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
next();
|
||||
func(*this);
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
SBE_NODISCARD static const char *PartyDetailIDMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
@@ -2220,7 +2215,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
NoPartyDetails &putPartyDetailID(const std::string& str)
|
||||
NoPartyDetails &putPartyDetailID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -2427,8 +2422,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, NoPartyDetails writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, NoPartyDetails writer)
|
||||
{
|
||||
builder << '{';
|
||||
builder << R"("PartyDetailID": )";
|
||||
@@ -2632,7 +2627,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
|
||||
inline std::uint64_t resetCountToIndex() SBE_NOEXCEPT
|
||||
inline std::uint64_t resetCountToIndex()
|
||||
{
|
||||
m_count = m_index;
|
||||
GroupSize dimensions(m_buffer, m_initialPosition, m_bufferLength, m_actingVersion);
|
||||
@@ -2640,8 +2635,7 @@ public:
|
||||
return m_count;
|
||||
}
|
||||
|
||||
#if __cplusplus < 201103L
|
||||
template<class Func> inline void forEach(Func& func)
|
||||
template<class Func> inline void forEach(Func &&func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
@@ -2650,17 +2644,6 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
#else
|
||||
template<class Func> inline void forEach(Func&& func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
next();
|
||||
func(*this);
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
SBE_NODISCARD static const char *TrdRegPublicationTypeMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
@@ -2805,8 +2788,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, NoTrdRegPublications writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, NoTrdRegPublications writer)
|
||||
{
|
||||
builder << '{';
|
||||
builder << R"("TrdRegPublicationType": )";
|
||||
@@ -2884,11 +2867,16 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, PartyDetailsListReport538 _writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, PartyDetailsListReport538 _writer)
|
||||
{
|
||||
PartyDetailsListReport538 writer(_writer.m_buffer, _writer.m_offset,
|
||||
_writer.m_bufferLength, _writer.sbeBlockLength(), _writer.m_actingVersion);
|
||||
PartyDetailsListReport538 writer(
|
||||
_writer.m_buffer,
|
||||
_writer.m_offset,
|
||||
_writer.m_bufferLength,
|
||||
_writer.m_actingBlockLength,
|
||||
_writer.m_actingVersion);
|
||||
|
||||
builder << '{';
|
||||
builder << R"("Name": "PartyDetailsListReport538", )";
|
||||
builder << R"("sbeTemplateId": )";
|
||||
@@ -2983,15 +2971,16 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
{
|
||||
bool atLeastOne = false;
|
||||
builder << R"("NoPartyDetails": [)";
|
||||
writer.noPartyDetails().forEach([&](NoPartyDetails& noPartyDetails)
|
||||
{
|
||||
if (atLeastOne)
|
||||
writer.noPartyDetails().forEach(
|
||||
[&](NoPartyDetails &noPartyDetails)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noPartyDetails;
|
||||
});
|
||||
if (atLeastOne)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noPartyDetails;
|
||||
});
|
||||
builder << ']';
|
||||
}
|
||||
|
||||
@@ -2999,15 +2988,16 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
{
|
||||
bool atLeastOne = false;
|
||||
builder << R"("NoTrdRegPublications": [)";
|
||||
writer.noTrdRegPublications().forEach([&](NoTrdRegPublications& noTrdRegPublications)
|
||||
{
|
||||
if (atLeastOne)
|
||||
writer.noTrdRegPublications().forEach(
|
||||
[&](NoTrdRegPublications &noTrdRegPublications)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noTrdRegPublications;
|
||||
});
|
||||
if (atLeastOne)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noTrdRegPublications;
|
||||
});
|
||||
builder << ']';
|
||||
}
|
||||
|
||||
@@ -3018,14 +3008,16 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
|
||||
void skip()
|
||||
{
|
||||
noPartyDetails().forEach([](NoPartyDetails e)
|
||||
auto &noPartyDetailsGroup { noPartyDetails() };
|
||||
while (noPartyDetailsGroup.hasNext())
|
||||
{
|
||||
e.skip();
|
||||
});
|
||||
noTrdRegPublications().forEach([](NoTrdRegPublications e)
|
||||
noPartyDetailsGroup.next().skip();
|
||||
}
|
||||
auto &noTrdRegPublicationsGroup { noTrdRegPublications() };
|
||||
while (noTrdRegPublicationsGroup.hasNext())
|
||||
{
|
||||
e.skip();
|
||||
});
|
||||
noTrdRegPublicationsGroup.next().skip();
|
||||
}
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR bool isConstLength() SBE_NOEXCEPT
|
||||
|
||||
@@ -70,11 +70,11 @@
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (__builtin_expect(exp, c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
@@ -156,6 +156,7 @@ private:
|
||||
std::uint64_t m_bufferLength = 0;
|
||||
std::uint64_t m_offset = 0;
|
||||
std::uint64_t m_position = 0;
|
||||
std::uint64_t m_actingBlockLength = 0;
|
||||
std::uint64_t m_actingVersion = 0;
|
||||
|
||||
inline std::uint64_t *sbePositionPtr() SBE_NOEXCEPT
|
||||
@@ -167,7 +168,7 @@ public:
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(20);
|
||||
static const std::uint16_t SBE_TEMPLATE_ID = static_cast<std::uint16_t>(537);
|
||||
static const std::uint16_t SBE_SCHEMA_ID = static_cast<std::uint16_t>(8);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(7);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(8);
|
||||
|
||||
enum MetaAttribute
|
||||
{
|
||||
@@ -200,6 +201,7 @@ public:
|
||||
m_bufferLength(bufferLength),
|
||||
m_offset(offset),
|
||||
m_position(sbeCheckPosition(offset + actingBlockLength)),
|
||||
m_actingBlockLength(actingBlockLength),
|
||||
m_actingVersion(actingVersion)
|
||||
{
|
||||
}
|
||||
@@ -240,7 +242,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeSchemaVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(7);
|
||||
return static_cast<std::uint16_t>(8);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR const char *sbeSemanticType() SBE_NOEXCEPT
|
||||
@@ -286,6 +288,11 @@ public:
|
||||
return *this = PartyDetailsListRequest537(buffer, offset, bufferLength, actingBlockLength, actingVersion);
|
||||
}
|
||||
|
||||
PartyDetailsListRequest537 &sbeRewind()
|
||||
{
|
||||
return wrapForDecode(m_buffer, m_offset, m_actingBlockLength, m_actingVersion, m_bufferLength);
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::uint64_t sbePosition() const SBE_NOEXCEPT
|
||||
{
|
||||
return m_position;
|
||||
@@ -677,7 +684,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
|
||||
inline std::uint64_t resetCountToIndex() SBE_NOEXCEPT
|
||||
inline std::uint64_t resetCountToIndex()
|
||||
{
|
||||
m_count = m_index;
|
||||
GroupSize dimensions(m_buffer, m_initialPosition, m_bufferLength, m_actingVersion);
|
||||
@@ -685,8 +692,7 @@ public:
|
||||
return m_count;
|
||||
}
|
||||
|
||||
#if __cplusplus < 201103L
|
||||
template<class Func> inline void forEach(Func& func)
|
||||
template<class Func> inline void forEach(Func &&func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
@@ -695,17 +701,6 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
#else
|
||||
template<class Func> inline void forEach(Func&& func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
next();
|
||||
func(*this);
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
SBE_NODISCARD static const char *RequestingPartyIDMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
@@ -895,7 +890,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
NoRequestingPartyIDs &putRequestingPartyID(const std::string& str)
|
||||
NoRequestingPartyIDs &putRequestingPartyID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 5)
|
||||
@@ -1056,8 +1051,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, NoRequestingPartyIDs writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, NoRequestingPartyIDs writer)
|
||||
{
|
||||
builder << '{';
|
||||
builder << R"("RequestingPartyID": )";
|
||||
@@ -1279,7 +1274,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
|
||||
inline std::uint64_t resetCountToIndex() SBE_NOEXCEPT
|
||||
inline std::uint64_t resetCountToIndex()
|
||||
{
|
||||
m_count = m_index;
|
||||
GroupSize dimensions(m_buffer, m_initialPosition, m_bufferLength, m_actingVersion);
|
||||
@@ -1287,8 +1282,7 @@ public:
|
||||
return m_count;
|
||||
}
|
||||
|
||||
#if __cplusplus < 201103L
|
||||
template<class Func> inline void forEach(Func& func)
|
||||
template<class Func> inline void forEach(Func &&func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
@@ -1297,17 +1291,6 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
#else
|
||||
template<class Func> inline void forEach(Func&& func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
next();
|
||||
func(*this);
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
SBE_NODISCARD static const char *PartyIDMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
@@ -1523,8 +1506,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, NoPartyIDs writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, NoPartyIDs writer)
|
||||
{
|
||||
builder << '{';
|
||||
builder << R"("PartyID": )";
|
||||
@@ -1613,11 +1596,16 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, PartyDetailsListRequest537 _writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, PartyDetailsListRequest537 _writer)
|
||||
{
|
||||
PartyDetailsListRequest537 writer(_writer.m_buffer, _writer.m_offset,
|
||||
_writer.m_bufferLength, _writer.sbeBlockLength(), _writer.m_actingVersion);
|
||||
PartyDetailsListRequest537 writer(
|
||||
_writer.m_buffer,
|
||||
_writer.m_offset,
|
||||
_writer.m_bufferLength,
|
||||
_writer.m_actingBlockLength,
|
||||
_writer.m_actingVersion);
|
||||
|
||||
builder << '{';
|
||||
builder << R"("Name": "PartyDetailsListRequest537", )";
|
||||
builder << R"("sbeTemplateId": )";
|
||||
@@ -1639,15 +1627,16 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
{
|
||||
bool atLeastOne = false;
|
||||
builder << R"("NoRequestingPartyIDs": [)";
|
||||
writer.noRequestingPartyIDs().forEach([&](NoRequestingPartyIDs& noRequestingPartyIDs)
|
||||
{
|
||||
if (atLeastOne)
|
||||
writer.noRequestingPartyIDs().forEach(
|
||||
[&](NoRequestingPartyIDs &noRequestingPartyIDs)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noRequestingPartyIDs;
|
||||
});
|
||||
if (atLeastOne)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noRequestingPartyIDs;
|
||||
});
|
||||
builder << ']';
|
||||
}
|
||||
|
||||
@@ -1655,15 +1644,16 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
{
|
||||
bool atLeastOne = false;
|
||||
builder << R"("NoPartyIDs": [)";
|
||||
writer.noPartyIDs().forEach([&](NoPartyIDs& noPartyIDs)
|
||||
{
|
||||
if (atLeastOne)
|
||||
writer.noPartyIDs().forEach(
|
||||
[&](NoPartyIDs &noPartyIDs)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noPartyIDs;
|
||||
});
|
||||
if (atLeastOne)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noPartyIDs;
|
||||
});
|
||||
builder << ']';
|
||||
}
|
||||
|
||||
@@ -1674,14 +1664,16 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
|
||||
void skip()
|
||||
{
|
||||
noRequestingPartyIDs().forEach([](NoRequestingPartyIDs e)
|
||||
auto &noRequestingPartyIDsGroup { noRequestingPartyIDs() };
|
||||
while (noRequestingPartyIDsGroup.hasNext())
|
||||
{
|
||||
e.skip();
|
||||
});
|
||||
noPartyIDs().forEach([](NoPartyIDs e)
|
||||
noRequestingPartyIDsGroup.next().skip();
|
||||
}
|
||||
auto &noPartyIDsGroup { noPartyIDs() };
|
||||
while (noPartyIDsGroup.hasNext())
|
||||
{
|
||||
e.skip();
|
||||
});
|
||||
noPartyIDsGroup.next().skip();
|
||||
}
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR bool isConstLength() SBE_NOEXCEPT
|
||||
|
||||
@@ -2,80 +2,17 @@
|
||||
#ifndef _ILINKBINARY_QUOTEACKSTATUS_H_
|
||||
#define _ILINKBINARY_QUOTEACKSTATUS_H_
|
||||
|
||||
#if defined(SBE_HAVE_CMATH)
|
||||
/* cmath needed for std::numeric_limits<double>::quiet_NaN() */
|
||||
# include <cmath>
|
||||
# define SBE_FLOAT_NAN std::numeric_limits<float>::quiet_NaN()
|
||||
# define SBE_DOUBLE_NAN std::numeric_limits<double>::quiet_NaN()
|
||||
#else
|
||||
/* math.h needed for NAN */
|
||||
# include <math.h>
|
||||
# define SBE_FLOAT_NAN NAN
|
||||
# define SBE_DOUBLE_NAN NAN
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201103L
|
||||
# define SBE_CONSTEXPR constexpr
|
||||
# define SBE_NOEXCEPT noexcept
|
||||
#else
|
||||
# define SBE_CONSTEXPR
|
||||
# define SBE_NOEXCEPT
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
# include <string_view>
|
||||
# define SBE_NODISCARD [[nodiscard]]
|
||||
#else
|
||||
# define SBE_NODISCARD
|
||||
#endif
|
||||
|
||||
#if !defined(__STDC_LIMIT_MACROS)
|
||||
# define __STDC_LIMIT_MACROS 1
|
||||
#endif
|
||||
|
||||
#include <cstdint>
|
||||
#include <cstring>
|
||||
#include <iomanip>
|
||||
#include <limits>
|
||||
#include <ostream>
|
||||
#include <stdexcept>
|
||||
#include <sstream>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <tuple>
|
||||
|
||||
#if defined(WIN32) || defined(_WIN32)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) _byteswap_ushort(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) _byteswap_ulong(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) _byteswap_uint64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) (v)
|
||||
#else
|
||||
# error "Byte Ordering of platform not determined. Set __BYTE_ORDER__ manually before including this file."
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
#define SBE_NULLVALUE_INT16 (std::numeric_limits<std::int16_t>::min)()
|
||||
@@ -86,7 +23,6 @@
|
||||
#define SBE_NULLVALUE_UINT32 (std::numeric_limits<std::uint32_t>::max)()
|
||||
#define SBE_NULLVALUE_UINT64 (std::numeric_limits<std::uint64_t>::max)()
|
||||
|
||||
|
||||
namespace iLinkBinary {
|
||||
|
||||
class QuoteAckStatus
|
||||
@@ -124,8 +60,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& os, QuoteAckStatus::Value m)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &os, QuoteAckStatus::Value m)
|
||||
{
|
||||
return os << QuoteAckStatus::c_str(m);
|
||||
}
|
||||
|
||||
@@ -70,11 +70,11 @@
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (__builtin_expect(exp, c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
@@ -156,6 +156,7 @@ private:
|
||||
std::uint64_t m_bufferLength = 0;
|
||||
std::uint64_t m_offset = 0;
|
||||
std::uint64_t m_position = 0;
|
||||
std::uint64_t m_actingBlockLength = 0;
|
||||
std::uint64_t m_actingVersion = 0;
|
||||
|
||||
inline std::uint64_t *sbePositionPtr() SBE_NOEXCEPT
|
||||
@@ -164,10 +165,10 @@ private:
|
||||
}
|
||||
|
||||
public:
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(52);
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(61);
|
||||
static const std::uint16_t SBE_TEMPLATE_ID = static_cast<std::uint16_t>(528);
|
||||
static const std::uint16_t SBE_SCHEMA_ID = static_cast<std::uint16_t>(8);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(7);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(8);
|
||||
|
||||
enum MetaAttribute
|
||||
{
|
||||
@@ -200,6 +201,7 @@ public:
|
||||
m_bufferLength(bufferLength),
|
||||
m_offset(offset),
|
||||
m_position(sbeCheckPosition(offset + actingBlockLength)),
|
||||
m_actingBlockLength(actingBlockLength),
|
||||
m_actingVersion(actingVersion)
|
||||
{
|
||||
}
|
||||
@@ -220,7 +222,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeBlockLength() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(52);
|
||||
return static_cast<std::uint16_t>(61);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint64_t sbeBlockAndHeaderLength() SBE_NOEXCEPT
|
||||
@@ -240,7 +242,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeSchemaVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(7);
|
||||
return static_cast<std::uint16_t>(8);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR const char *sbeSemanticType() SBE_NOEXCEPT
|
||||
@@ -286,6 +288,11 @@ public:
|
||||
return *this = QuoteCancel528(buffer, offset, bufferLength, actingBlockLength, actingVersion);
|
||||
}
|
||||
|
||||
QuoteCancel528 &sbeRewind()
|
||||
{
|
||||
return wrapForDecode(m_buffer, m_offset, m_actingBlockLength, m_actingVersion, m_bufferLength);
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::uint64_t sbePosition() const SBE_NOEXCEPT
|
||||
{
|
||||
return m_position;
|
||||
@@ -802,7 +809,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
QuoteCancel528 &putSenderID(const std::string& str)
|
||||
QuoteCancel528 &putSenderID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -1008,7 +1015,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
QuoteCancel528 &putLocation(const std::string& str)
|
||||
QuoteCancel528 &putLocation(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 5)
|
||||
@@ -1223,6 +1230,310 @@ public:
|
||||
return *this;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static const char *OrigOrderUserMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
switch (metaAttribute)
|
||||
{
|
||||
case MetaAttribute::SEMANTIC_TYPE: return "String";
|
||||
case MetaAttribute::PRESENCE: return "optional";
|
||||
default: return "";
|
||||
}
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint16_t origOrderUserId() SBE_NOEXCEPT
|
||||
{
|
||||
return 9937;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint64_t origOrderUserSinceVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
SBE_NODISCARD bool origOrderUserInActingVersion() SBE_NOEXCEPT
|
||||
{
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic push
|
||||
#pragma clang diagnostic ignored "-Wtautological-compare"
|
||||
#endif
|
||||
return m_actingVersion >= origOrderUserSinceVersion();
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic pop
|
||||
#endif
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::size_t origOrderUserEncodingOffset() SBE_NOEXCEPT
|
||||
{
|
||||
return 52;
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR char origOrderUserNullValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<char>(0);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR char origOrderUserMinValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<char>(32);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR char origOrderUserMaxValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<char>(126);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::size_t origOrderUserEncodingLength() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint64_t origOrderUserLength() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
SBE_NODISCARD const char *origOrderUser() const SBE_NOEXCEPT
|
||||
{
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
return m_buffer + m_offset + 52;
|
||||
}
|
||||
|
||||
SBE_NODISCARD char *origOrderUser() SBE_NOEXCEPT
|
||||
{
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
return m_buffer + m_offset + 52;
|
||||
}
|
||||
|
||||
SBE_NODISCARD char origOrderUser(const std::uint64_t index) const
|
||||
{
|
||||
if (index >= 8)
|
||||
{
|
||||
throw std::runtime_error("index out of range for origOrderUser [E104]");
|
||||
}
|
||||
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return static_cast<char>(0);
|
||||
}
|
||||
|
||||
char val;
|
||||
std::memcpy(&val, m_buffer + m_offset + 52 + (index * 1), sizeof(char));
|
||||
return (val);
|
||||
}
|
||||
|
||||
QuoteCancel528 &origOrderUser(const std::uint64_t index, const char value)
|
||||
{
|
||||
if (index >= 8)
|
||||
{
|
||||
throw std::runtime_error("index out of range for origOrderUser [E105]");
|
||||
}
|
||||
|
||||
char val = (value);
|
||||
std::memcpy(m_buffer + m_offset + 52 + (index * 1), &val, sizeof(char));
|
||||
return *this;
|
||||
}
|
||||
|
||||
std::uint64_t getOrigOrderUser(char *const dst, const std::uint64_t length) const
|
||||
{
|
||||
if (length > 8)
|
||||
{
|
||||
throw std::runtime_error("length too large for getOrigOrderUser [E106]");
|
||||
}
|
||||
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
std::memcpy(dst, m_buffer + m_offset + 52, sizeof(char) * static_cast<std::size_t>(length));
|
||||
return length;
|
||||
}
|
||||
|
||||
QuoteCancel528 &putOrigOrderUser(const char *const src) SBE_NOEXCEPT
|
||||
{
|
||||
std::memcpy(m_buffer + m_offset + 52, src, sizeof(char) * 8);
|
||||
return *this;
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::string getOrigOrderUserAsString() const
|
||||
{
|
||||
const char *buffer = m_buffer + m_offset + 52;
|
||||
std::size_t length = 0;
|
||||
|
||||
for (; length < 8 && *(buffer + length) != '\0'; ++length);
|
||||
std::string result(buffer, length);
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
std::string getOrigOrderUserAsJsonEscapedString()
|
||||
{
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return std::string("");
|
||||
}
|
||||
|
||||
std::ostringstream oss;
|
||||
std::string s = getOrigOrderUserAsString();
|
||||
|
||||
for (const auto c : s)
|
||||
{
|
||||
switch (c)
|
||||
{
|
||||
case '"': oss << "\\\""; break;
|
||||
case '\\': oss << "\\\\"; break;
|
||||
case '\b': oss << "\\b"; break;
|
||||
case '\f': oss << "\\f"; break;
|
||||
case '\n': oss << "\\n"; break;
|
||||
case '\r': oss << "\\r"; break;
|
||||
case '\t': oss << "\\t"; break;
|
||||
|
||||
default:
|
||||
if ('\x00' <= c && c <= '\x1f')
|
||||
{
|
||||
oss << "\\u" << std::hex << std::setw(4)
|
||||
<< std::setfill('0') << (int)(c);
|
||||
}
|
||||
else
|
||||
{
|
||||
oss << c;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return oss.str();
|
||||
}
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
SBE_NODISCARD std::string_view getOrigOrderUserAsStringView() const SBE_NOEXCEPT
|
||||
{
|
||||
const char *buffer = m_buffer + m_offset + 52;
|
||||
std::size_t length = 0;
|
||||
|
||||
for (; length < 8 && *(buffer + length) != '\0'; ++length);
|
||||
std::string_view result(buffer, length);
|
||||
|
||||
return result;
|
||||
}
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
QuoteCancel528 &putOrigOrderUser(const std::string_view str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 8)
|
||||
{
|
||||
throw std::runtime_error("string too large for putOrigOrderUser [E106]");
|
||||
}
|
||||
|
||||
std::memcpy(m_buffer + m_offset + 52, str.data(), srcLength);
|
||||
for (std::size_t start = srcLength; start < 8; ++start)
|
||||
{
|
||||
m_buffer[m_offset + 52 + start] = 0;
|
||||
}
|
||||
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
QuoteCancel528 &putOrigOrderUser(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 8)
|
||||
{
|
||||
throw std::runtime_error("string too large for putOrigOrderUser [E106]");
|
||||
}
|
||||
|
||||
std::memcpy(m_buffer + m_offset + 52, str.c_str(), srcLength);
|
||||
for (std::size_t start = srcLength; start < 8; ++start)
|
||||
{
|
||||
m_buffer[m_offset + 52 + start] = 0;
|
||||
}
|
||||
|
||||
return *this;
|
||||
}
|
||||
#endif
|
||||
|
||||
SBE_NODISCARD static const char *QuoteEntryOpenMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
switch (metaAttribute)
|
||||
{
|
||||
case MetaAttribute::SEMANTIC_TYPE: return "int";
|
||||
case MetaAttribute::PRESENCE: return "required";
|
||||
default: return "";
|
||||
}
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint16_t quoteEntryOpenId() SBE_NOEXCEPT
|
||||
{
|
||||
return 9182;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint64_t quoteEntryOpenSinceVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
SBE_NODISCARD bool quoteEntryOpenInActingVersion() SBE_NOEXCEPT
|
||||
{
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic push
|
||||
#pragma clang diagnostic ignored "-Wtautological-compare"
|
||||
#endif
|
||||
return m_actingVersion >= quoteEntryOpenSinceVersion();
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic pop
|
||||
#endif
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::size_t quoteEntryOpenEncodingOffset() SBE_NOEXCEPT
|
||||
{
|
||||
return 60;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::size_t quoteEntryOpenEncodingLength() SBE_NOEXCEPT
|
||||
{
|
||||
return 1;
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::uint8_t quoteEntryOpenRaw() const SBE_NOEXCEPT
|
||||
{
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return static_cast<std::uint8_t>(255);
|
||||
}
|
||||
|
||||
std::uint8_t val;
|
||||
std::memcpy(&val, m_buffer + m_offset + 60, sizeof(std::uint8_t));
|
||||
return (val);
|
||||
}
|
||||
|
||||
SBE_NODISCARD BooleanNULL::Value quoteEntryOpen() const
|
||||
{
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return BooleanNULL::NULL_VALUE;
|
||||
}
|
||||
|
||||
std::uint8_t val;
|
||||
std::memcpy(&val, m_buffer + m_offset + 60, sizeof(std::uint8_t));
|
||||
return BooleanNULL::get((val));
|
||||
}
|
||||
|
||||
QuoteCancel528 "eEntryOpen(const BooleanNULL::Value value) SBE_NOEXCEPT
|
||||
{
|
||||
std::uint8_t val = (value);
|
||||
std::memcpy(m_buffer + m_offset + 60, &val, sizeof(std::uint8_t));
|
||||
return *this;
|
||||
}
|
||||
|
||||
class NoQuoteEntries
|
||||
{
|
||||
private:
|
||||
@@ -1349,7 +1660,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
|
||||
inline std::uint64_t resetCountToIndex() SBE_NOEXCEPT
|
||||
inline std::uint64_t resetCountToIndex()
|
||||
{
|
||||
m_count = m_index;
|
||||
GroupSize dimensions(m_buffer, m_initialPosition, m_bufferLength, m_actingVersion);
|
||||
@@ -1357,8 +1668,7 @@ public:
|
||||
return m_count;
|
||||
}
|
||||
|
||||
#if __cplusplus < 201103L
|
||||
template<class Func> inline void forEach(Func& func)
|
||||
template<class Func> inline void forEach(Func &&func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
@@ -1367,17 +1677,6 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
#else
|
||||
template<class Func> inline void forEach(Func&& func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
next();
|
||||
func(*this);
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
SBE_NODISCARD static const char *SecurityGroupMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
@@ -1567,7 +1866,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
NoQuoteEntries &putSecurityGroup(const std::string& str)
|
||||
NoQuoteEntries &putSecurityGroup(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 6)
|
||||
@@ -1657,8 +1956,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, NoQuoteEntries writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, NoQuoteEntries writer)
|
||||
{
|
||||
builder << '{';
|
||||
builder << R"("SecurityGroup": )";
|
||||
@@ -1862,7 +2161,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
|
||||
inline std::uint64_t resetCountToIndex() SBE_NOEXCEPT
|
||||
inline std::uint64_t resetCountToIndex()
|
||||
{
|
||||
m_count = m_index;
|
||||
GroupSize dimensions(m_buffer, m_initialPosition, m_bufferLength, m_actingVersion);
|
||||
@@ -1870,8 +2169,7 @@ public:
|
||||
return m_count;
|
||||
}
|
||||
|
||||
#if __cplusplus < 201103L
|
||||
template<class Func> inline void forEach(Func& func)
|
||||
template<class Func> inline void forEach(Func &&func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
@@ -1880,17 +2178,6 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
#else
|
||||
template<class Func> inline void forEach(Func&& func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
next();
|
||||
func(*this);
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
SBE_NODISCARD static const char *BidSizeMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
@@ -2106,8 +2393,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, NoQuoteSets writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, NoQuoteSets writer)
|
||||
{
|
||||
builder << '{';
|
||||
builder << R"("BidSize": )";
|
||||
@@ -2189,11 +2476,16 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, QuoteCancel528 _writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, QuoteCancel528 _writer)
|
||||
{
|
||||
QuoteCancel528 writer(_writer.m_buffer, _writer.m_offset,
|
||||
_writer.m_bufferLength, _writer.sbeBlockLength(), _writer.m_actingVersion);
|
||||
QuoteCancel528 writer(
|
||||
_writer.m_buffer,
|
||||
_writer.m_offset,
|
||||
_writer.m_bufferLength,
|
||||
_writer.m_actingBlockLength,
|
||||
_writer.m_actingVersion);
|
||||
|
||||
builder << '{';
|
||||
builder << R"("Name": "QuoteCancel528", )";
|
||||
builder << R"("sbeTemplateId": )";
|
||||
@@ -2237,19 +2529,29 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
builder << R"("LiquidityFlag": )";
|
||||
builder << '"' << writer.liquidityFlag() << '"';
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("OrigOrderUser": )";
|
||||
builder << '"' <<
|
||||
writer.getOrigOrderUserAsJsonEscapedString().c_str() << '"';
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("QuoteEntryOpen": )";
|
||||
builder << '"' << writer.quoteEntryOpen() << '"';
|
||||
|
||||
builder << ", ";
|
||||
{
|
||||
bool atLeastOne = false;
|
||||
builder << R"("NoQuoteEntries": [)";
|
||||
writer.noQuoteEntries().forEach([&](NoQuoteEntries& noQuoteEntries)
|
||||
{
|
||||
if (atLeastOne)
|
||||
writer.noQuoteEntries().forEach(
|
||||
[&](NoQuoteEntries &noQuoteEntries)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noQuoteEntries;
|
||||
});
|
||||
if (atLeastOne)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noQuoteEntries;
|
||||
});
|
||||
builder << ']';
|
||||
}
|
||||
|
||||
@@ -2257,15 +2559,16 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
{
|
||||
bool atLeastOne = false;
|
||||
builder << R"("NoQuoteSets": [)";
|
||||
writer.noQuoteSets().forEach([&](NoQuoteSets& noQuoteSets)
|
||||
{
|
||||
if (atLeastOne)
|
||||
writer.noQuoteSets().forEach(
|
||||
[&](NoQuoteSets &noQuoteSets)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noQuoteSets;
|
||||
});
|
||||
if (atLeastOne)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noQuoteSets;
|
||||
});
|
||||
builder << ']';
|
||||
}
|
||||
|
||||
@@ -2276,14 +2579,16 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
|
||||
void skip()
|
||||
{
|
||||
noQuoteEntries().forEach([](NoQuoteEntries e)
|
||||
auto &noQuoteEntriesGroup { noQuoteEntries() };
|
||||
while (noQuoteEntriesGroup.hasNext())
|
||||
{
|
||||
e.skip();
|
||||
});
|
||||
noQuoteSets().forEach([](NoQuoteSets e)
|
||||
noQuoteEntriesGroup.next().skip();
|
||||
}
|
||||
auto &noQuoteSetsGroup { noQuoteSets() };
|
||||
while (noQuoteSetsGroup.hasNext())
|
||||
{
|
||||
e.skip();
|
||||
});
|
||||
noQuoteSetsGroup.next().skip();
|
||||
}
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR bool isConstLength() SBE_NOEXCEPT
|
||||
|
||||
@@ -70,11 +70,11 @@
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (__builtin_expect(exp, c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
@@ -156,6 +156,7 @@ private:
|
||||
std::uint64_t m_bufferLength = 0;
|
||||
std::uint64_t m_offset = 0;
|
||||
std::uint64_t m_position = 0;
|
||||
std::uint64_t m_actingBlockLength = 0;
|
||||
std::uint64_t m_actingVersion = 0;
|
||||
|
||||
inline std::uint64_t *sbePositionPtr() SBE_NOEXCEPT
|
||||
@@ -164,10 +165,10 @@ private:
|
||||
}
|
||||
|
||||
public:
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(351);
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(368);
|
||||
static const std::uint16_t SBE_TEMPLATE_ID = static_cast<std::uint16_t>(563);
|
||||
static const std::uint16_t SBE_SCHEMA_ID = static_cast<std::uint16_t>(8);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(7);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(8);
|
||||
|
||||
enum MetaAttribute
|
||||
{
|
||||
@@ -200,6 +201,7 @@ public:
|
||||
m_bufferLength(bufferLength),
|
||||
m_offset(offset),
|
||||
m_position(sbeCheckPosition(offset + actingBlockLength)),
|
||||
m_actingBlockLength(actingBlockLength),
|
||||
m_actingVersion(actingVersion)
|
||||
{
|
||||
}
|
||||
@@ -220,7 +222,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeBlockLength() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(351);
|
||||
return static_cast<std::uint16_t>(368);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint64_t sbeBlockAndHeaderLength() SBE_NOEXCEPT
|
||||
@@ -240,7 +242,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeSchemaVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(7);
|
||||
return static_cast<std::uint16_t>(8);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR const char *sbeSemanticType() SBE_NOEXCEPT
|
||||
@@ -286,6 +288,11 @@ public:
|
||||
return *this = QuoteCancelAck563(buffer, offset, bufferLength, actingBlockLength, actingVersion);
|
||||
}
|
||||
|
||||
QuoteCancelAck563 &sbeRewind()
|
||||
{
|
||||
return wrapForDecode(m_buffer, m_offset, m_actingBlockLength, m_actingVersion, m_bufferLength);
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::uint64_t sbePosition() const SBE_NOEXCEPT
|
||||
{
|
||||
return m_position;
|
||||
@@ -668,7 +675,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
QuoteCancelAck563 &putText(const std::string& str)
|
||||
QuoteCancelAck563 &putText(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 256)
|
||||
@@ -874,7 +881,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
QuoteCancelAck563 &putSenderID(const std::string& str)
|
||||
QuoteCancelAck563 &putSenderID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -1293,7 +1300,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
QuoteCancelAck563 &putCancelledSymbol(const std::string& str)
|
||||
QuoteCancelAck563 &putCancelledSymbol(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 6)
|
||||
@@ -1499,7 +1506,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
QuoteCancelAck563 &putLocation(const std::string& str)
|
||||
QuoteCancelAck563 &putLocation(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 5)
|
||||
@@ -2392,6 +2399,541 @@ public:
|
||||
return *this;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static const char *OrigOrderUserMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
switch (metaAttribute)
|
||||
{
|
||||
case MetaAttribute::SEMANTIC_TYPE: return "String";
|
||||
case MetaAttribute::PRESENCE: return "optional";
|
||||
default: return "";
|
||||
}
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint16_t origOrderUserId() SBE_NOEXCEPT
|
||||
{
|
||||
return 9937;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint64_t origOrderUserSinceVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
SBE_NODISCARD bool origOrderUserInActingVersion() SBE_NOEXCEPT
|
||||
{
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic push
|
||||
#pragma clang diagnostic ignored "-Wtautological-compare"
|
||||
#endif
|
||||
return m_actingVersion >= origOrderUserSinceVersion();
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic pop
|
||||
#endif
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::size_t origOrderUserEncodingOffset() SBE_NOEXCEPT
|
||||
{
|
||||
return 351;
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR char origOrderUserNullValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<char>(0);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR char origOrderUserMinValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<char>(32);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR char origOrderUserMaxValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<char>(126);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::size_t origOrderUserEncodingLength() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint64_t origOrderUserLength() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
SBE_NODISCARD const char *origOrderUser() const SBE_NOEXCEPT
|
||||
{
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
return m_buffer + m_offset + 351;
|
||||
}
|
||||
|
||||
SBE_NODISCARD char *origOrderUser() SBE_NOEXCEPT
|
||||
{
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
return m_buffer + m_offset + 351;
|
||||
}
|
||||
|
||||
SBE_NODISCARD char origOrderUser(const std::uint64_t index) const
|
||||
{
|
||||
if (index >= 8)
|
||||
{
|
||||
throw std::runtime_error("index out of range for origOrderUser [E104]");
|
||||
}
|
||||
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return static_cast<char>(0);
|
||||
}
|
||||
|
||||
char val;
|
||||
std::memcpy(&val, m_buffer + m_offset + 351 + (index * 1), sizeof(char));
|
||||
return (val);
|
||||
}
|
||||
|
||||
QuoteCancelAck563 &origOrderUser(const std::uint64_t index, const char value)
|
||||
{
|
||||
if (index >= 8)
|
||||
{
|
||||
throw std::runtime_error("index out of range for origOrderUser [E105]");
|
||||
}
|
||||
|
||||
char val = (value);
|
||||
std::memcpy(m_buffer + m_offset + 351 + (index * 1), &val, sizeof(char));
|
||||
return *this;
|
||||
}
|
||||
|
||||
std::uint64_t getOrigOrderUser(char *const dst, const std::uint64_t length) const
|
||||
{
|
||||
if (length > 8)
|
||||
{
|
||||
throw std::runtime_error("length too large for getOrigOrderUser [E106]");
|
||||
}
|
||||
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
std::memcpy(dst, m_buffer + m_offset + 351, sizeof(char) * static_cast<std::size_t>(length));
|
||||
return length;
|
||||
}
|
||||
|
||||
QuoteCancelAck563 &putOrigOrderUser(const char *const src) SBE_NOEXCEPT
|
||||
{
|
||||
std::memcpy(m_buffer + m_offset + 351, src, sizeof(char) * 8);
|
||||
return *this;
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::string getOrigOrderUserAsString() const
|
||||
{
|
||||
const char *buffer = m_buffer + m_offset + 351;
|
||||
std::size_t length = 0;
|
||||
|
||||
for (; length < 8 && *(buffer + length) != '\0'; ++length);
|
||||
std::string result(buffer, length);
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
std::string getOrigOrderUserAsJsonEscapedString()
|
||||
{
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return std::string("");
|
||||
}
|
||||
|
||||
std::ostringstream oss;
|
||||
std::string s = getOrigOrderUserAsString();
|
||||
|
||||
for (const auto c : s)
|
||||
{
|
||||
switch (c)
|
||||
{
|
||||
case '"': oss << "\\\""; break;
|
||||
case '\\': oss << "\\\\"; break;
|
||||
case '\b': oss << "\\b"; break;
|
||||
case '\f': oss << "\\f"; break;
|
||||
case '\n': oss << "\\n"; break;
|
||||
case '\r': oss << "\\r"; break;
|
||||
case '\t': oss << "\\t"; break;
|
||||
|
||||
default:
|
||||
if ('\x00' <= c && c <= '\x1f')
|
||||
{
|
||||
oss << "\\u" << std::hex << std::setw(4)
|
||||
<< std::setfill('0') << (int)(c);
|
||||
}
|
||||
else
|
||||
{
|
||||
oss << c;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return oss.str();
|
||||
}
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
SBE_NODISCARD std::string_view getOrigOrderUserAsStringView() const SBE_NOEXCEPT
|
||||
{
|
||||
const char *buffer = m_buffer + m_offset + 351;
|
||||
std::size_t length = 0;
|
||||
|
||||
for (; length < 8 && *(buffer + length) != '\0'; ++length);
|
||||
std::string_view result(buffer, length);
|
||||
|
||||
return result;
|
||||
}
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
QuoteCancelAck563 &putOrigOrderUser(const std::string_view str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 8)
|
||||
{
|
||||
throw std::runtime_error("string too large for putOrigOrderUser [E106]");
|
||||
}
|
||||
|
||||
std::memcpy(m_buffer + m_offset + 351, str.data(), srcLength);
|
||||
for (std::size_t start = srcLength; start < 8; ++start)
|
||||
{
|
||||
m_buffer[m_offset + 351 + start] = 0;
|
||||
}
|
||||
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
QuoteCancelAck563 &putOrigOrderUser(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 8)
|
||||
{
|
||||
throw std::runtime_error("string too large for putOrigOrderUser [E106]");
|
||||
}
|
||||
|
||||
std::memcpy(m_buffer + m_offset + 351, str.c_str(), srcLength);
|
||||
for (std::size_t start = srcLength; start < 8; ++start)
|
||||
{
|
||||
m_buffer[m_offset + 351 + start] = 0;
|
||||
}
|
||||
|
||||
return *this;
|
||||
}
|
||||
#endif
|
||||
|
||||
SBE_NODISCARD static const char *CancelTextMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
switch (metaAttribute)
|
||||
{
|
||||
case MetaAttribute::SEMANTIC_TYPE: return "String";
|
||||
case MetaAttribute::PRESENCE: return "optional";
|
||||
default: return "";
|
||||
}
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint16_t cancelTextId() SBE_NOEXCEPT
|
||||
{
|
||||
return 2807;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint64_t cancelTextSinceVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
SBE_NODISCARD bool cancelTextInActingVersion() SBE_NOEXCEPT
|
||||
{
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic push
|
||||
#pragma clang diagnostic ignored "-Wtautological-compare"
|
||||
#endif
|
||||
return m_actingVersion >= cancelTextSinceVersion();
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic pop
|
||||
#endif
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::size_t cancelTextEncodingOffset() SBE_NOEXCEPT
|
||||
{
|
||||
return 359;
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR char cancelTextNullValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<char>(0);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR char cancelTextMinValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<char>(32);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR char cancelTextMaxValue() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<char>(126);
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::size_t cancelTextEncodingLength() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint64_t cancelTextLength() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
SBE_NODISCARD const char *cancelText() const SBE_NOEXCEPT
|
||||
{
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
return m_buffer + m_offset + 359;
|
||||
}
|
||||
|
||||
SBE_NODISCARD char *cancelText() SBE_NOEXCEPT
|
||||
{
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
return m_buffer + m_offset + 359;
|
||||
}
|
||||
|
||||
SBE_NODISCARD char cancelText(const std::uint64_t index) const
|
||||
{
|
||||
if (index >= 8)
|
||||
{
|
||||
throw std::runtime_error("index out of range for cancelText [E104]");
|
||||
}
|
||||
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return static_cast<char>(0);
|
||||
}
|
||||
|
||||
char val;
|
||||
std::memcpy(&val, m_buffer + m_offset + 359 + (index * 1), sizeof(char));
|
||||
return (val);
|
||||
}
|
||||
|
||||
QuoteCancelAck563 &cancelText(const std::uint64_t index, const char value)
|
||||
{
|
||||
if (index >= 8)
|
||||
{
|
||||
throw std::runtime_error("index out of range for cancelText [E105]");
|
||||
}
|
||||
|
||||
char val = (value);
|
||||
std::memcpy(m_buffer + m_offset + 359 + (index * 1), &val, sizeof(char));
|
||||
return *this;
|
||||
}
|
||||
|
||||
std::uint64_t getCancelText(char *const dst, const std::uint64_t length) const
|
||||
{
|
||||
if (length > 8)
|
||||
{
|
||||
throw std::runtime_error("length too large for getCancelText [E106]");
|
||||
}
|
||||
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
std::memcpy(dst, m_buffer + m_offset + 359, sizeof(char) * static_cast<std::size_t>(length));
|
||||
return length;
|
||||
}
|
||||
|
||||
QuoteCancelAck563 &putCancelText(const char *const src) SBE_NOEXCEPT
|
||||
{
|
||||
std::memcpy(m_buffer + m_offset + 359, src, sizeof(char) * 8);
|
||||
return *this;
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::string getCancelTextAsString() const
|
||||
{
|
||||
const char *buffer = m_buffer + m_offset + 359;
|
||||
std::size_t length = 0;
|
||||
|
||||
for (; length < 8 && *(buffer + length) != '\0'; ++length);
|
||||
std::string result(buffer, length);
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
std::string getCancelTextAsJsonEscapedString()
|
||||
{
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return std::string("");
|
||||
}
|
||||
|
||||
std::ostringstream oss;
|
||||
std::string s = getCancelTextAsString();
|
||||
|
||||
for (const auto c : s)
|
||||
{
|
||||
switch (c)
|
||||
{
|
||||
case '"': oss << "\\\""; break;
|
||||
case '\\': oss << "\\\\"; break;
|
||||
case '\b': oss << "\\b"; break;
|
||||
case '\f': oss << "\\f"; break;
|
||||
case '\n': oss << "\\n"; break;
|
||||
case '\r': oss << "\\r"; break;
|
||||
case '\t': oss << "\\t"; break;
|
||||
|
||||
default:
|
||||
if ('\x00' <= c && c <= '\x1f')
|
||||
{
|
||||
oss << "\\u" << std::hex << std::setw(4)
|
||||
<< std::setfill('0') << (int)(c);
|
||||
}
|
||||
else
|
||||
{
|
||||
oss << c;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return oss.str();
|
||||
}
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
SBE_NODISCARD std::string_view getCancelTextAsStringView() const SBE_NOEXCEPT
|
||||
{
|
||||
const char *buffer = m_buffer + m_offset + 359;
|
||||
std::size_t length = 0;
|
||||
|
||||
for (; length < 8 && *(buffer + length) != '\0'; ++length);
|
||||
std::string_view result(buffer, length);
|
||||
|
||||
return result;
|
||||
}
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
QuoteCancelAck563 &putCancelText(const std::string_view str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 8)
|
||||
{
|
||||
throw std::runtime_error("string too large for putCancelText [E106]");
|
||||
}
|
||||
|
||||
std::memcpy(m_buffer + m_offset + 359, str.data(), srcLength);
|
||||
for (std::size_t start = srcLength; start < 8; ++start)
|
||||
{
|
||||
m_buffer[m_offset + 359 + start] = 0;
|
||||
}
|
||||
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
QuoteCancelAck563 &putCancelText(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 8)
|
||||
{
|
||||
throw std::runtime_error("string too large for putCancelText [E106]");
|
||||
}
|
||||
|
||||
std::memcpy(m_buffer + m_offset + 359, str.c_str(), srcLength);
|
||||
for (std::size_t start = srcLength; start < 8; ++start)
|
||||
{
|
||||
m_buffer[m_offset + 359 + start] = 0;
|
||||
}
|
||||
|
||||
return *this;
|
||||
}
|
||||
#endif
|
||||
|
||||
SBE_NODISCARD static const char *QuoteEntryOpenMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
switch (metaAttribute)
|
||||
{
|
||||
case MetaAttribute::SEMANTIC_TYPE: return "int";
|
||||
case MetaAttribute::PRESENCE: return "required";
|
||||
default: return "";
|
||||
}
|
||||
}
|
||||
|
||||
static SBE_CONSTEXPR std::uint16_t quoteEntryOpenId() SBE_NOEXCEPT
|
||||
{
|
||||
return 9182;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint64_t quoteEntryOpenSinceVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return 8;
|
||||
}
|
||||
|
||||
SBE_NODISCARD bool quoteEntryOpenInActingVersion() SBE_NOEXCEPT
|
||||
{
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic push
|
||||
#pragma clang diagnostic ignored "-Wtautological-compare"
|
||||
#endif
|
||||
return m_actingVersion >= quoteEntryOpenSinceVersion();
|
||||
#if defined(__clang__)
|
||||
#pragma clang diagnostic pop
|
||||
#endif
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::size_t quoteEntryOpenEncodingOffset() SBE_NOEXCEPT
|
||||
{
|
||||
return 367;
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::size_t quoteEntryOpenEncodingLength() SBE_NOEXCEPT
|
||||
{
|
||||
return 1;
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::uint8_t quoteEntryOpenRaw() const SBE_NOEXCEPT
|
||||
{
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return static_cast<std::uint8_t>(255);
|
||||
}
|
||||
|
||||
std::uint8_t val;
|
||||
std::memcpy(&val, m_buffer + m_offset + 367, sizeof(std::uint8_t));
|
||||
return (val);
|
||||
}
|
||||
|
||||
SBE_NODISCARD BooleanNULL::Value quoteEntryOpen() const
|
||||
{
|
||||
if (m_actingVersion < 8)
|
||||
{
|
||||
return BooleanNULL::NULL_VALUE;
|
||||
}
|
||||
|
||||
std::uint8_t val;
|
||||
std::memcpy(&val, m_buffer + m_offset + 367, sizeof(std::uint8_t));
|
||||
return BooleanNULL::get((val));
|
||||
}
|
||||
|
||||
QuoteCancelAck563 "eEntryOpen(const BooleanNULL::Value value) SBE_NOEXCEPT
|
||||
{
|
||||
std::uint8_t val = (value);
|
||||
std::memcpy(m_buffer + m_offset + 367, &val, sizeof(std::uint8_t));
|
||||
return *this;
|
||||
}
|
||||
|
||||
class NoQuoteEntries
|
||||
{
|
||||
private:
|
||||
@@ -2518,7 +3060,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
|
||||
inline std::uint64_t resetCountToIndex() SBE_NOEXCEPT
|
||||
inline std::uint64_t resetCountToIndex()
|
||||
{
|
||||
m_count = m_index;
|
||||
GroupSize dimensions(m_buffer, m_initialPosition, m_bufferLength, m_actingVersion);
|
||||
@@ -2526,8 +3068,7 @@ public:
|
||||
return m_count;
|
||||
}
|
||||
|
||||
#if __cplusplus < 201103L
|
||||
template<class Func> inline void forEach(Func& func)
|
||||
template<class Func> inline void forEach(Func &&func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
@@ -2536,17 +3077,6 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
#else
|
||||
template<class Func> inline void forEach(Func&& func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
next();
|
||||
func(*this);
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
SBE_NODISCARD static const char *QuoteEntryIDMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
@@ -2762,8 +3292,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, NoQuoteEntries writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, NoQuoteEntries writer)
|
||||
{
|
||||
builder << '{';
|
||||
builder << R"("QuoteEntryID": )";
|
||||
@@ -2970,7 +3500,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
|
||||
inline std::uint64_t resetCountToIndex() SBE_NOEXCEPT
|
||||
inline std::uint64_t resetCountToIndex()
|
||||
{
|
||||
m_count = m_index;
|
||||
GroupSize dimensions(m_buffer, m_initialPosition, m_bufferLength, m_actingVersion);
|
||||
@@ -2978,8 +3508,7 @@ public:
|
||||
return m_count;
|
||||
}
|
||||
|
||||
#if __cplusplus < 201103L
|
||||
template<class Func> inline void forEach(Func& func)
|
||||
template<class Func> inline void forEach(Func &&func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
@@ -2988,17 +3517,6 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
#else
|
||||
template<class Func> inline void forEach(Func&& func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
next();
|
||||
func(*this);
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
SBE_NODISCARD static const char *QuoteSetIDMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
@@ -3143,8 +3661,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, NoQuoteSets writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, NoQuoteSets writer)
|
||||
{
|
||||
builder << '{';
|
||||
builder << R"("QuoteSetID": )";
|
||||
@@ -3222,11 +3740,16 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, QuoteCancelAck563 _writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, QuoteCancelAck563 _writer)
|
||||
{
|
||||
QuoteCancelAck563 writer(_writer.m_buffer, _writer.m_offset,
|
||||
_writer.m_bufferLength, _writer.sbeBlockLength(), _writer.m_actingVersion);
|
||||
QuoteCancelAck563 writer(
|
||||
_writer.m_buffer,
|
||||
_writer.m_offset,
|
||||
_writer.m_bufferLength,
|
||||
_writer.m_actingBlockLength,
|
||||
_writer.m_actingVersion);
|
||||
|
||||
builder << '{';
|
||||
builder << R"("Name": "QuoteCancelAck563", )";
|
||||
builder << R"("sbeTemplateId": )";
|
||||
@@ -3331,19 +3854,34 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
builder << R"("DelayToTime": )";
|
||||
builder << +writer.delayToTime();
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("OrigOrderUser": )";
|
||||
builder << '"' <<
|
||||
writer.getOrigOrderUserAsJsonEscapedString().c_str() << '"';
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("CancelText": )";
|
||||
builder << '"' <<
|
||||
writer.getCancelTextAsJsonEscapedString().c_str() << '"';
|
||||
|
||||
builder << ", ";
|
||||
builder << R"("QuoteEntryOpen": )";
|
||||
builder << '"' << writer.quoteEntryOpen() << '"';
|
||||
|
||||
builder << ", ";
|
||||
{
|
||||
bool atLeastOne = false;
|
||||
builder << R"("NoQuoteEntries": [)";
|
||||
writer.noQuoteEntries().forEach([&](NoQuoteEntries& noQuoteEntries)
|
||||
{
|
||||
if (atLeastOne)
|
||||
writer.noQuoteEntries().forEach(
|
||||
[&](NoQuoteEntries &noQuoteEntries)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noQuoteEntries;
|
||||
});
|
||||
if (atLeastOne)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noQuoteEntries;
|
||||
});
|
||||
builder << ']';
|
||||
}
|
||||
|
||||
@@ -3351,15 +3889,16 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
{
|
||||
bool atLeastOne = false;
|
||||
builder << R"("NoQuoteSets": [)";
|
||||
writer.noQuoteSets().forEach([&](NoQuoteSets& noQuoteSets)
|
||||
{
|
||||
if (atLeastOne)
|
||||
writer.noQuoteSets().forEach(
|
||||
[&](NoQuoteSets &noQuoteSets)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noQuoteSets;
|
||||
});
|
||||
if (atLeastOne)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noQuoteSets;
|
||||
});
|
||||
builder << ']';
|
||||
}
|
||||
|
||||
@@ -3370,14 +3909,16 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
|
||||
void skip()
|
||||
{
|
||||
noQuoteEntries().forEach([](NoQuoteEntries e)
|
||||
auto &noQuoteEntriesGroup { noQuoteEntries() };
|
||||
while (noQuoteEntriesGroup.hasNext())
|
||||
{
|
||||
e.skip();
|
||||
});
|
||||
noQuoteSets().forEach([](NoQuoteSets e)
|
||||
noQuoteEntriesGroup.next().skip();
|
||||
}
|
||||
auto &noQuoteSetsGroup { noQuoteSets() };
|
||||
while (noQuoteSetsGroup.hasNext())
|
||||
{
|
||||
e.skip();
|
||||
});
|
||||
noQuoteSetsGroup.next().skip();
|
||||
}
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR bool isConstLength() SBE_NOEXCEPT
|
||||
|
||||
@@ -2,80 +2,17 @@
|
||||
#ifndef _ILINKBINARY_QUOTECXLSTATUS_H_
|
||||
#define _ILINKBINARY_QUOTECXLSTATUS_H_
|
||||
|
||||
#if defined(SBE_HAVE_CMATH)
|
||||
/* cmath needed for std::numeric_limits<double>::quiet_NaN() */
|
||||
# include <cmath>
|
||||
# define SBE_FLOAT_NAN std::numeric_limits<float>::quiet_NaN()
|
||||
# define SBE_DOUBLE_NAN std::numeric_limits<double>::quiet_NaN()
|
||||
#else
|
||||
/* math.h needed for NAN */
|
||||
# include <math.h>
|
||||
# define SBE_FLOAT_NAN NAN
|
||||
# define SBE_DOUBLE_NAN NAN
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201103L
|
||||
# define SBE_CONSTEXPR constexpr
|
||||
# define SBE_NOEXCEPT noexcept
|
||||
#else
|
||||
# define SBE_CONSTEXPR
|
||||
# define SBE_NOEXCEPT
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
# include <string_view>
|
||||
# define SBE_NODISCARD [[nodiscard]]
|
||||
#else
|
||||
# define SBE_NODISCARD
|
||||
#endif
|
||||
|
||||
#if !defined(__STDC_LIMIT_MACROS)
|
||||
# define __STDC_LIMIT_MACROS 1
|
||||
#endif
|
||||
|
||||
#include <cstdint>
|
||||
#include <cstring>
|
||||
#include <iomanip>
|
||||
#include <limits>
|
||||
#include <ostream>
|
||||
#include <stdexcept>
|
||||
#include <sstream>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <tuple>
|
||||
|
||||
#if defined(WIN32) || defined(_WIN32)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) _byteswap_ushort(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) _byteswap_ulong(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) _byteswap_uint64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) (v)
|
||||
#else
|
||||
# error "Byte Ordering of platform not determined. Set __BYTE_ORDER__ manually before including this file."
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
#define SBE_NULLVALUE_INT16 (std::numeric_limits<std::int16_t>::min)()
|
||||
@@ -86,7 +23,6 @@
|
||||
#define SBE_NULLVALUE_UINT32 (std::numeric_limits<std::uint32_t>::max)()
|
||||
#define SBE_NULLVALUE_UINT64 (std::numeric_limits<std::uint64_t>::max)()
|
||||
|
||||
|
||||
namespace iLinkBinary {
|
||||
|
||||
class QuoteCxlStatus
|
||||
@@ -133,8 +69,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& os, QuoteCxlStatus::Value m)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &os, QuoteCxlStatus::Value m)
|
||||
{
|
||||
return os << QuoteCxlStatus::c_str(m);
|
||||
}
|
||||
|
||||
@@ -2,80 +2,17 @@
|
||||
#ifndef _ILINKBINARY_QUOTECXLTYP_H_
|
||||
#define _ILINKBINARY_QUOTECXLTYP_H_
|
||||
|
||||
#if defined(SBE_HAVE_CMATH)
|
||||
/* cmath needed for std::numeric_limits<double>::quiet_NaN() */
|
||||
# include <cmath>
|
||||
# define SBE_FLOAT_NAN std::numeric_limits<float>::quiet_NaN()
|
||||
# define SBE_DOUBLE_NAN std::numeric_limits<double>::quiet_NaN()
|
||||
#else
|
||||
/* math.h needed for NAN */
|
||||
# include <math.h>
|
||||
# define SBE_FLOAT_NAN NAN
|
||||
# define SBE_DOUBLE_NAN NAN
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201103L
|
||||
# define SBE_CONSTEXPR constexpr
|
||||
# define SBE_NOEXCEPT noexcept
|
||||
#else
|
||||
# define SBE_CONSTEXPR
|
||||
# define SBE_NOEXCEPT
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
# include <string_view>
|
||||
# define SBE_NODISCARD [[nodiscard]]
|
||||
#else
|
||||
# define SBE_NODISCARD
|
||||
#endif
|
||||
|
||||
#if !defined(__STDC_LIMIT_MACROS)
|
||||
# define __STDC_LIMIT_MACROS 1
|
||||
#endif
|
||||
|
||||
#include <cstdint>
|
||||
#include <cstring>
|
||||
#include <iomanip>
|
||||
#include <limits>
|
||||
#include <ostream>
|
||||
#include <stdexcept>
|
||||
#include <sstream>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <tuple>
|
||||
|
||||
#if defined(WIN32) || defined(_WIN32)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) _byteswap_ushort(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) _byteswap_ulong(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) _byteswap_uint64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) (v)
|
||||
#else
|
||||
# error "Byte Ordering of platform not determined. Set __BYTE_ORDER__ manually before including this file."
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
#define SBE_NULLVALUE_INT16 (std::numeric_limits<std::int16_t>::min)()
|
||||
@@ -86,7 +23,6 @@
|
||||
#define SBE_NULLVALUE_UINT32 (std::numeric_limits<std::uint32_t>::max)()
|
||||
#define SBE_NULLVALUE_UINT64 (std::numeric_limits<std::uint64_t>::max)()
|
||||
|
||||
|
||||
namespace iLinkBinary {
|
||||
|
||||
class QuoteCxlTyp
|
||||
@@ -130,8 +66,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& os, QuoteCxlTyp::Value m)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &os, QuoteCxlTyp::Value m)
|
||||
{
|
||||
return os << QuoteCxlTyp::c_str(m);
|
||||
}
|
||||
|
||||
@@ -2,80 +2,17 @@
|
||||
#ifndef _ILINKBINARY_QUOTETYP_H_
|
||||
#define _ILINKBINARY_QUOTETYP_H_
|
||||
|
||||
#if defined(SBE_HAVE_CMATH)
|
||||
/* cmath needed for std::numeric_limits<double>::quiet_NaN() */
|
||||
# include <cmath>
|
||||
# define SBE_FLOAT_NAN std::numeric_limits<float>::quiet_NaN()
|
||||
# define SBE_DOUBLE_NAN std::numeric_limits<double>::quiet_NaN()
|
||||
#else
|
||||
/* math.h needed for NAN */
|
||||
# include <math.h>
|
||||
# define SBE_FLOAT_NAN NAN
|
||||
# define SBE_DOUBLE_NAN NAN
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201103L
|
||||
# define SBE_CONSTEXPR constexpr
|
||||
# define SBE_NOEXCEPT noexcept
|
||||
#else
|
||||
# define SBE_CONSTEXPR
|
||||
# define SBE_NOEXCEPT
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
# include <string_view>
|
||||
# define SBE_NODISCARD [[nodiscard]]
|
||||
#else
|
||||
# define SBE_NODISCARD
|
||||
#endif
|
||||
|
||||
#if !defined(__STDC_LIMIT_MACROS)
|
||||
# define __STDC_LIMIT_MACROS 1
|
||||
#endif
|
||||
|
||||
#include <cstdint>
|
||||
#include <cstring>
|
||||
#include <iomanip>
|
||||
#include <limits>
|
||||
#include <ostream>
|
||||
#include <stdexcept>
|
||||
#include <sstream>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <tuple>
|
||||
|
||||
#if defined(WIN32) || defined(_WIN32)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) _byteswap_ushort(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) _byteswap_ulong(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) _byteswap_uint64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) (v)
|
||||
#else
|
||||
# error "Byte Ordering of platform not determined. Set __BYTE_ORDER__ manually before including this file."
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
#define SBE_NULLVALUE_INT16 (std::numeric_limits<std::int16_t>::min)()
|
||||
@@ -86,7 +23,6 @@
|
||||
#define SBE_NULLVALUE_UINT32 (std::numeric_limits<std::uint32_t>::max)()
|
||||
#define SBE_NULLVALUE_UINT64 (std::numeric_limits<std::uint64_t>::max)()
|
||||
|
||||
|
||||
namespace iLinkBinary {
|
||||
|
||||
class QuoteTyp
|
||||
@@ -121,8 +57,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& os, QuoteTyp::Value m)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &os, QuoteTyp::Value m)
|
||||
{
|
||||
return os << QuoteTyp::c_str(m);
|
||||
}
|
||||
|
||||
@@ -1,13 +1,11 @@
|
||||
To update ilinkbinary.xml
|
||||
sftp cmeconfig@sftpng.cmegroup.com
|
||||
password: G3t(0nnect3d
|
||||
get /MSGW/NRCert/Templates/ilinkbinary.xml
|
||||
|
||||
To generate:
|
||||
|
||||
Download sbe-all-[version].jar from sbe-logic github releases.
|
||||
|
||||
docker run --rm -it -w /work -v $PWD:/work java java -Dsbe.output.dir=/work -Dsbe.generate.ir="false" -Dsbe.target.language=cpp -jar sbe-all-1.16.1.jar ilinkbinary.xml
|
||||
#docker run --rm -it -w /work -v $PWD:/work java java -Dsbe.output.dir=/work -Dsbe.generate.ir="false" -Dsbe.target.language=uk.co.real_logic.sbe.generation.rust.Rust -jar sbe-all-1.16.1.jar ilinkbinary.xml
|
||||
|
||||
|
||||
To update ilinkbinary.xml
|
||||
sftp cmeconfig@sftpng.cmegroup.com
|
||||
password: G3t(0nnect3d
|
||||
get /MSGW/NRCert/Templates/ilinkbinary.xml
|
||||
|
||||
To generate:
|
||||
|
||||
Download sbe-all-[version].jar from sbe-logic github releases.
|
||||
|
||||
docker run --rm -it -w /work -v $PWD:/work eclipse-temurin:17-jdk-jammy java -Dsbe.output.dir=/work -Dsbe.generate.ir="false" -Dsbe.target.language=cpp -jar sbe-all-1.27.0.jar ilinkbinary.xml
|
||||
|
||||
@@ -2,80 +2,17 @@
|
||||
#ifndef _ILINKBINARY_RFQSIDE_H_
|
||||
#define _ILINKBINARY_RFQSIDE_H_
|
||||
|
||||
#if defined(SBE_HAVE_CMATH)
|
||||
/* cmath needed for std::numeric_limits<double>::quiet_NaN() */
|
||||
# include <cmath>
|
||||
# define SBE_FLOAT_NAN std::numeric_limits<float>::quiet_NaN()
|
||||
# define SBE_DOUBLE_NAN std::numeric_limits<double>::quiet_NaN()
|
||||
#else
|
||||
/* math.h needed for NAN */
|
||||
# include <math.h>
|
||||
# define SBE_FLOAT_NAN NAN
|
||||
# define SBE_DOUBLE_NAN NAN
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201103L
|
||||
# define SBE_CONSTEXPR constexpr
|
||||
# define SBE_NOEXCEPT noexcept
|
||||
#else
|
||||
# define SBE_CONSTEXPR
|
||||
# define SBE_NOEXCEPT
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
# include <string_view>
|
||||
# define SBE_NODISCARD [[nodiscard]]
|
||||
#else
|
||||
# define SBE_NODISCARD
|
||||
#endif
|
||||
|
||||
#if !defined(__STDC_LIMIT_MACROS)
|
||||
# define __STDC_LIMIT_MACROS 1
|
||||
#endif
|
||||
|
||||
#include <cstdint>
|
||||
#include <cstring>
|
||||
#include <iomanip>
|
||||
#include <limits>
|
||||
#include <ostream>
|
||||
#include <stdexcept>
|
||||
#include <sstream>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <tuple>
|
||||
|
||||
#if defined(WIN32) || defined(_WIN32)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) _byteswap_ushort(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) _byteswap_ulong(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) _byteswap_uint64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) (v)
|
||||
#else
|
||||
# error "Byte Ordering of platform not determined. Set __BYTE_ORDER__ manually before including this file."
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
#define SBE_NULLVALUE_INT16 (std::numeric_limits<std::int16_t>::min)()
|
||||
@@ -86,7 +23,6 @@
|
||||
#define SBE_NULLVALUE_UINT32 (std::numeric_limits<std::uint32_t>::max)()
|
||||
#define SBE_NULLVALUE_UINT64 (std::numeric_limits<std::uint64_t>::max)()
|
||||
|
||||
|
||||
namespace iLinkBinary {
|
||||
|
||||
class RFQSide
|
||||
@@ -127,8 +63,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& os, RFQSide::Value m)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &os, RFQSide::Value m)
|
||||
{
|
||||
return os << RFQSide::c_str(m);
|
||||
}
|
||||
|
||||
@@ -2,80 +2,17 @@
|
||||
#ifndef _ILINKBINARY_REQRESULT_H_
|
||||
#define _ILINKBINARY_REQRESULT_H_
|
||||
|
||||
#if defined(SBE_HAVE_CMATH)
|
||||
/* cmath needed for std::numeric_limits<double>::quiet_NaN() */
|
||||
# include <cmath>
|
||||
# define SBE_FLOAT_NAN std::numeric_limits<float>::quiet_NaN()
|
||||
# define SBE_DOUBLE_NAN std::numeric_limits<double>::quiet_NaN()
|
||||
#else
|
||||
/* math.h needed for NAN */
|
||||
# include <math.h>
|
||||
# define SBE_FLOAT_NAN NAN
|
||||
# define SBE_DOUBLE_NAN NAN
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201103L
|
||||
# define SBE_CONSTEXPR constexpr
|
||||
# define SBE_NOEXCEPT noexcept
|
||||
#else
|
||||
# define SBE_CONSTEXPR
|
||||
# define SBE_NOEXCEPT
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
# include <string_view>
|
||||
# define SBE_NODISCARD [[nodiscard]]
|
||||
#else
|
||||
# define SBE_NODISCARD
|
||||
#endif
|
||||
|
||||
#if !defined(__STDC_LIMIT_MACROS)
|
||||
# define __STDC_LIMIT_MACROS 1
|
||||
#endif
|
||||
|
||||
#include <cstdint>
|
||||
#include <cstring>
|
||||
#include <iomanip>
|
||||
#include <limits>
|
||||
#include <ostream>
|
||||
#include <stdexcept>
|
||||
#include <sstream>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <tuple>
|
||||
|
||||
#if defined(WIN32) || defined(_WIN32)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) _byteswap_ushort(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) _byteswap_ulong(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) _byteswap_uint64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) (v)
|
||||
#else
|
||||
# error "Byte Ordering of platform not determined. Set __BYTE_ORDER__ manually before including this file."
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
#define SBE_NULLVALUE_INT16 (std::numeric_limits<std::int16_t>::min)()
|
||||
@@ -86,7 +23,6 @@
|
||||
#define SBE_NULLVALUE_UINT32 (std::numeric_limits<std::uint32_t>::max)()
|
||||
#define SBE_NULLVALUE_UINT64 (std::numeric_limits<std::uint64_t>::max)()
|
||||
|
||||
|
||||
namespace iLinkBinary {
|
||||
|
||||
class ReqResult
|
||||
@@ -130,8 +66,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& os, ReqResult::Value m)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &os, ReqResult::Value m)
|
||||
{
|
||||
return os << ReqResult::c_str(m);
|
||||
}
|
||||
|
||||
@@ -70,11 +70,11 @@
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (__builtin_expect(exp, c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
@@ -156,6 +156,7 @@ private:
|
||||
std::uint64_t m_bufferLength = 0;
|
||||
std::uint64_t m_offset = 0;
|
||||
std::uint64_t m_position = 0;
|
||||
std::uint64_t m_actingBlockLength = 0;
|
||||
std::uint64_t m_actingVersion = 0;
|
||||
|
||||
inline std::uint64_t *sbePositionPtr() SBE_NOEXCEPT
|
||||
@@ -167,7 +168,7 @@ public:
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(55);
|
||||
static const std::uint16_t SBE_TEMPLATE_ID = static_cast<std::uint16_t>(543);
|
||||
static const std::uint16_t SBE_SCHEMA_ID = static_cast<std::uint16_t>(8);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(7);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(8);
|
||||
|
||||
enum MetaAttribute
|
||||
{
|
||||
@@ -200,6 +201,7 @@ public:
|
||||
m_bufferLength(bufferLength),
|
||||
m_offset(offset),
|
||||
m_position(sbeCheckPosition(offset + actingBlockLength)),
|
||||
m_actingBlockLength(actingBlockLength),
|
||||
m_actingVersion(actingVersion)
|
||||
{
|
||||
}
|
||||
@@ -240,7 +242,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeSchemaVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(7);
|
||||
return static_cast<std::uint16_t>(8);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR const char *sbeSemanticType() SBE_NOEXCEPT
|
||||
@@ -286,6 +288,11 @@ public:
|
||||
return *this = RequestForQuote543(buffer, offset, bufferLength, actingBlockLength, actingVersion);
|
||||
}
|
||||
|
||||
RequestForQuote543 &sbeRewind()
|
||||
{
|
||||
return wrapForDecode(m_buffer, m_offset, m_actingBlockLength, m_actingVersion, m_bufferLength);
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::uint64_t sbePosition() const SBE_NOEXCEPT
|
||||
{
|
||||
return m_position;
|
||||
@@ -802,7 +809,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
RequestForQuote543 &putSenderID(const std::string& str)
|
||||
RequestForQuote543 &putSenderID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -1079,7 +1086,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
RequestForQuote543 &putLocation(const std::string& str)
|
||||
RequestForQuote543 &putLocation(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 5)
|
||||
@@ -1286,7 +1293,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
|
||||
inline std::uint64_t resetCountToIndex() SBE_NOEXCEPT
|
||||
inline std::uint64_t resetCountToIndex()
|
||||
{
|
||||
m_count = m_index;
|
||||
GroupSize dimensions(m_buffer, m_initialPosition, m_bufferLength, m_actingVersion);
|
||||
@@ -1294,8 +1301,7 @@ public:
|
||||
return m_count;
|
||||
}
|
||||
|
||||
#if __cplusplus < 201103L
|
||||
template<class Func> inline void forEach(Func& func)
|
||||
template<class Func> inline void forEach(Func &&func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
@@ -1304,17 +1310,6 @@ public:
|
||||
}
|
||||
}
|
||||
|
||||
#else
|
||||
template<class Func> inline void forEach(Func&& func)
|
||||
{
|
||||
while (hasNext())
|
||||
{
|
||||
next();
|
||||
func(*this);
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
SBE_NODISCARD static const char *SecurityIDMetaAttribute(const MetaAttribute metaAttribute) SBE_NOEXCEPT
|
||||
{
|
||||
@@ -1522,8 +1517,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, NoRelatedSym writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, NoRelatedSym writer)
|
||||
{
|
||||
builder << '{';
|
||||
builder << R"("SecurityID": )";
|
||||
@@ -1605,11 +1600,16 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, RequestForQuote543 _writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, RequestForQuote543 _writer)
|
||||
{
|
||||
RequestForQuote543 writer(_writer.m_buffer, _writer.m_offset,
|
||||
_writer.m_bufferLength, _writer.sbeBlockLength(), _writer.m_actingVersion);
|
||||
RequestForQuote543 writer(
|
||||
_writer.m_buffer,
|
||||
_writer.m_offset,
|
||||
_writer.m_bufferLength,
|
||||
_writer.m_actingBlockLength,
|
||||
_writer.m_actingVersion);
|
||||
|
||||
builder << '{';
|
||||
builder << R"("Name": "RequestForQuote543", )";
|
||||
builder << R"("sbeTemplateId": )";
|
||||
@@ -1653,15 +1653,16 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
{
|
||||
bool atLeastOne = false;
|
||||
builder << R"("NoRelatedSym": [)";
|
||||
writer.noRelatedSym().forEach([&](NoRelatedSym& noRelatedSym)
|
||||
{
|
||||
if (atLeastOne)
|
||||
writer.noRelatedSym().forEach(
|
||||
[&](NoRelatedSym &noRelatedSym)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noRelatedSym;
|
||||
});
|
||||
if (atLeastOne)
|
||||
{
|
||||
builder << ", ";
|
||||
}
|
||||
atLeastOne = true;
|
||||
builder << noRelatedSym;
|
||||
});
|
||||
builder << ']';
|
||||
}
|
||||
|
||||
@@ -1672,10 +1673,11 @@ friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
|
||||
void skip()
|
||||
{
|
||||
noRelatedSym().forEach([](NoRelatedSym e)
|
||||
auto &noRelatedSymGroup { noRelatedSym() };
|
||||
while (noRelatedSymGroup.hasNext())
|
||||
{
|
||||
e.skip();
|
||||
});
|
||||
noRelatedSymGroup.next().skip();
|
||||
}
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR bool isConstLength() SBE_NOEXCEPT
|
||||
|
||||
@@ -70,11 +70,11 @@
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (__builtin_expect(exp, c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
@@ -156,6 +156,7 @@ private:
|
||||
std::uint64_t m_bufferLength = 0;
|
||||
std::uint64_t m_offset = 0;
|
||||
std::uint64_t m_position = 0;
|
||||
std::uint64_t m_actingBlockLength = 0;
|
||||
std::uint64_t m_actingVersion = 0;
|
||||
|
||||
inline std::uint64_t *sbePositionPtr() SBE_NOEXCEPT
|
||||
@@ -167,7 +168,7 @@ public:
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(358);
|
||||
static const std::uint16_t SBE_TEMPLATE_ID = static_cast<std::uint16_t>(546);
|
||||
static const std::uint16_t SBE_SCHEMA_ID = static_cast<std::uint16_t>(8);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(7);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(8);
|
||||
|
||||
enum MetaAttribute
|
||||
{
|
||||
@@ -200,6 +201,7 @@ public:
|
||||
m_bufferLength(bufferLength),
|
||||
m_offset(offset),
|
||||
m_position(sbeCheckPosition(offset + actingBlockLength)),
|
||||
m_actingBlockLength(actingBlockLength),
|
||||
m_actingVersion(actingVersion)
|
||||
{
|
||||
}
|
||||
@@ -240,7 +242,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeSchemaVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(7);
|
||||
return static_cast<std::uint16_t>(8);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR const char *sbeSemanticType() SBE_NOEXCEPT
|
||||
@@ -286,6 +288,11 @@ public:
|
||||
return *this = RequestForQuoteAck546(buffer, offset, bufferLength, actingBlockLength, actingVersion);
|
||||
}
|
||||
|
||||
RequestForQuoteAck546 &sbeRewind()
|
||||
{
|
||||
return wrapForDecode(m_buffer, m_offset, m_actingBlockLength, m_actingVersion, m_bufferLength);
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::uint64_t sbePosition() const SBE_NOEXCEPT
|
||||
{
|
||||
return m_position;
|
||||
@@ -668,7 +675,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
RequestForQuoteAck546 &putText(const std::string& str)
|
||||
RequestForQuoteAck546 &putText(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 256)
|
||||
@@ -874,7 +881,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
RequestForQuoteAck546 &putSenderID(const std::string& str)
|
||||
RequestForQuoteAck546 &putSenderID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 20)
|
||||
@@ -1080,7 +1087,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
RequestForQuoteAck546 &putExchangeQuoteReqID(const std::string& str)
|
||||
RequestForQuoteAck546 &putExchangeQuoteReqID(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 17)
|
||||
@@ -1570,7 +1577,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
RequestForQuoteAck546 &putLocation(const std::string& str)
|
||||
RequestForQuoteAck546 &putLocation(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 5)
|
||||
@@ -2069,11 +2076,16 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, RequestForQuoteAck546 _writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, RequestForQuoteAck546 _writer)
|
||||
{
|
||||
RequestForQuoteAck546 writer(_writer.m_buffer, _writer.m_offset,
|
||||
_writer.m_bufferLength, _writer.sbeBlockLength(), _writer.m_actingVersion);
|
||||
RequestForQuoteAck546 writer(
|
||||
_writer.m_buffer,
|
||||
_writer.m_offset,
|
||||
_writer.m_bufferLength,
|
||||
_writer.m_actingBlockLength,
|
||||
_writer.m_actingVersion);
|
||||
|
||||
builder << '{';
|
||||
builder << R"("Name": "RequestForQuoteAck546", )";
|
||||
builder << R"("sbeTemplateId": )";
|
||||
|
||||
@@ -70,11 +70,11 @@
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (__builtin_expect(exp, c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
@@ -156,6 +156,7 @@ private:
|
||||
std::uint64_t m_bufferLength = 0;
|
||||
std::uint64_t m_offset = 0;
|
||||
std::uint64_t m_position = 0;
|
||||
std::uint64_t m_actingBlockLength = 0;
|
||||
std::uint64_t m_actingVersion = 0;
|
||||
|
||||
inline std::uint64_t *sbePositionPtr() SBE_NOEXCEPT
|
||||
@@ -167,7 +168,7 @@ public:
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(31);
|
||||
static const std::uint16_t SBE_TEMPLATE_ID = static_cast<std::uint16_t>(509);
|
||||
static const std::uint16_t SBE_SCHEMA_ID = static_cast<std::uint16_t>(8);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(7);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(8);
|
||||
|
||||
enum MetaAttribute
|
||||
{
|
||||
@@ -200,6 +201,7 @@ public:
|
||||
m_bufferLength(bufferLength),
|
||||
m_offset(offset),
|
||||
m_position(sbeCheckPosition(offset + actingBlockLength)),
|
||||
m_actingBlockLength(actingBlockLength),
|
||||
m_actingVersion(actingVersion)
|
||||
{
|
||||
}
|
||||
@@ -240,7 +242,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeSchemaVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(7);
|
||||
return static_cast<std::uint16_t>(8);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR const char *sbeSemanticType() SBE_NOEXCEPT
|
||||
@@ -286,6 +288,11 @@ public:
|
||||
return *this = Retransmission509(buffer, offset, bufferLength, actingBlockLength, actingVersion);
|
||||
}
|
||||
|
||||
Retransmission509 &sbeRewind()
|
||||
{
|
||||
return wrapForDecode(m_buffer, m_offset, m_actingBlockLength, m_actingVersion, m_bufferLength);
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::uint64_t sbePosition() const SBE_NOEXCEPT
|
||||
{
|
||||
return m_position;
|
||||
@@ -757,11 +764,16 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, Retransmission509 _writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, Retransmission509 _writer)
|
||||
{
|
||||
Retransmission509 writer(_writer.m_buffer, _writer.m_offset,
|
||||
_writer.m_bufferLength, _writer.sbeBlockLength(), _writer.m_actingVersion);
|
||||
Retransmission509 writer(
|
||||
_writer.m_buffer,
|
||||
_writer.m_offset,
|
||||
_writer.m_bufferLength,
|
||||
_writer.m_actingBlockLength,
|
||||
_writer.m_actingVersion);
|
||||
|
||||
builder << '{';
|
||||
builder << R"("Name": "Retransmission509", )";
|
||||
builder << R"("sbeTemplateId": )";
|
||||
|
||||
@@ -70,11 +70,11 @@
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (__builtin_expect(exp, c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
@@ -156,6 +156,7 @@ private:
|
||||
std::uint64_t m_bufferLength = 0;
|
||||
std::uint64_t m_offset = 0;
|
||||
std::uint64_t m_position = 0;
|
||||
std::uint64_t m_actingBlockLength = 0;
|
||||
std::uint64_t m_actingVersion = 0;
|
||||
|
||||
inline std::uint64_t *sbePositionPtr() SBE_NOEXCEPT
|
||||
@@ -167,7 +168,7 @@ public:
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(75);
|
||||
static const std::uint16_t SBE_TEMPLATE_ID = static_cast<std::uint16_t>(510);
|
||||
static const std::uint16_t SBE_SCHEMA_ID = static_cast<std::uint16_t>(8);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(7);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(8);
|
||||
|
||||
enum MetaAttribute
|
||||
{
|
||||
@@ -200,6 +201,7 @@ public:
|
||||
m_bufferLength(bufferLength),
|
||||
m_offset(offset),
|
||||
m_position(sbeCheckPosition(offset + actingBlockLength)),
|
||||
m_actingBlockLength(actingBlockLength),
|
||||
m_actingVersion(actingVersion)
|
||||
{
|
||||
}
|
||||
@@ -240,7 +242,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeSchemaVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(7);
|
||||
return static_cast<std::uint16_t>(8);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR const char *sbeSemanticType() SBE_NOEXCEPT
|
||||
@@ -286,6 +288,11 @@ public:
|
||||
return *this = RetransmitReject510(buffer, offset, bufferLength, actingBlockLength, actingVersion);
|
||||
}
|
||||
|
||||
RetransmitReject510 &sbeRewind()
|
||||
{
|
||||
return wrapForDecode(m_buffer, m_offset, m_actingBlockLength, m_actingVersion, m_bufferLength);
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::uint64_t sbePosition() const SBE_NOEXCEPT
|
||||
{
|
||||
return m_position;
|
||||
@@ -526,7 +533,7 @@ public:
|
||||
return *this;
|
||||
}
|
||||
#else
|
||||
RetransmitReject510 &putReason(const std::string& str)
|
||||
RetransmitReject510 &putReason(const std::string &str)
|
||||
{
|
||||
const std::size_t srcLength = str.length();
|
||||
if (srcLength > 48)
|
||||
@@ -892,11 +899,16 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, RetransmitReject510 _writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, RetransmitReject510 _writer)
|
||||
{
|
||||
RetransmitReject510 writer(_writer.m_buffer, _writer.m_offset,
|
||||
_writer.m_bufferLength, _writer.sbeBlockLength(), _writer.m_actingVersion);
|
||||
RetransmitReject510 writer(
|
||||
_writer.m_buffer,
|
||||
_writer.m_offset,
|
||||
_writer.m_bufferLength,
|
||||
_writer.m_actingBlockLength,
|
||||
_writer.m_actingVersion);
|
||||
|
||||
builder << '{';
|
||||
builder << R"("Name": "RetransmitReject510", )";
|
||||
builder << R"("sbeTemplateId": )";
|
||||
|
||||
@@ -70,11 +70,11 @@
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp, c) (__builtin_expect(exp, c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
@@ -156,6 +156,7 @@ private:
|
||||
std::uint64_t m_bufferLength = 0;
|
||||
std::uint64_t m_offset = 0;
|
||||
std::uint64_t m_position = 0;
|
||||
std::uint64_t m_actingBlockLength = 0;
|
||||
std::uint64_t m_actingVersion = 0;
|
||||
|
||||
inline std::uint64_t *sbePositionPtr() SBE_NOEXCEPT
|
||||
@@ -167,7 +168,7 @@ public:
|
||||
static const std::uint16_t SBE_BLOCK_LENGTH = static_cast<std::uint16_t>(30);
|
||||
static const std::uint16_t SBE_TEMPLATE_ID = static_cast<std::uint16_t>(508);
|
||||
static const std::uint16_t SBE_SCHEMA_ID = static_cast<std::uint16_t>(8);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(7);
|
||||
static const std::uint16_t SBE_SCHEMA_VERSION = static_cast<std::uint16_t>(8);
|
||||
|
||||
enum MetaAttribute
|
||||
{
|
||||
@@ -200,6 +201,7 @@ public:
|
||||
m_bufferLength(bufferLength),
|
||||
m_offset(offset),
|
||||
m_position(sbeCheckPosition(offset + actingBlockLength)),
|
||||
m_actingBlockLength(actingBlockLength),
|
||||
m_actingVersion(actingVersion)
|
||||
{
|
||||
}
|
||||
@@ -240,7 +242,7 @@ public:
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR std::uint16_t sbeSchemaVersion() SBE_NOEXCEPT
|
||||
{
|
||||
return static_cast<std::uint16_t>(7);
|
||||
return static_cast<std::uint16_t>(8);
|
||||
}
|
||||
|
||||
SBE_NODISCARD static SBE_CONSTEXPR const char *sbeSemanticType() SBE_NOEXCEPT
|
||||
@@ -286,6 +288,11 @@ public:
|
||||
return *this = RetransmitRequest508(buffer, offset, bufferLength, actingBlockLength, actingVersion);
|
||||
}
|
||||
|
||||
RetransmitRequest508 &sbeRewind()
|
||||
{
|
||||
return wrapForDecode(m_buffer, m_offset, m_actingBlockLength, m_actingVersion, m_bufferLength);
|
||||
}
|
||||
|
||||
SBE_NODISCARD std::uint64_t sbePosition() const SBE_NOEXCEPT
|
||||
{
|
||||
return m_position;
|
||||
@@ -694,11 +701,16 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& builder, RetransmitRequest508 _writer)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &builder, RetransmitRequest508 _writer)
|
||||
{
|
||||
RetransmitRequest508 writer(_writer.m_buffer, _writer.m_offset,
|
||||
_writer.m_bufferLength, _writer.sbeBlockLength(), _writer.m_actingVersion);
|
||||
RetransmitRequest508 writer(
|
||||
_writer.m_buffer,
|
||||
_writer.m_offset,
|
||||
_writer.m_bufferLength,
|
||||
_writer.m_actingBlockLength,
|
||||
_writer.m_actingVersion);
|
||||
|
||||
builder << '{';
|
||||
builder << R"("Name": "RetransmitRequest508", )";
|
||||
builder << R"("sbeTemplateId": )";
|
||||
|
||||
@@ -2,80 +2,17 @@
|
||||
#ifndef _ILINKBINARY_SLEDS_H_
|
||||
#define _ILINKBINARY_SLEDS_H_
|
||||
|
||||
#if defined(SBE_HAVE_CMATH)
|
||||
/* cmath needed for std::numeric_limits<double>::quiet_NaN() */
|
||||
# include <cmath>
|
||||
# define SBE_FLOAT_NAN std::numeric_limits<float>::quiet_NaN()
|
||||
# define SBE_DOUBLE_NAN std::numeric_limits<double>::quiet_NaN()
|
||||
#else
|
||||
/* math.h needed for NAN */
|
||||
# include <math.h>
|
||||
# define SBE_FLOAT_NAN NAN
|
||||
# define SBE_DOUBLE_NAN NAN
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201103L
|
||||
# define SBE_CONSTEXPR constexpr
|
||||
# define SBE_NOEXCEPT noexcept
|
||||
#else
|
||||
# define SBE_CONSTEXPR
|
||||
# define SBE_NOEXCEPT
|
||||
#endif
|
||||
|
||||
#if __cplusplus >= 201703L
|
||||
# include <string_view>
|
||||
# define SBE_NODISCARD [[nodiscard]]
|
||||
#else
|
||||
# define SBE_NODISCARD
|
||||
#endif
|
||||
|
||||
#if !defined(__STDC_LIMIT_MACROS)
|
||||
# define __STDC_LIMIT_MACROS 1
|
||||
#endif
|
||||
|
||||
#include <cstdint>
|
||||
#include <cstring>
|
||||
#include <iomanip>
|
||||
#include <limits>
|
||||
#include <ostream>
|
||||
#include <stdexcept>
|
||||
#include <sstream>
|
||||
#include <string>
|
||||
#include <vector>
|
||||
#include <tuple>
|
||||
|
||||
#if defined(WIN32) || defined(_WIN32)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) _byteswap_ushort(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) _byteswap_ulong(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) _byteswap_uint64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) (v)
|
||||
#elif __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_16(v) __builtin_bswap16(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_32(v) __builtin_bswap32(v)
|
||||
# define SBE_LITTLE_ENDIAN_ENCODE_64(v) __builtin_bswap64(v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_16(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_32(v) (v)
|
||||
# define SBE_BIG_ENDIAN_ENCODE_64(v) (v)
|
||||
#else
|
||||
# error "Byte Ordering of platform not determined. Set __BYTE_ORDER__ manually before including this file."
|
||||
#endif
|
||||
|
||||
#if defined(SBE_NO_BOUNDS_CHECK)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (false)
|
||||
#elif defined(_MSC_VER)
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (exp)
|
||||
#else
|
||||
# define SBE_BOUNDS_CHECK_EXPECT(exp,c) (__builtin_expect(exp,c))
|
||||
#endif
|
||||
|
||||
#define SBE_NULLVALUE_INT8 (std::numeric_limits<std::int8_t>::min)()
|
||||
#define SBE_NULLVALUE_INT16 (std::numeric_limits<std::int16_t>::min)()
|
||||
@@ -86,7 +23,6 @@
|
||||
#define SBE_NULLVALUE_UINT32 (std::numeric_limits<std::uint32_t>::max)()
|
||||
#define SBE_NULLVALUE_UINT64 (std::numeric_limits<std::uint64_t>::max)()
|
||||
|
||||
|
||||
namespace iLinkBinary {
|
||||
|
||||
class SLEDS
|
||||
@@ -124,8 +60,8 @@ public:
|
||||
}
|
||||
|
||||
template<typename CharT, typename Traits>
|
||||
friend std::basic_ostream<CharT, Traits>& operator << (
|
||||
std::basic_ostream<CharT, Traits>& os, SLEDS::Value m)
|
||||
friend std::basic_ostream<CharT, Traits> & operator << (
|
||||
std::basic_ostream<CharT, Traits> &os, SLEDS::Value m)
|
||||
{
|
||||
return os << SLEDS::c_str(m);
|
||||
}
|
||||
|
||||
Loaded 100 of 121 files, more files were not shown because too many files have changed in this diff.
Show more
Reference in new issue
Block a user