Compare commits

..
25 Commits
Author SHA1 Message Date
petefisher78 4fd9442e5f Update externals submodule URL to Gitea 2026-11-12 10:19:56 -05:00
John Colvin 9a85a475db fix: Revert accidental change to externals 2023-01-10 09:51:54 -05:00
Taha Afzal 8a1ab0ba9e Updating generated files (and minor code adjustment) for CME schema 8 changes: 2023-01-09 10:28:10 -05:00
John Colvin 57ac54b6c5 build (sparkd): Pipe 'eval' cmd stdout/err back to shell
So we can actually see the build output
2023-01-05 14:03:40 -05:00
johncolvin-og 4a8433246c build: Use unix eol in build_sparkd, exec not eval 2023-01-05 14:03:40 -05:00
John Colvin d6351cd187 Update docker/linux
To get python3-venv
2023-01-05 14:03:40 -05:00
John Colvin eef263f2e7 build: Ensure python virtual env is installed/up-to-date 2023-01-05 14:03:40 -05:00
johncolvin-og 2009027586 build: Port build/publish_spark scripts over from crypto branches 2023-01-05 14:03:40 -05:00
John Colvin feaad6335d build: Set up cmake 'install' build target
The 'install' build target creates a self-contained (deployable) sparkd
package. It copies the sparkd executable and its dependencies into a
single directory (no symlinks), which can then be copied/deployed to
another machine.

Run `cmake --build . --target install` to install sparkd in the
directory defined by the CMAKE_INSTALL_PREFIX variable.
2023-01-05 14:03:40 -05:00
John Colvin b96612d37b fix build (linux): Port py3 build scripts over from spark_crypto.dev 2023-01-05 14:03:40 -05:00
John Colvin 84f9338005 Add .venv dirs to .gitignore 2023-01-05 14:03:40 -05:00
John Colvin 2837f3edfb chore: Add requirements.txt (py venv) 2023-01-05 14:03:40 -05:00
John Colvin a82932652b fix build: Copy a handful of files over from spark_crypto.dev
This fixes the last of the boost-related errors
2022-09-28 19:49:17 -04:00
John Colvin c9b5ff844f fix build (partial): Update externals to get new websocketpp
This fixes some of the boost errors related to the recent boost upgrade
2022-09-28 19:47:39 -04:00
John Colvin b0cbc2cb71 fix build: Disable web build
That's one way to fix it!
2022-09-28 19:33:19 -04:00
BTS User b2a2cae9c1 test 2022-09-28 13:44:48 -04:00
BTS User 93d9a924e9 test 2022-09-28 13:39:09 -04:00
BTS User 9d699711c1 test 2022-09-28 13:31:29 -04:00
BTS User 5951691cbd test 2022-09-28 13:28:20 -04:00
BTS Devs cbff70d5a1 plugin.py edited online with Bitbucket 2022-09-28 16:10:31 +00:00
BTS Devs b59d45ae28 plugin.py edited online with Bitbucket 2022-09-28 16:07:14 +00:00
BTS Devs ea6e158e63 plugin.py edited online with Bitbucket 2022-09-28 15:54:41 +00:00
BTS Devs 55a32935a9 plugin.py edited online with Bitbucket 2022-09-28 15:41:32 +00:00
BTS Devs 9f895df70c audit_ice.py edited online with Bitbucket 2022-09-23 21:25:37 +00:00
BTS Devs 8551936383 audit_upload.sh edited online with Bitbucket 2022-09-20 15:36:21 +00:00
173 changed files with 12465 additions and 7434 deletions

No files matched your search

