libjmmcg
build_2783
A C++ library containing an eclectic mix of useful, advanced components.
|
A simple, FIX-protocol exchange simulator. More...
#include <processing_rules.hpp>
Classes | |
struct | state_machine_t |
Public Types | |
using | base_t = exchanges::common::simulator_responses< SrcMsgDetails, simulator_responses< SrcMsgDetails, SktT >, SktT > |
using | msg_details_t = typename base_t::msg_details_t |
using | src_msg_details_t = msg_details_t |
using | socket_t = typename base_t::socket_t |
Public Types inherited from isimud::exchanges::common::simulator_responses< SrcMsgDetails, simulator_responses< SrcMsgDetails, SktT >, SktT > | |
using | base_t = message_responses< SrcMsgDetails, SrcMsgDetails, simulator_responses< SrcMsgDetails, SktT >, typename SrcMsgDetails ::client_to_exchange_messages_t, SktT > |
using | msg_details_t = typename base_t::src_msg_details_t |
using | src_msg_details_t = msg_details_t |
using | socket_t = typename base_t::socket_t |
using | derived_t = typename base_t::derived_t |
using | Price_t = typename std::conditional< std::is_integral< typename msg_details_t::Price_t >::value, typename msg_details_t::Price_t, std::uint64_t >::type |
Public Member Functions | |
simulator_responses ()=default | |
simulator_responses (simulator_responses const &sr) noexcept(true) | |
bool | process_msg (typename src_msg_details_t::msg_buffer_t const &buff, socket_t &exchg_skt, socket_t &client_skt) override |
std::string | to_string () const noexcept(false) |
Public Member Functions inherited from isimud::exchanges::common::simulator_responses< SrcMsgDetails, simulator_responses< SrcMsgDetails, SktT >, SktT > | |
virtual bool | process_msg (typename src_msg_details_t::msg_buffer_t const &buff, socket_t &exchg_skt, socket_t &client_skt) override=0 |
std::string | to_string () const noexcept(false) |
Static Public Attributes | |
static constexpr Reason_t | logout_reason {'U', 's', 'e', 'r', ' ', 'l', 'o', 'g', 'o', 'u', 't', ' ', 'r', 'e', 'c', 'e', 'i', 'v', 'e', 'd'} |
static constexpr msg_details_t::SecurityID_t | instrumentID {'1'} |
The only valid instrument, all others will be rejected. More... | |
static constexpr msg_details_t::SecurityID_t | invalidInstrumentID {'2'} |
An invalid instrument, that will be rejected. More... | |
Static Public Attributes inherited from isimud::exchanges::common::simulator_responses< SrcMsgDetails, simulator_responses< SrcMsgDetails, SktT >, SktT > | |
static constexpr msg_details_t::UserName_t | username |
The only valid username. More... | |
static constexpr msg_details_t::Password_t | password |
The only valid password. More... | |
static constexpr msg_details_t::Password_t | new_password |
The only valid new password. More... | |
static constexpr std::int32_t | quantity_limit |
The magic quantity value. More... | |
static constexpr Price_t | price |
For limit orders, this is the price at which the order will be traded, otherwise it will be left "on the market". More... | |
static constexpr Price_t | scaled_price |
For limit orders, this is the native, scaled price at which the order will be traded, otherwise it will be left "on the market", which is used within the simulator. More... | |
Additional Inherited Members | |
Protected Types inherited from isimud::exchanges::common::simulator_responses< SrcMsgDetails, simulator_responses< SrcMsgDetails, SktT >, SktT > | |
using | order_book_t = std::map< typename msg_details_t::ClientOrderID_t, typename msg_details_t::NewOrder > |
Protected Member Functions inherited from isimud::exchanges::common::simulator_responses< SrcMsgDetails, simulator_responses< SrcMsgDetails, SktT >, SktT > | |
simulator_responses ()=default | |
simulator_responses (simulator_responses const &)=default | |
Protected Attributes inherited from isimud::exchanges::common::simulator_responses< SrcMsgDetails, simulator_responses< SrcMsgDetails, SktT >, SktT > | |
order_book_t | order_book |
std::int32_t | sequenceNumber |
A simple, FIX-protocol exchange simulator.
The behaviour of this simulator is a simplification derived from the specification in [1].
Definition at line 158 of file processing_rules.hpp.
using isimud::exchanges::FIX::common::simulator_responses< SrcMsgDetails, SktT >::base_t = exchanges::common::simulator_responses<SrcMsgDetails, simulator_responses<SrcMsgDetails, SktT>, SktT> |
Definition at line 160 of file processing_rules.hpp.
using isimud::exchanges::FIX::common::simulator_responses< SrcMsgDetails, SktT >::msg_details_t = typename base_t::msg_details_t |
Definition at line 161 of file processing_rules.hpp.
using isimud::exchanges::FIX::common::simulator_responses< SrcMsgDetails, SktT >::socket_t = typename base_t::socket_t |
Definition at line 163 of file processing_rules.hpp.
using isimud::exchanges::FIX::common::simulator_responses< SrcMsgDetails, SktT >::src_msg_details_t = msg_details_t |
Definition at line 162 of file processing_rules.hpp.
|
default |
|
inlinenoexcept |
Definition at line 172 of file processing_rules.hpp.
|
inlineoverride |
Definition at line 198 of file processing_rules_impl.hpp.
|
inlinenoexcept |
Definition at line 206 of file processing_rules_impl.hpp.
|
inlinestaticconstexpr |
The only valid instrument, all others will be rejected.
Definition at line 167 of file processing_rules.hpp.
|
inlinestaticconstexpr |
An invalid instrument, that will be rejected.
Definition at line 169 of file processing_rules.hpp.
|
inlinestaticconstexpr |
Definition at line 165 of file processing_rules.hpp.