+1
View File
@@ -37,3 +37,4 @@ trace_data/
*.rej
/build
.clangd/
.venv/**
+6 -3
View File
@@ -1,9 +1,12 @@
[submodule "externals"]
path = externals
url = git@bitbucket.org:bluetradesys/externals.git
url = https://git.wearethefishers.com/petefisher78/externals.git
[submodule "docker/linux"]
path = docker/linux
url = git@bitbucket.org:bluetradesys/linux_docker.git
url = https://git.wearethefishers.com/petefisher78/linux_docker.git
[submodule "docker/windows"]
path = docker/windows
url = git@bitbucket.org:bluetradesys/windows_docker.git
url = https://git.wearethefishers.com/petefisher78/windows_docker.git
[submodule "vcpkg"]
path = vcpkg
url = https://github.com/microsoft/vcpkg.git
+4 -1
View File
@@ -52,7 +52,7 @@ else ()
set (CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -Wno-undef")
add_subdirectory(src/server/sparkd)
add_subdirectory(src/lib)
add_subdirectory(src/web)
# add_subdirectory(src/web)
add_subdirectory(doc/user)
add_subdirectory(src/sdk)
add_subdirectory(src/data_files)
@@ -70,4 +70,7 @@ else ()
DEPENDS sparkd data_files_dir)
add_custom_target(server_layout ALL DEPENDS ${CMAKE_BINARY_DIR}/server)
install(FILES "${CMAKE_SOURCE_DIR}/externals/linux/lib/${CMAKE_BUILD_TYPE}/libACE-5.7.5.so" DESTINATION bin)
install(FILES "${CMAKE_SOURCE_DIR}/externals/linux/lib/${CMAKE_BUILD_TYPE}/libOnixS.IceImpactMulticastPriceFeedHandlerCpp.so.3.16.0.0" DESTINATION bin)
endif()
+21
View File
@@ -0,0 +1,21 @@
astroid==2.7.3
autopep8==1.5.7
cffi==1.14.6
colorama==0.4.4
isort==5.9.3
lazy-object-proxy==1.6.0
mccabe==0.6.1
pkg_resources==0.0.0
platformdirs==2.3.0
protobuf==3.19.1
pybars3==0.9.7
pycodestyle==2.7.0
pycparser==2.20
pylint==2.10.2
PyMeta3==0.5.1
termcolor==1.1.0
toml==0.10.2
typed-ast==1.4.3
typing_extensions==4.1.1
wrapt==1.12.1
yapf==0.31.0
+7 -2
View File
@@ -32,11 +32,17 @@ valid_message_types = {
def print_headers():
# From https://www.theice.com/publicdocs/futures_us/exchange_notices/ICE_Advisory_0113_009.pdf
line_to_write = ",11,37,60,55,55,167,202,201,54,38,210,40,44,99,440,439,9175,9195,9208,9139,115 (left),115 (right),116 (right),116 (left),144 (left),59"
with open (args.output_file, 'w') as the_file:
the_file.write(line_to_write)
the_file.write("\n")
line_to_write = "Active Date,Cl Ord ID,OrderID,Transact Time,Symbol,Symbol,SecurityType,Stk Prc,P/C,Side,OrderQty,Max Show,OrdType,\
Price,StopPx,Clearing Account,Clearing Firm,Order State,AccountCode,CTI Code,Originator User ID,OnBehalfOfCompID,\
OnBehalfOfCompID,On Behalf Of Sub ID,On Behalf Of Sub ID,On Behalf Of Location ID,Time In Force"
with open (args.output_file, 'w') as the_file:
with open (args.output_file, 'a') as the_file:
the_file.write(line_to_write)
the_file.write("\n")
@@ -49,7 +55,6 @@ Routing Trdr,Routing Grp,Time In Force"
the_file.write(line_to_write)
the_file.write("\n")
def getter(field_name):
def result(parsed_fix_record):
if field_name in parsed_fix_record:
+1 -1
View File
@@ -56,7 +56,7 @@ for SESSION in $(ls /sparkdata/data/{ilink3,jetfix}/); do
ILINK_TYPE="ilink3"
LOG_NAME="log"
elif [[ $SESSION == "ice_"* ]]; then
SESSION_DAY=$(date -d "$DATE 2 days ago" +%Y-%m-%d)
SESSION_DAY=$(date -d "$DATE 1 days ago" +%Y-%m-%d)
AUDIT_SCRIPT="audit_ice.py"
ILINK_TYPE="jetfix"
LOG_NAME="fix"
+3 -1
View File
@@ -135,7 +135,9 @@ else ()
-ldl
-static-libgcc
-static-libstdc++
-pthread)
-pthread)
install(TARGETS libspark DESTINATION bin)
endif()
if (WIN32)
+1 -1
View File
@@ -319,7 +319,7 @@ if __name__ == "__main__":
if DEBUG:
for f in response.file:
print f.content
print (f.content)
else:
output = response.SerializeToString()
sys.stdout.write(output)
+35 -41
View File
@@ -9,33 +9,28 @@ namespace config {
namespace internal {
HTTPServer::HTTPServer()
: _io_service(),
_acceptor(_io_service, tcp::endpoint(boost::asio::ip::address_v4::loopback(), 0)),
_cur_socket(),
_request_response_pairs(),
_thread(),
_done(false)
{
}
: _io_service(),
_acceptor(
_io_service,
tcp::endpoint(boost::asio::ip::address_v4::loopback(), 0)),
_cur_socket(), _request_response_pairs(), _thread(), _done(false) {}
unsigned int HTTPServer::port() const
{
unsigned int HTTPServer::port() const {
return _acceptor.local_endpoint().port();
}
void HTTPServer::add_response(const std::string& path, const std::string& response, const std::string& content)
{
void HTTPServer::add_response(
const std::string &path,
const std::string &response,
const std::string &content) {
_request_response_pairs[path] = response + content;
}
void HTTPServer::start()
{
void HTTPServer::start() {
_thread.reset(new boost::thread(boost::bind(&HTTPServer::worker, this)));
}
void HTTPServer::stop()
{
void HTTPServer::stop() {
_done = true;
_io_service.stop();
@@ -45,55 +40,52 @@ void HTTPServer::stop()
}
}
void HTTPServer::worker()
{
void HTTPServer::worker() {
start_accept();
_io_service.run();
}
void HTTPServer::start_accept()
{
void HTTPServer::start_accept() {
_cur_socket.reset(new boost::asio::ip::tcp::socket(_io_service));
_acceptor.async_accept(*_cur_socket.get(), boost::bind(&HTTPServer::handle_accept, this, _cur_socket.get(), boost::asio::placeholders::error));
_acceptor.async_accept(
*_cur_socket.get(),
boost::bind(
&HTTPServer::handle_accept, this, _cur_socket.get(),
boost::asio::placeholders::error));
}
void HTTPServer::handle_accept(boost::asio::ip::tcp::socket* socket, const boost::system::error_code& error)
{
if (!error)
{
void HTTPServer::handle_accept(
boost::asio::ip::tcp::socket *socket,
const boost::system::error_code &error) {
if (!error) {
handle_connect(socket);
}
start_accept();
}
void HTTPServer::handle_connect(boost::asio::ip::tcp::socket* socket)
{
void HTTPServer::handle_connect(boost::asio::ip::tcp::socket *socket) {
boost::asio::streambuf buffer;
size_t size = boost::asio::read_until(*socket, buffer, "\r\n\r\n");
std::string request(size, 0);
buffer.sgetn(&request[0], size);
size_t start = request.find("GET ") + 4;
size_t end = request.find(" HTTP/1.1\r\n");
size_t url_args = request.find("?");
if (url_args != std::string::npos)
end = std::min(end, url_args);
std::string request_path = request.substr(start, end-start);
std::string request_path = request.substr(start, end - start);
std::map<std::string, std::string>::iterator request_match =
_request_response_pairs.find(request_path);
if (request_match == _request_response_pairs.end())
{
std::map<std::string, std::string>::iterator request_match =
_request_response_pairs.find(request_path);
if (request_match == _request_response_pairs.end()) {
std::string response = "HTTP/1.0 404 NOT FOUND\r\n"
"Content-Type: text/plain\r\n\r\n"
"not found\r\n";
boost::asio::write(*socket, boost::asio::buffer(response));
}
else
{
} else {
boost::asio::write(*socket, boost::asio::buffer(request_match->second));
}
@@ -102,4 +94,6 @@ void HTTPServer::handle_connect(boost::asio::ip::tcp::socket* socket)
socket->close(ec);
}
}}}
} // namespace internal
} // namespace config
} // namespace bts
+15 -10
View File
@@ -8,6 +8,7 @@
#include <boost/asio/read_until.hpp>
#include <boost/asio/streambuf.hpp>
#include <boost/asio/write.hpp>
#define BOOST_BIND_GLOBAL_PLACEHOLDERS
#include <boost/bind.hpp>
#include <boost/lexical_cast.hpp>
#include <boost/scoped_ptr.hpp>
@@ -17,28 +18,31 @@
#include <boost/asio/connect.hpp>
#include <boost/scoped_ptr.hpp>
#include <string>
#include <map>
#include <string>
namespace bts {
namespace config {
namespace internal {
class HTTPServer
{
public:
class HTTPServer {
public:
HTTPServer();
unsigned int port() const;
void start();
void add_response(const std::string& path, const std::string& response, const std::string& content);
void add_response(
const std::string &path,
const std::string &response,
const std::string &content);
void stop();
private:
private:
void worker();
void start_accept();
void handle_accept(boost::asio::ip::tcp::socket*, const boost::system::error_code& error);
void handle_connect(boost::asio::ip::tcp::socket*);
void handle_accept(
boost::asio::ip::tcp::socket *, const boost::system::error_code &error);
void handle_connect(boost::asio::ip::tcp::socket *);
boost::asio::io_service _io_service;
boost::asio::ip::tcp::acceptor _acceptor;
@@ -46,8 +50,9 @@ private:
std::map<std::string, std::string> _request_response_pairs;
boost::scoped_ptr<boost::thread> _thread;
bool _done;
};
}}} // end namespace
} // namespace internal
} // namespace config
} // namespace bts
#endif
File diff suppressed because it is too large. Load diff
+311 -360
View File
@@ -1,8 +1,8 @@
#include "lib/utils/TempFile.h"
#include "../config.h"
#include "../ConfigurationState.h"
#include "../ConfigurationException.h"
#include "../ConfigurationState.h"
#include "../config.h"
#include "lib/expression/ParserExceptions.h"
#include "lib/utils/bts_assert.h"
#include "lib/utils/is_unittest_environment.h"
@@ -19,9 +19,9 @@
#define URDL_HEADER_ONLY 1
#define URDL_DISALE_SSL 1
#include <urdl/url.hpp>
#include <urdl/test/http_server.hpp>
#include <catch/catch.hpp>
#include <urdl/test/http_server.hpp>
#include <urdl/url.hpp>
using namespace bts::config;
using namespace bts::config::internal;
@@ -31,124 +31,107 @@ using bts::config::test::Foo;
using bts::config::test::FooGroup;
using bts::config::test::StringTable;
namespace bts {
int config_tests = 0;
TEST_CASE("Configuration Tests","[config]") {
TEST_CASE("Configuration Tests", "[config]") {
bts::utils::internal::force_unittest_environment();
SECTION("basic_get_value_test")
{
initialize_for_test(
"Foo { \n"
" rule: \"true\"\n"
" value {\n"
" name: \"Name A\"\n"
" id: 65\n"
" email: \"test@example.com\"\n"
" }\n"
"}\n");
SECTION("basic_get_value_test") {
initialize_for_test("Foo { \n"
" rule: \"true\"\n"
" value {\n"
" name: \"Name A\"\n"
" id: 65\n"
" email: \"test@example.com\"\n"
" }\n"
"}\n");
const Foo& foo = get<Foo>();
const Foo &foo = get<Foo>();
REQUIRE(foo.name() == "Name A");
REQUIRE(foo.id() == 65);
REQUIRE(foo.email().Get(0) == "test@example.com");
}
SECTION("default_value_test")
{
SECTION("default_value_test") {
initialize_for_test(""); // Only loads defaults.conf
// Should load a Foo from testkeys.conf
const Foo& foo = get<Foo>();
const Foo &foo = get<Foo>();
REQUIRE(foo.name() == "Blue Foo"); // from testkeys.proto
REQUIRE(foo.id() == 1234); // from testkeys.proto
REQUIRE(foo.id() == 1234); // from testkeys.proto
REQUIRE(foo.email().size() > 0);
REQUIRE(foo.email().Get(0) == "default@example.com"); // from testkeys.conf
REQUIRE(
foo.email().Get(0) == "default@example.com"); // from testkeys.conf
}
SECTION("default_include_test")
{
SECTION("default_include_test") {
// test defaults.conf with an include
}
SECTION("invalid_key_type_test")
{
SECTION("invalid_key_type_test") {
// Load an initialize with no files - OK all values default
const Foo& foo = get<Foo>(); // OK
const Foo &foo = get<Foo>(); // OK
REQUIRE(foo.name() == "Blue Foo");
bool error = false;
try
{
try {
get<config::test::InvalidMessageType>(); // BAD
}
catch(...)
{
} catch (...) {
error = true;
}
REQUIRE(error == true);
}
SECTION("invalid_config_test2")
{
SECTION("invalid_config_test2") {
utils::TempFile config_b;
*config_b.out() <<
"Foo {\n"
" value { \n"
" name: \"bob\"\n"
" id: 7319 \n"
" }";
*config_b.out() << "Foo {\n"
" value { \n"
" name: \"bob\"\n"
" id: 7319 \n"
" }";
bool error = false;
try
{
try {
initialize_for_test("include: \"" + config_b.path() + "\"", false);
}
catch(const ConfigurationException& err)
{
} catch (const ConfigurationException &err) {
std::string what = err.what();
bts_assert(what.find("Expected identifier.") != std::string::npos);
error = true;
}
REQUIRE(error == true);
}
// Tests that we can load using a File:/// url
// Tests complex value load
SECTION("file_url_test")
{
SECTION("file_url_test") {
utils::TempFile config_a;
utils::TempFile config_b;
*config_a.out() << "include: \"" << config_b.path() << "\"" << std::endl <<
"Foo { \n"
" rule: \"false\"\n"
" value {\n"
" name: \"Name A\"\n"
" id: 65\n"
" email: \"A@bluecg.com\"\n"
" }\n"
"}\n";
*config_a.out() << "include: \"" << config_b.path() << "\"" << std::endl
<< "Foo { \n"
" rule: \"false\"\n"
" value {\n"
" name: \"Name A\"\n"
" id: 65\n"
" email: \"A@bluecg.com\"\n"
" }\n"
"}\n";
*config_b.out() <<
"Foo {\n"
" rule: \"true\"\n"
" value {\n"
" name: \"Name B\"\n"
" id: 66 "
" email: \"A@bluecg.com\" \n"
" }}";
*config_b.out() << "Foo {\n"
" rule: \"true\"\n"
" value {\n"
" name: \"Name B\"\n"
" id: 66 "
" email: \"A@bluecg.com\" \n"
" }}";
// Get key Foo without loading any config files - this will show the default value
// Get key Foo without loading any config files - this will show the
// default value
Foo foo = bts::config::get<Foo>();
REQUIRE(foo.name() == "Blue Foo");
@@ -163,23 +146,20 @@ TEST_CASE("Configuration Tests","[config]") {
REQUIRE(foo.id() == 66);
}
SECTION("http_test")
{
SECTION("http_test") {
HTTPServer server;
std::string port = boost::lexical_cast<std::string>(server.port());
std::string path = "/spark.conf";
std::string response =
"HTTP/1.0 200 OK\r\n"
"Content-Type: text/plain\r\n\r\n";
std::string content =
"FooGroup {\n"
" rule: \"true\"\n"
" value {\n"
" group: \"http_group\"\n"
" foo {\n"
" name: \"http\"\n"
" id: 80\n"
"}}}\n";
std::string response = "HTTP/1.0 200 OK\r\n"
"Content-Type: text/plain\r\n\r\n";
std::string content = "FooGroup {\n"
" rule: \"true\"\n"
" value {\n"
" group: \"http_group\"\n"
" foo {\n"
" name: \"http\"\n"
" id: 80\n"
"}}}\n";
server.add_response(path, response, content);
server.start();
@@ -190,7 +170,7 @@ TEST_CASE("Configuration Tests","[config]") {
server.stop();
const FooGroup& foogrp = get<FooGroup>();
const FooGroup &foogrp = get<FooGroup>();
REQUIRE(foogrp.group() == "http_group");
REQUIRE(foogrp.foo().name() == "http");
@@ -198,41 +178,41 @@ TEST_CASE("Configuration Tests","[config]") {
REQUIRE(get<System>().config_host() == "127.0.0.1");
}
SECTION("http_folder_test")
{
SECTION("http_folder_test") {
HTTPServer server;
std::string port = boost::lexical_cast<std::string>(server.port());
std::string config_url = "http://localhost:" + port + "/";
std::string response =
"HTTP/1.0 200 OK\r\n"
"Content-Type: text/plain\r\n\r\n";
std::string response = "HTTP/1.0 200 OK\r\n"
"Content-Type: text/plain\r\n\r\n";
server.add_response("/spark.conf", response, "include: \"" + config_url + "other/\"");
server.add_response("/testkeys.conf", response,
"FooGroup {\n"
" rule: \"true\"\n"
" value {\n"
" group: \"http_group\"\n"
" foo {\n"
" name: \"http\"\n"
" id: 80\n"
"}}}\n");
server.add_response("/other/spark.conf", response,
"Foo {\n"
" rule: \"true\"\n"
" value: {\n"
" name: \"included_value\"\n"
" id: 4096\n"
" }}\n");
server.add_response(
"/spark.conf", response, "include: \"" + config_url + "other/\"");
server.add_response(
"/testkeys.conf", response,
"FooGroup {\n"
" rule: \"true\"\n"
" value {\n"
" group: \"http_group\"\n"
" foo {\n"
" name: \"http\"\n"
" id: 80\n"
"}}}\n");
server.add_response(
"/other/spark.conf", response,
"Foo {\n"
" rule: \"true\"\n"
" value: {\n"
" name: \"included_value\"\n"
" id: 4096\n"
" }}\n");
server.start();
initialize_for_test("include: \"" + config_url + "\"");
server.stop();
const FooGroup& foogrp = get<FooGroup>();
const FooGroup &foogrp = get<FooGroup>();
REQUIRE(foogrp.group() == "http_group");
REQUIRE(foogrp.foo().name() == "http");
@@ -242,44 +222,39 @@ TEST_CASE("Configuration Tests","[config]") {
REQUIRE(get<Foo>().id() == 4096);
}
SECTION("test_rules")
{
initialize_for_test(
"StringTable {\n"
" value { \n"
" entries: [\"foo\", \"bar\", \"baz\"] \n"
" }\n"
" }\n"
"RuleRef { \n"
" # use this rule of StringTable has a cow \n"
" rule: \"'cow' in StringTable.entries\" \n"
" value { \n"
" a_string: \"AAA\"\n"
" a_int: -1\n"
" }\n"
"}\n"
"RuleRef { \n"
" rule: \"'baz' in StringTable.entries\" \n"
" value { \n"
" a_string: \"BBB\"\n"
" a_int: 99\n"
" }\n"
"}\n"
"Foo { \n"
" rule: \"RuleRef.a_int == 789\"\n"
" value {\n"
" name: \"A\"\n"
" }\n"
"}\n"
"Foo { \n"
" rule: \"RuleRef.a_string == 'BBB'\"\n"
" value {\n"
" name: \"B\"\n"
" }\n"
"}\n"
);
SECTION("test_rules") {
initialize_for_test("StringTable {\n"
" value { \n"
" entries: [\"foo\", \"bar\", \"baz\"] \n"
" }\n"
" }\n"
"RuleRef { \n"
" # use this rule of StringTable has a cow \n"
" rule: \"'cow' in StringTable.entries\" \n"
" value { \n"
" a_string: \"AAA\"\n"
" a_int: -1\n"
" }\n"
"}\n"
"RuleRef { \n"
" rule: \"'baz' in StringTable.entries\" \n"
" value { \n"
" a_string: \"BBB\"\n"
" a_int: 99\n"
" }\n"
"}\n"
"Foo { \n"
" rule: \"RuleRef.a_int == 789\"\n"
" value {\n"
" name: \"A\"\n"
" }\n"
"}\n"
"Foo { \n"
" rule: \"RuleRef.a_string == 'BBB'\"\n"
" value {\n"
" name: \"B\"\n"
" }\n"
"}\n");
// What should happen:
// Foo A
@@ -297,286 +272,262 @@ TEST_CASE("Configuration Tests","[config]") {
// success a_string == 'BBB'
// return Foo B
const Foo& foo = get<Foo>();
const Foo &foo = get<Foo>();
REQUIRE(foo.name() == "B");
}
SECTION("test_recursive_rules") {
initialize_for_test("StringTable {\n"
" rule: \"Foo.name == 'foo'\"\n"
" value { \n"
" entries: [\"foo\", \"bar\", \"baz\"] \n"
" }\n"
" }\n"
"RuleRef { \n"
" rule: \"'foo' in StringTable.entries\" \n"
" value { \n"
" a_string: \"AAA\"\n"
" a_int: -1\n"
" }\n"
"}\n"
"Foo { \n"
" rule: \"RuleRef.a_string == 'BBB'\"\n"
" value {\n"
" name: \"foo\"\n"
" }\n"
"}\n");
SECTION("test_recursive_rules")
{
initialize_for_test(
"StringTable {\n"
" rule: \"Foo.name == 'foo'\"\n"
" value { \n"
" entries: [\"foo\", \"bar\", \"baz\"] \n"
" }\n"
" }\n"
"RuleRef { \n"
" rule: \"'foo' in StringTable.entries\" \n"
" value { \n"
" a_string: \"AAA\"\n"
" a_int: -1\n"
" }\n"
"}\n"
"Foo { \n"
" rule: \"RuleRef.a_string == 'BBB'\"\n"
" value {\n"
" name: \"foo\"\n"
" }\n"
"}\n"
);
// Foo cannot be queried because RuleRef's rule requests StringTable which requests RuleRef
// Foo cannot be queried because RuleRef's rule requests StringTable which
// requests RuleRef
bool error = false;
try
{
try {
get<Foo>();
}
catch(const expression::RecursivePropertyGetException&)
{
} catch (const expression::RecursivePropertyGetException &) {
error = true;
}
REQUIRE(error);
}
SECTION("test_nested_properties")
{
initialize_for_test(
"RuleRef { \n"
" value { \n"
" nested {\n"
" list_int: [7,8,9] \n"
" nested {\n"
" a_string: 'ABC' \n"
" }\n"
" }\n"
" }\n"
"}\n"
"Foo { \n"
" rule: \"RuleRef.nested.nested.a_string == 'ABC' and 9 in RuleRef.nested.list_int\"\n"
" value {\n"
" name: \"foo\"\n"
" }\n"
"}\n"
);
SECTION("test_nested_properties") {
initialize_for_test("RuleRef { \n"
" value { \n"
" nested {\n"
" list_int: [7,8,9] \n"
" nested {\n"
" a_string: 'ABC' \n"
" }\n"
" }\n"
" }\n"
"}\n"
"Foo { \n"
" rule: \"RuleRef.nested.nested.a_string == 'ABC' "
"and 9 in RuleRef.nested.list_int\"\n"
" value {\n"
" name: \"foo\"\n"
" }\n"
"}\n");
REQUIRE(get<Foo>().name() == "foo");
}
SECTION("built_in_properties_test")
{
initialize_for_test(
"Foo { \n"
" rule: \"System.unittest_environment == true \"\n"
" value {\n"
" name: \"unit tests\"\n"
" }\n"
"}\n"
);
SECTION("built_in_properties_test") {
initialize_for_test("Foo { \n"
" rule: \"System.unittest_environment == true \"\n"
" value {\n"
" name: \"unit tests\"\n"
" }\n"
"}\n");
REQUIRE(get<Foo>().name() == "unit tests");
}
SECTION("nonbreaking_space_test")
{
SECTION("nonbreaking_space_test") {
bool parse_error = false;
try
{
try {
initialize_for_test(
"Foo { "
" value {\xA0\xA0 "
" name: \"valid name\""
" \xA0 }"
"} ", false);
}
catch(const bts::config::ConfigurationException)
{
"Foo { "
" value {\xA0\xA0 "
" name: \"valid name\""
" \xA0 }"
"} ",
false);
} catch (const bts::config::ConfigurationException &) {
parse_error = true;
}
REQUIRE(parse_error);
}
SECTION("macro_bool_test")
{
initialize_for_test(
"macro"
"{"
" name: \"bool\""
" expression: \"'c' in ['a', 'b', 'c', 'd']\""
"}"
""
"Foo"
"{"
" rule: \"$bool\""
" value {"
" name: 'good'"
" }"
"}"
""
"Foo"
"{"
" value {"
" name: 'bad'"
" }"
"}"
);
SECTION("macro_bool_test") {
initialize_for_test("macro"
"{"
" name: \"bool\""
" expression: \"'c' in ['a', 'b', 'c', 'd']\""
"}"
""
"Foo"
"{"
" rule: \"$bool\""
" value {"
" name: 'good'"
" }"
"}"
""
"Foo"
"{"
" value {"
" name: 'bad'"
" }"
"}");
REQUIRE(config::get<Foo>().name() == "good");
}
SECTION("macro_list_test")
{
initialize_for_test(
"macro"
"{"
" name: \"list\""
" expression: \"['a', 'b', 'c', 'd']\""
"}"
""
"Foo"
"{"
" rule: \"'a' in $list\""
" value {"
" name: 'good'"
" }"
"}"
""
"Foo"
"{"
" value {"
" name: 'bad'"
" }"
"}"
);
SECTION("macro_list_test") {
initialize_for_test("macro"
"{"
" name: \"list\""
" expression: \"['a', 'b', 'c', 'd']\""
"}"
""
"Foo"
"{"
" rule: \"'a' in $list\""
" value {"
" name: 'good'"
" }"
"}"
""
"Foo"
"{"
" value {"
" name: 'bad'"
" }"
"}");
REQUIRE(config::get<Foo>().name() == "good");
}
SECTION("fallback_test") {
//HTTPServer main;
// HTTPServer main;
HTTPServer fallback;
//std::string main_url = "http://localhost:" + boost::lexical_cast<std::string>(main.port()) + "/";
// std::string main_url = "http://localhost:" +
// boost::lexical_cast<std::string>(main.port()) + "/";
std::string main_url = "http://does_not_exist:12345/";
//main.stop();
std::string fallback_url = "http://127.0.0.1:" + boost::lexical_cast<std::string>(fallback.port()) + "/";
std::string response =
"HTTP/1.0 200 OK\r\n"
"Content-Type: text/plain\r\n\r\n";
// main.stop();
std::string fallback_url =
"http://127.0.0.1:" +
boost::lexical_cast<std::string>(fallback.port()) + "/";
std::string response = "HTTP/1.0 200 OK\r\n"
"Content-Type: text/plain\r\n\r\n";
std::string content =
"FooGroup {\n"
" value {\n"
" group: \"http_group\"\n"
" foo {\n"
" name: \"http\"\n"
" id: 80\n"
"}}}\n";
std::string content = "FooGroup {\n"
" value {\n"
" group: \"http_group\"\n"
" foo {\n"
" name: \"http\"\n"
" id: 80\n"
"}}}\n";
fallback.add_response("/spark.conf", response, content);
fallback.start();
initialize_for_test(
"include: '" + main_url + "'\n"
"fallback: '" + fallback_url + "'\n",false
);
"include: '" + main_url +
"'\n"
"fallback: '" +
fallback_url + "'\n",
false);
fallback.stop();
REQUIRE(get<FooGroup>().foo().name() == "http");
REQUIRE(get<FooGroup>().foo().id() == 80);
}
SECTION("macro_definition_order_test") {
// The $is_crusible test
// o2_cme_enabled depends on Foo which has a rule which depends on is_crucible.
// Eager evaluation caused a bug which would cause loading o2_cme_enabled to set is_crucible false. Case 3993
initialize_for_test(
"Foo {"
" rule: '$is_crucible'"
" value { name: 'cme_1u7_cert' }"
"}"
""
"Foo {"
" value { name: '' }"
"}"
""
"macro {"
" name: 'o2_cme_enabled'"
" expression: \"Foo.name != ''\" "
"}"
""
"macro {"
" name: 'is_crucible'"
" expression: 'true'"
"}"
);
// o2_cme_enabled depends on Foo which has a rule which depends on
// is_crucible. Eager evaluation caused a bug which would cause loading
// o2_cme_enabled to set is_crucible false. Case 3993
initialize_for_test("Foo {"
" rule: '$is_crucible'"
" value { name: 'cme_1u7_cert' }"
"}"
""
"Foo {"
" value { name: '' }"
"}"
""
"macro {"
" name: 'o2_cme_enabled'"
" expression: \"Foo.name != ''\" "
"}"
""
"macro {"
" name: 'is_crucible'"
" expression: 'true'"
"}");
REQUIRE(get<Foo>().name() == "cme_1u7_cert");
}
SECTION("repeated_value_order_preserved") {
initialize_for_test(
"Foo {"
" value { name: 'edge-eharding' id: 80 }"
"}"
"StringTable {"
" value {"
" entries: 'http://'"
" entries: @Foo.name"
" entries: ':'"
" entries: @Foo.id"
" entries: '/risk'"
" }"
"}");
initialize_for_test("Foo {"
" value { name: 'edge-eharding' id: 80 }"
"}"
"StringTable {"
" value {"
" entries: 'http://'"
" entries: @Foo.name"
" entries: ':'"
" entries: @Foo.id"
" entries: '/risk'"
" }"
"}");
std::string result;
for (const auto& part : get<StringTable>().entries()) {
for (const auto &part : get<StringTable>().entries()) {
result += part;
}
REQUIRE(result == "http://edge-eharding:80/risk");
}
SECTION("string_concat_test") {
initialize_for_test(
"Ports {\n"
" value { \n"
" config_port: 80 \n"
" }\n"
"}\n"
"RuleRef { \n"
" value { \n"
" a_string: \"localhost\"\n"
" }\n"
"}\n"
"macro{\n"
" name: 'list'\n"
" expression: \"['http://', RuleRef.a_string, ':', Ports.config_port, '/risk']\"\n"
"}"
"StringTable {\n"
"value {\n"
" entries: 'http://'\n"
" entries: @RuleRef.a_string\n"
" entries: ':'\n"
" entries: @Ports.config_port\n"
" entries: '/risk'\n"
"}}\n"
"Foo { \n"
" value {\n"
" name: $list\n"
" url: @StringTable.entries \n"
" }\n"
"}"
);
initialize_for_test("Ports {\n"
" value { \n"
" config_port: 80 \n"
" }\n"
"}\n"
"RuleRef { \n"
" value { \n"
" a_string: \"localhost\"\n"
" }\n"
"}\n"
"macro{\n"
" name: 'list'\n"
" expression: \"['http://', RuleRef.a_string, ':', "
"Ports.config_port, '/risk']\"\n"
"}"
"StringTable {\n"
"value {\n"
" entries: 'http://'\n"
" entries: @RuleRef.a_string\n"
" entries: ':'\n"
" entries: @Ports.config_port\n"
" entries: '/risk'\n"
"}}\n"
"Foo { \n"
" value {\n"
" name: $list\n"
" url: @StringTable.entries \n"
" }\n"
"}");
auto foo = config::get<Foo>();
auto expected = "http://localhost:80/risk";
REQUIRE(foo.name() == expected);
REQUIRE(foo.url() == expected);
}
reset();
}
}
} // namespace bts
@@ -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 << '}';
@@ -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
@@ -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 -66
View File
@@ -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 &quoteEntryOpen(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 &quoteEntryOpen(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 &quoteEntryOpen(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 &quoteEntryOpen(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
Loaded 100 of 173 files, more files were not shown because too many files have changed in this diff. Show more