dxFeed Graal CXX API
Loading...
Searching...
No Matches
dxfcpp::Order Class Reference

Order event is a snapshot for a full available market depth for a symbol. More...

#include <Order.hpp>

+ Inheritance diagram for dxfcpp::Order:

Public Types

using Ptr = std::shared_ptr<Order>
 The alias to a type of shared pointer to the Order object.
 
using Unique = std::unique_ptr<Order>
 The alias to a type of unique pointer to the Order object.
 
- Public Types inherited from dxfcpp::MarketEvent
using Ptr = std::shared_ptr<MarketEvent>
 The alias to a type of shared pointer to the MarketEvent object.
 
- Public Types inherited from dxfcpp::EventTypeWithSymbol< std::string >
using Ptr
 The alias to a type of shared pointer to the EventTypeWithSymbol's child object.
 
- Public Types inherited from dxfcpp::EventType
using Ptr = std::shared_ptr<EventType>
 The alias to a type of shared pointer to the EventType object.
 
- Public Types inherited from dxfcpp::SharedEntity
using Ptr = std::shared_ptr<SharedEntity>
 The alias to a type of shared pointer to the SharedEntity object.
 
- Public Types inherited from dxfcpp::IndexedEvent
using Ptr = std::shared_ptr<IndexedEvent>
 The alias to a type of shared pointer to the IndexedEvent object.
 

Public Member Functions

voidtoGraal () const noexcept override
 Allocates memory for the dxFeed Graal SDK structure (recursively if necessary).
 
 Order () noexcept=default
 Creates new order event with default values.
 
 Order (std::string eventSymbol) noexcept
 Creates new order event with the specified event symbol.
 
virtual OrderwithEventSymbol (const std::string &eventSymbol) noexcept
 Changes event's symbol and returns the current order.
 
Order::Ptr withEventSymbolShared (const std::string &eventSymbol) noexcept
 Changes event's symbol and returns a shared pointer to the current order.
 
OrderwithEventTime (std::int64_t eventTime) noexcept
 Changes event's creation time and returns the current order.
 
Order::Ptr withEventTimeShared (std::int64_t eventTime) noexcept
 Changes event's creation time and returns a shared pointer to the current order.
 
OrderwithSource (const OrderSource &source) noexcept
 Changes event's source and returns the current order.
 
Order::Ptr withSourceShared (const OrderSource &source) noexcept
 Changes event's source and returns a shared pointer to the current order.
 
OrderwithEventFlags (std::int32_t eventFlags) noexcept
 Changes transactional event flags and returns the current order.
 
Order::Ptr withEventFlagsShared (std::int32_t eventFlags) noexcept
 Changes transactional event flags and returns a shared pointer to the current order.
 
OrderwithEventFlags (const EventFlagsMask &eventFlags) noexcept
 Changes transactional event flags and returns the current order.
 
Order::Ptr withEventFlagsShared (const EventFlagsMask &eventFlags) noexcept
 Changes transactional event flags and returns a shared pointer to the current order.
 
OrderwithIndex (std::int64_t index) noexcept
 Changes unique per-symbol index of this order and returns it.
 
Order::Ptr withIndexShared (std::int64_t index) noexcept
 Changes unique per-symbol index of this order and returns a shared pointer to it.
 
OrderwithTime (std::int64_t time) noexcept
 Changes time of this order and returns it.
 
Order::Ptr withTimeShared (std::int64_t time) noexcept
 Changes time of this order and returns a shared pointer to it.
 
OrderwithTimeNanoPart (std::int32_t timeNanoPart) noexcept
 Changes microseconds and nanoseconds time part of this order.
 
Order::Ptr withTimeNanoPartShared (std::int32_t timeNanoPart) noexcept
 Changes microseconds and nanoseconds time part of this order.
 
OrderwithSequence (std::int32_t sequence) noexcept
 Changes sequence number of this order.
 
Order::Ptr withSequenceShared (std::int32_t sequence) noexcept
 Changes sequence number of this order.
 
OrderwithTimeNanos (std::int64_t timeNanos) noexcept
 Changes time of this order and returns it.
 
Order::Ptr withTimeNanosShared (std::int64_t timeNanos) noexcept
 Changes time of this order.
 
OrderwithAction (const OrderAction &action) noexcept
 Changes action of this order and returns it.
 
Order::Ptr withActionShared (const OrderAction &action) noexcept
 Changes action of this order.
 
OrderwithActionTime (std::int64_t actionTime) noexcept
 Changes time of the last action and returns current order.
 
Order::Ptr withActionTimeShared (std::int64_t actionTime) noexcept
 Changes time of the last action and returns a shared pointer to the current order.
 
OrderwithOrderId (std::int64_t orderId) noexcept
 Changes order ID.
 
Order::Ptr withOrderIdShared (std::int64_t orderId) noexcept
 Changes order ID.
 
OrderwithAuxOrderId (std::int64_t auxOrderId) noexcept
 Changes auxiliary order ID.
 
Order::Ptr withAuxOrderIdShared (std::int64_t auxOrderId) noexcept
 Changes auxiliary order ID.
 
OrderwithPrice (double price) noexcept
 Changes price of this order.
 
Order::Ptr withPriceShared (double price) noexcept
 Changes price of this order.
 
OrderwithSize (double size) noexcept
 Changes size of this order.
 
Order::Ptr withSizeShared (double size) noexcept
 Changes size of this order.
 
OrderwithExecutedSize (double executedSize) noexcept
 Changes executed size of this order.
 
Order::Ptr withExecutedSizeShared (double executedSize) noexcept
 Changes executed size of this order.
 
OrderwithCount (std::int64_t count) noexcept
 Changes number of individual orders in this aggregate order.
 
Order::Ptr withCountShared (std::int64_t count) noexcept
 Changes number of individual orders in this aggregate order.
 
OrderwithTradeId (std::int64_t tradeId) noexcept
 Changes trade ID.
 
Order::Ptr withTradeShared (std::int64_t tradeId) noexcept
 Changes trade ID.
 
OrderwithTradePrice (double tradePrice) noexcept
 Changes trade price.
 
Order::Ptr withTradePriceShared (double tradePrice) noexcept
 Changes trade price.
 
OrderwithTradeSize (double tradeSize) noexcept
 Changes trade size.
 
Order::Ptr withTradeSizeShared (double tradeSize) noexcept
 Changes trade size.
 
OrderwithExchangeCode (char exchangeCode) noexcept
 Changes exchange code of this order.
 
Order::Ptr withExchangeCodeShared (char exchangeCode) noexcept
 Changes exchange code of this order.
 
OrderwithExchangeCode (std::int16_t exchangeCode) noexcept
 Changes exchange code of this order.
 
Order::Ptr withExchangeCodeShared (std::int16_t exchangeCode) noexcept
 Changes exchange code of this order.
 
OrderwithOrderSide (const Side &side) noexcept
 Changes side of this order.
 
Order::Ptr withOrderSideShared (const Side &side) noexcept
 Changes side of this order.
 
OrderwithScope (const Scope &scope) noexcept
 Changes scope of this order.
 
Order::Ptr withScopeShared (const Scope &scope) noexcept
 Changes scope of this order.
 
const std::string & getMarketMaker () const &noexcept
 Returns market maker or other aggregate identifier of this order.
 
const std::optional< std::string > & getMarketMakerOpt () const &noexcept
 Returns market maker or other aggregate identifier of this order.
 
void setMarketMaker (std::string marketMaker) noexcept
 Changes market maker or other aggregate identifier of this order.
 
OrderwithMarketMaker (std::string marketMaker) noexcept
 Changes market maker or other aggregate identifier of this order.
 
Order::Ptr withMarketMakerShared (std::string marketMaker) noexcept
 Changes market maker or other aggregate identifier of this order.
 
std::string toString () const noexcept override
 Returns a string representation of the current object.
 
- Public Member Functions inherited from dxfcpp::OrderBase
 OrderBase () noexcept=default
 Creates new order event with default values.
 
 OrderBase (std::string eventSymbol) noexcept
 Creates new order event with the specified event symbol.
 
const OrderSourcegetSource () const &noexcept override
 Returns source of this event.
 
void setSource (const OrderSource &source) noexcept
 Changes source of this event.
 
std::int32_t getEventFlags () const noexcept override
 Returns transactional event flags.
 
EventFlagsMask getEventFlagsMask () const noexcept override
 Returns transactional event flags.
 
void setEventFlags (std::int32_t eventFlags) noexcept override
 Changes transactional event flags.
 
void setEventFlags (const EventFlagsMask &eventFlags) noexcept override
 Changes transactional event flags.
 
void setIndex (std::int64_t index) noexcept override
 Changes unique per-symbol index of this order.
 
std::int64_t getIndex () const noexcept override
 Returns unique per-symbol index of this order.
 
std::int64_t getTimeSequence () const noexcept
 Returns time and sequence of this order packaged into single long value.
 
void setTimeSequence (std::int64_t timeSequence) noexcept
 Changes time and sequence of this order.
 
std::int64_t getTime () const noexcept
 Returns time of this order.
 
void setTime (std::int64_t time) noexcept
 Changes time of this order.
 
void setTimeNanoPart (std::int32_t timeNanoPart) noexcept
 Changes microseconds and nanoseconds time part of this order.
 
std::int32_t getTimeNanoPart () const noexcept
 Returns microseconds and nanoseconds time part of this order.
 
std::int32_t getSequence () const noexcept
 Returns sequence number of this order to distinguish orders that have the same time.
 
void setSequence (std::int32_t sequence) noexcept
 Changes sequence number of this order.
 
std::int64_t getTimeNanos () const noexcept
 Returns time of this order in nanoseconds.
 
void setTimeNanos (std::int64_t timeNanos) noexcept
 Changes time of this order.
 
const OrderActiongetAction () const &noexcept
 Returns order action if available, otherwise - OrderAction::UNDEFINED.
 
void setAction (const OrderAction &action) noexcept
 Changes action of this order.
 
std::int64_t getActionTime () const noexcept
 Returns time of the last action.
 
void setActionTime (std::int64_t actionTime) noexcept
 Changes time of the last action.
 
std::int64_t getOrderId () const noexcept
 Returns order ID if available.
 
void setOrderId (std::int64_t orderId) noexcept
 Changes order ID.
 
std::int64_t getAuxOrderId () const noexcept
 Returns auxiliary order ID if available:
 
void setAuxOrderId (std::int64_t auxOrderId) noexcept
 Changes auxiliary order ID.
 
double getPrice () const noexcept
 Returns price of this order.
 
void setPrice (double price) noexcept
 Changes price of this order.
 
double getSize () const noexcept
 Returns size of this order.
 
void setSize (double size) noexcept
 Changes size of this order.
 
bool hasSize () const noexcept
 Returns true if this order has some size (sizeAsDouble is neither 0 nor NaN).
 
double getExecutedSize () const noexcept
 Returns executed size of this order.
 
void setExecutedSize (double executedSize) noexcept
 Changes executed size of this order.
 
std::int64_t getCount () const noexcept
 Returns number of individual orders in this aggregate order.
 
void setCount (std::int64_t count) noexcept
 Changes number of individual orders in this aggregate order.
 
std::int64_t getTradeId () const noexcept
 Returns trade (order execution) ID for events containing trade-related action.
 
void setTradeId (std::int64_t tradeId) noexcept
 Changes trade ID.
 
double getTradePrice () const noexcept
 Returns trade price for events containing trade-related action.
 
void setTradePrice (double tradePrice) noexcept
 Changes trade price.
 
double getTradeSize () const noexcept
 Returns trade size for events containing trade-related action.
 
void setTradeSize (double tradeSize) noexcept
 Changes trade size.
 
std::int16_t getExchangeCode () const noexcept
 Returns exchange code of this order.
 
std::string getExchangeCodeString () const noexcept
 Returns exchange code of this order as UTF8 string.
 
void setExchangeCode (char exchangeCode) noexcept
 Changes exchange code of this order.
 
void setExchangeCode (std::int16_t exchangeCode) noexcept
 Changes exchange code of this order.
 
const SidegetOrderSide () const &noexcept
 Returns side of this order.
 
void setOrderSide (const Side &side) noexcept
 Changes side of this order.
 
const ScopegetScope () const &noexcept
 Returns scope of this order.
 
void setScope (const Scope &scope) noexcept
 Changes scope of this order.
 
std::string baseFieldsToString () const noexcept
 Returns string representation of this order event's fields.
 
- Public Member Functions inherited from dxfcpp::MarketEvent
const std::string & getEventSymbol () const &noexcept override
 Returns symbol of this event.
 
const std::optional< std::string > & getEventSymbolOpt () const &noexcept override
 Returns symbol of this event.
 
void setEventSymbol (const std::string &eventSymbol) noexcept override
 Changes symbol of this event.
 
std::int64_t getEventTime () const noexcept override
 Returns time when event was created or zero when time is not available.
 
void setEventTime (std::int64_t eventTime) noexcept override
 Changes event creation time.
 
- Public Member Functions inherited from dxfcpp::SharedEntity
template<typename T >
bool is () const noexcept
 Checks that pointer to the current type could be converted to type T* In other words: whether type T belongs to the type hierarchy in which the current type resides.
 
template<typename T >
std::shared_ptr< T > sharedAs () noexcept
 Returns a pointer to the current object wrapped in a smart pointer to type T.
 
template<typename T >
std::shared_ptr< T > sharedAs () const noexcept
 Returns a pointer to the current object wrapped in a smart pointer to type T.
 
- Public Member Functions inherited from dxfcpp::Entity
virtual ~Entity () noexcept=default
 The default virtual d-tor.
 

Static Public Member Functions

static void freeGraal (void *graalNative) noexcept
 Releases the memory occupied by the dxFeed Graal SDK structure (recursively if necessary).
 

Static Public Attributes

static const EventTypeEnumTYPE = EventTypeEnum::ORDER
 Type identifier and additional information about the current event class.
 
- Static Public Attributes inherited from dxfcpp::OrderBase
static constexpr std::uint32_t MAX_SEQUENCE = (1U << 22U) - 1U
 Maximum allowed sequence value.
 
- Static Public Attributes inherited from dxfcpp::IndexedEvent
static const EventFlag TX_PENDING = EventFlag::TX_PENDING
 0x01 - A bitmask to get transaction pending indicator from the value of eventFlags property.
 
static const EventFlag REMOVE_EVENT = EventFlag::REMOVE_EVENT
 0x02 - A bitmask to get removal indicator from the value of eventFlags property.
 
static const EventFlag SNAPSHOT_BEGIN = EventFlag::SNAPSHOT_BEGIN
 0x04 - A bitmask to get snapshot begin indicator from the value of eventFlags property.
 
static const EventFlag SNAPSHOT_END = EventFlag::SNAPSHOT_END
 0x08 - A bitmask to get snapshot end indicator from the value of eventFlags property.
 
static const EventFlag SNAPSHOT_SNIP = EventFlag::SNAPSHOT_SNIP
 0x10 - A bitmask to get snapshot snip indicator from the value of eventFlags property.
 
static const EventFlag SNAPSHOT_MODE = EventFlag::SNAPSHOT_MODE
 0x40 - A bitmask to set snapshot mode indicator into the value of eventFlags property.
 

Additional Inherited Members

- Protected Member Functions inherited from dxfcpp::MarketEvent
 MarketEvent (std::string eventSymbol) noexcept
 Protected constructor for concrete implementation classes that initializes eventSymbol property.
 

Detailed Description

Order event is a snapshot for a full available market depth for a symbol.

The collection of order events of a symbol represents the most recent information that is available about orders on the market at any given moment of time. Order events give information on several levels of details, called scopes - see Scope. Scope of an order is available via scope property.

Order events arrive from multiple sources for the same market symbol and are distinguished by their index. Index is a unique per symbol identifier of the event. It is unique across all the sources of depth information for the symbol. The event with size either 0 or NaN is a signal to remove previously received order for the corresponding index. The method Order::hasSize() is a convenient method to test for size presence.

Events from finer-grained Scope of detail give more information and include events from coarse-grained Scope of detail. For a consistent representation of the market depth to the end-user, order events must be filtered to remove coarse-grained events that are superseded by the finer-grained events.

Event flags, transactions and snapshots

Some order event sources provide a consistent view of the price-level or detailed order book. Their updates may incorporate multiple changes to price levels or to individual orders that have to be processed at the same time. The corresponding information is carried in eventFlags property.

See Event Flags section of OrderBase class documentation for details.

The composite quotes with Scope::COMPOSITE and regional quotes with Scope::REGIONAL come individually from different venues and are not related to each other in any transactional way. The result of Order::getEventFlags method for them is always zero.

Publishing order books

When publishing an order event with DXPublisher::publishEvents() method, least significant 32 bits of order index must be in a range of from 0 to std::numeric_limits<std::int32_t>::max() inclusive. Use Order::setSource() method after Order::setIndex() to properly include source identifier into the index.

A snapshot has to be published in the descending order of index, starting with an event with the largest index and marking it with EventFlag::SNAPSHOT_BEGIN bit in eventFlags, and finishing the snapshot with an event that has zero 32 least significant bits of index. EventFlag::SNAPSHOT_END bit in eventFlags is optional during publishing. It will be properly set on receiving end anyway.

Limitations

This event type cannot be used with DXFeed::getLastEvent() method.

Full Order Book Support

Some feeds provide support for "Full Order Book" (FOB) where additional fields will be available:

Implementation details

This event is implemented on top of QDS record Quote for composite quotes with Scope::COMPOSITE, record Quote&X for regional exchange best quotes with Scope::REGIONAL, record MarketMaker for market-maker quotes and futures price level aggregates with Scope::AGGREGATE, record Order for the most fine-grained Scope::ORDER with zero source id, and records Order#<source-id> for specific source ids, where <source-id> is up to 4 ASCII characters with a mnemonic for the source like "NTV".

Constructor & Destructor Documentation

◆ Order()

dxfcpp::Order::Order ( std::string eventSymbol)
inlineexplicitnoexcept

Creates new order event with the specified event symbol.

Parameters
eventSymbolThe event symbol.

Member Function Documentation

◆ freeGraal()

void dxfcpp::Order::freeGraal ( void * graalNative)
staticnoexcept

Releases the memory occupied by the dxFeed Graal SDK structure (recursively if necessary).

Parameters
graalNativeThe pointer to the dxFeed Graal SDK structure.

◆ getMarketMaker()

const std::string & dxfcpp::Order::getMarketMaker ( ) const &
inlinenoexcept

Returns market maker or other aggregate identifier of this order.

This value is defined for Scope::AGGREGATE and Scope::ORDER orders.

Returns
market maker or other aggregate identifier of this order or dxfcpp::String::NUL (std::string{"<null>"}).

◆ getMarketMakerOpt()

const std::optional< std::string > & dxfcpp::Order::getMarketMakerOpt ( ) const &
inlinenoexcept

Returns market maker or other aggregate identifier of this order.

This value is defined for Scope::AGGREGATE and Scope::ORDER orders.

Returns
market maker or other aggregate identifier of this order or std::nullopt.

◆ setMarketMaker()

void dxfcpp::Order::setMarketMaker ( std::string marketMaker)
inlinenoexcept

Changes market maker or other aggregate identifier of this order.

Parameters
marketMakermarket maker or other aggregate identifier of this order.

◆ toGraal()

void * dxfcpp::Order::toGraal ( ) const
overridevirtualnoexcept

Allocates memory for the dxFeed Graal SDK structure (recursively if necessary).

Fills the dxFeed Graal SDK structure's fields by the data of the current entity (recursively if necessary). Returns the pointer to the filled structure.

Returns
The pointer to the filled dxFeed Graal SDK structure

Implements dxfcpp::EventType.

◆ toString()

std::string dxfcpp::Order::toString ( ) const
overridevirtualnoexcept

Returns a string representation of the current object.

Returns
a string representation

Reimplemented from dxfcpp::EventType.

◆ withAction()

Order & dxfcpp::Order::withAction ( const OrderAction & action)
inlinenoexcept

Changes action of this order and returns it.

Parameters
actionThe side of this order.
Returns
The current order.

◆ withActionShared()

Order::Ptr dxfcpp::Order::withActionShared ( const OrderAction & action)
inlinenoexcept

Changes action of this order.

Returns a shared pointer to the current order.

Warning
Please do not use this method unless the object was created with std::shared_ptr<Order>(new Order(...)) or std::make_shared<Order>(...)
Parameters
actionThe action of this order.
Returns
A shared pointer to the current order.

◆ withActionTime()

Order & dxfcpp::Order::withActionTime ( std::int64_t actionTime)
inlinenoexcept

Changes time of the last action and returns current order.

Parameters
actionTimeThe last order action time.
Returns
The current order.

◆ withActionTimeShared()

Order::Ptr dxfcpp::Order::withActionTimeShared ( std::int64_t actionTime)
inlinenoexcept

Changes time of the last action and returns a shared pointer to the current order.

Warning
Please do not use this method unless the object was created with std::shared_ptr<Order>(new Order(...)) or std::make_shared<Order>(...)
Parameters
actionTimeThe last order action time.
Returns
A shared pointer to the current order.

◆ withAuxOrderId()

Order & dxfcpp::Order::withAuxOrderId ( std::int64_t auxOrderId)
inlinenoexcept

Changes auxiliary order ID.

Returns the current order.

Parameters
auxOrderIdThe auxiliary order ID.
Returns
The current order.

◆ withAuxOrderIdShared()

Order::Ptr dxfcpp::Order::withAuxOrderIdShared ( std::int64_t auxOrderId)
inlinenoexcept

Changes auxiliary order ID.

Returns a shared pointer to the current order.

Warning
Please do not use this method unless the object was created with std::shared_ptr<Order>(new Order(...)) or std::make_shared<Order>(...)
Parameters
auxOrderIdThe auxiliary order ID.
Returns
A shared pointer to the current order.

◆ withCount()

Order & dxfcpp::Order::withCount ( std::int64_t count)
inlinenoexcept

Changes number of individual orders in this aggregate order.

Returns the current order.

Parameters
countThe number of individual orders in this aggregate order.
Returns
The current order.

◆ withCountShared()

Order::Ptr dxfcpp::Order::withCountShared ( std::int64_t count)
inlinenoexcept

Changes number of individual orders in this aggregate order.

Returns a shared pointer to the current order.

Warning
Please do not use this method unless the object was created with std::shared_ptr<Order>(new Order(...)) or std::make_shared<Order>(...)
Parameters
countThe number of individual orders in this aggregate order.
Returns
A shared pointer to the current order.

◆ withEventFlags() [1/2]

Order & dxfcpp::Order::withEventFlags ( const EventFlagsMask & eventFlags)
inlinenoexcept

Changes transactional event flags and returns the current order.

See EventFlag "Event Flags" section.

Parameters
eventFlagstransactional event flags' mask.
Returns
The current order.

◆ withEventFlags() [2/2]

Order & dxfcpp::Order::withEventFlags ( std::int32_t eventFlags)
inlinenoexcept

Changes transactional event flags and returns the current order.

See EventFlag "Event Flags" section.

Parameters
eventFlagstransactional event flags.
Returns
The current order.

◆ withEventFlagsShared() [1/2]

Order::Ptr dxfcpp::Order::withEventFlagsShared ( const EventFlagsMask & eventFlags)
inlinenoexcept

Changes transactional event flags and returns a shared pointer to the current order.

See EventFlag "Event Flags" section.

Warning
Please do not use this method unless the object was created with std::shared_ptr<Order>(new Order(...)) or std::make_shared<Order>(...)
Parameters
eventFlagstransactional event flags' mask.
Returns
A shared pointer to the current order.

◆ withEventFlagsShared() [2/2]

Order::Ptr dxfcpp::Order::withEventFlagsShared ( std::int32_t eventFlags)
inlinenoexcept

Changes transactional event flags and returns a shared pointer to the current order.

See EventFlag "Event Flags" section.

Warning
Please do not use this method unless the object was created with std::shared_ptr<Order>(new Order(...)) or std::make_shared<Order>(...)
Parameters
eventFlagstransactional event flags.
Returns
A shared pointer to the current order.

◆ withEventSymbol()

virtual Order & dxfcpp::Order::withEventSymbol ( const std::string & eventSymbol)
inlinevirtualnoexcept

Changes event's symbol and returns the current order.

Parameters
eventSymbolThe symbol of this event.
Returns
The current order.

Reimplemented in dxfcpp::AnalyticOrder.

◆ withEventSymbolShared()

Order::Ptr dxfcpp::Order::withEventSymbolShared ( const std::string & eventSymbol)
inlinenoexcept

Changes event's symbol and returns a shared pointer to the current order.

Warning
Please do not use this method unless the object was created with std::shared_ptr<Order>(new Order(...)) or std::make_shared<Order>(...)
Parameters
eventSymbolThe symbol of this event.
Returns
A shared pointer to the current order.

◆ withEventTime()

Order & dxfcpp::Order::withEventTime ( std::int64_t eventTime)
inlinenoexcept

Changes event's creation time and returns the current order.

Parameters
eventTimethe difference, measured in milliseconds, between the event creation time and midnight, January 1, 1970 UTC.
Returns
The current order.

◆ withEventTimeShared()

Order::Ptr dxfcpp::Order::withEventTimeShared ( std::int64_t eventTime)
inlinenoexcept

Changes event's creation time and returns a shared pointer to the current order.

Warning
Please do not use this method unless the object was created with std::shared_ptr<Order>(new Order(...)) or std::make_shared<Order>(...)
Parameters
eventTimethe difference, measured in milliseconds, between the event creation time and midnight, January 1, 1970 UTC.
Returns
A shared pointer to the current order.

◆ withExchangeCode() [1/2]

Order & dxfcpp::Order::withExchangeCode ( char exchangeCode)
inlinenoexcept

Changes exchange code of this order.

Returns the current order.

Parameters
exchangeCodeThe exchange code of this order.
Returns
The current order.

◆ withExchangeCode() [2/2]

Order & dxfcpp::Order::withExchangeCode ( std::int16_t exchangeCode)
inlinenoexcept

Changes exchange code of this order.

Returns the current order.

Parameters
exchangeCodeThe exchange code of this order.
Returns
The current order.

◆ withExchangeCodeShared() [1/2]

Order::Ptr dxfcpp::Order::withExchangeCodeShared ( char exchangeCode)
inlinenoexcept

Changes exchange code of this order.

Returns a shared pointer to the current order.

Warning
Please do not use this method unless the object was created with std::shared_ptr<Order>(new Order(...)) or std::make_shared<Order>(...)
Parameters
exchangeCodeThe exchange code of this order.
Returns
A shared pointer to the current order.

◆ withExchangeCodeShared() [2/2]

Order::Ptr dxfcpp::Order::withExchangeCodeShared ( std::int16_t exchangeCode)
inlinenoexcept

Changes exchange code of this order.

Returns a shared pointer to the current order.

Warning
Please do not use this method unless the object was created with std::shared_ptr<Order>(new Order(...)) or std::make_shared<Order>(...)
Parameters
exchangeCodeThe exchange code of this order.
Returns
A shared pointer to the current order.

◆ withExecutedSize()

Order & dxfcpp::Order::withExecutedSize ( double executedSize)
inlinenoexcept

Changes executed size of this order.

Returns the current order.

Parameters
executedSizeThe executed size of this order.
Returns
The current order.

◆ withExecutedSizeShared()

Order::Ptr dxfcpp::Order::withExecutedSizeShared ( double executedSize)
inlinenoexcept

Changes executed size of this order.

Returns a shared pointer to the current order.

Warning
Please do not use this method unless the object was created with std::shared_ptr<Order>(new Order(...)) or std::make_shared<Order>(...)
Parameters
executedSizeThe executed size of this order.
Returns
A shared pointer to the current order.

◆ withIndex()

Order & dxfcpp::Order::withIndex ( std::int64_t index)
inlinenoexcept

Changes unique per-symbol index of this order and returns it.

Note, that this method also changes source, whose id occupies highest bits of index. Use OrderBase::setSource() after invocation of this method to set the desired value of source.

Parameters
indexunique per-symbol index of this order.
Returns
The current order.

◆ withIndexShared()

Order::Ptr dxfcpp::Order::withIndexShared ( std::int64_t index)
inlinenoexcept

Changes unique per-symbol index of this order and returns a shared pointer to it.

Note, that this method also changes source, whose id occupies highest bits of index. Use OrderBase::setSource() after invocation of this method to set the desired value of source.

Warning
Please do not use this method unless the object was created with std::shared_ptr<Order>(new Order(...)) or std::make_shared<Order>(...)
Parameters
indexunique per-symbol index of this order.
Returns
A shared pointer to the current order.

◆ withMarketMaker()

Order & dxfcpp::Order::withMarketMaker ( std::string marketMaker)
inlinenoexcept

Changes market maker or other aggregate identifier of this order.

Returns the current order.

Parameters
marketMakerThe market maker or other aggregate identifier of this order.
Returns
The current order.

◆ withMarketMakerShared()

Order::Ptr dxfcpp::Order::withMarketMakerShared ( std::string marketMaker)
inlinenoexcept

Changes market maker or other aggregate identifier of this order.

Returns a shared pointer to the current order.

Warning
Please do not use this method unless the object was created with std::shared_ptr<Order>(new Order(...)) or std::make_shared<Order>(...)
Parameters
marketMakerThe market maker or other aggregate identifier of this order.
Returns
A shared pointer to the current order.

◆ withOrderId()

Order & dxfcpp::Order::withOrderId ( std::int64_t orderId)
inlinenoexcept

Changes order ID.

Returns the current order.

Parameters
orderIdThe order ID.
Returns
The current order.

◆ withOrderIdShared()

Order::Ptr dxfcpp::Order::withOrderIdShared ( std::int64_t orderId)
inlinenoexcept

Changes order ID.

Returns a shared pointer to the current order.

Warning
Please do not use this method unless the object was created with std::shared_ptr<Order>(new Order(...)) or std::make_shared<Order>(...)
Parameters
orderIdorder ID.
Returns
A shared pointer to the current order.

◆ withOrderSide()

Order & dxfcpp::Order::withOrderSide ( const Side & side)
inlinenoexcept

Changes side of this order.

Returns the current order.

Parameters
sideThe side of this order.
Returns
The current order.

◆ withOrderSideShared()

Order::Ptr dxfcpp::Order::withOrderSideShared ( const Side & side)
inlinenoexcept

Changes side of this order.

Returns a shared pointer to the current order.

Warning
Please do not use this method unless the object was created with std::shared_ptr<Order>(new Order(...)) or std::make_shared<Order>(...)
Parameters
sideThe side of this order.
Returns
A shared pointer to the current order.

◆ withPrice()

Order & dxfcpp::Order::withPrice ( double price)
inlinenoexcept

Changes price of this order.

Returns the current order.

Parameters
priceThe price of this order.
Returns
The current order.

◆ withPriceShared()

Order::Ptr dxfcpp::Order::withPriceShared ( double price)
inlinenoexcept

Changes price of this order.

Returns a shared pointer to the current order.

Warning
Please do not use this method unless the object was created with std::shared_ptr<Order>(new Order(...)) or std::make_shared<Order>(...)
Parameters
priceThe price of this order.
Returns
A shared pointer to the current order.

◆ withScope()

Order & dxfcpp::Order::withScope ( const Scope & scope)
inlinenoexcept

Changes scope of this order.

Returns the current order.

Parameters
scopeThe scope of this order.
Returns
The current order.

◆ withScopeShared()

Order::Ptr dxfcpp::Order::withScopeShared ( const Scope & scope)
inlinenoexcept

Changes scope of this order.

Returns a shared pointer to the current order.

Warning
Please do not use this method unless the object was created with std::shared_ptr<Order>(new Order(...)) or std::make_shared<Order>(...)
Parameters
scopeThe scope of this order.
Returns
A shared pointer to the current order.

◆ withSequence()

Order & dxfcpp::Order::withSequence ( std::int32_t sequence)
inlinenoexcept

Changes sequence number of this order.

Returns the current order.

Parameters
sequencethe sequence.
Returns
The current order.
See also
OrderBase::getSequence()

◆ withSequenceShared()

Order::Ptr dxfcpp::Order::withSequenceShared ( std::int32_t sequence)
inlinenoexcept

Changes sequence number of this order.

Returns a shared pointer to the current order.

Warning
Please do not use this method unless the object was created with std::shared_ptr<Order>(new Order(...)) or std::make_shared<Order>(...)
Parameters
sequencethe sequence.
Returns
A shared pointer to the current order.
See also
OrderBase::getSequence()

◆ withSize()

Order & dxfcpp::Order::withSize ( double size)
inlinenoexcept

Changes size of this order.

Returns the current order.

Parameters
sizeThe size of this order.
Returns
The current order.

◆ withSizeShared()

Order::Ptr dxfcpp::Order::withSizeShared ( double size)
inlinenoexcept

Changes size of this order.

Returns a shared pointer to the current order.

Warning
Please do not use this method unless the object was created with std::shared_ptr<Order>(new Order(...)) or std::make_shared<Order>(...)
Parameters
sizeThe size of this order.
Returns
A shared pointer to the current order.

◆ withSource()

Order & dxfcpp::Order::withSource ( const OrderSource & source)
inlinenoexcept

Changes event's source and returns the current order.

This method changes highest bits of the index of this event.

Parameters
sourcesource of this event.
Returns
The current order.

◆ withSourceShared()

Order::Ptr dxfcpp::Order::withSourceShared ( const OrderSource & source)
inlinenoexcept

Changes event's source and returns a shared pointer to the current order.

This method changes highest bits of the index of this event.

Warning
Please do not use this method unless the object was created with std::shared_ptr<Order>(new Order(...)) or std::make_shared<Order>(...)
Parameters
sourcesource of this event.
Returns
A shared pointer to the current order.

◆ withTime()

Order & dxfcpp::Order::withTime ( std::int64_t time)
inlinenoexcept

Changes time of this order and returns it.

Time is measured in milliseconds between the current time and midnight, January 1, 1970 UTC.

Parameters
timetime of this order.
Returns
The current order.

◆ withTimeNanoPart()

Order & dxfcpp::Order::withTimeNanoPart ( std::int32_t timeNanoPart)
inlinenoexcept

Changes microseconds and nanoseconds time part of this order.

Returns the current order.

Parameters
timeNanoPartmicroseconds and nanoseconds time part of this order.
Returns
The current order.

◆ withTimeNanoPartShared()

Order::Ptr dxfcpp::Order::withTimeNanoPartShared ( std::int32_t timeNanoPart)
inlinenoexcept

Changes microseconds and nanoseconds time part of this order.

Returns a shared pointer to the current order.

Warning
Please do not use this method unless the object was created with std::shared_ptr<Order>(new Order(...)) or std::make_shared<Order>(...)
Parameters
timeNanoPartmicroseconds and nanoseconds time part of this order.
Returns
A shared pointer to the current order.

◆ withTimeNanos()

Order & dxfcpp::Order::withTimeNanos ( std::int64_t timeNanos)
inlinenoexcept

Changes time of this order and returns it.

Time is measured in nanoseconds between the current time and midnight, January 1, 1970 UTC.

Parameters
timeNanosThe time of this order in nanoseconds.
Returns
The current order.

◆ withTimeNanosShared()

Order::Ptr dxfcpp::Order::withTimeNanosShared ( std::int64_t timeNanos)
inlinenoexcept

Changes time of this order.

Returns a shared pointer to the current order. Time is measured in nanoseconds between the current time and midnight, January 1, 1970 UTC.

Warning
Please do not use this method unless the object was created with std::shared_ptr<Order>(new Order(...)) or std::make_shared<Order>(...)
Parameters
timeNanostime of this order in nanoseconds.
Returns
A shared pointer to the current order.

◆ withTimeShared()

Order::Ptr dxfcpp::Order::withTimeShared ( std::int64_t time)
inlinenoexcept

Changes time of this order and returns a shared pointer to it.

Time is measured in milliseconds between the current time and midnight, January 1, 1970 UTC.

Warning
Please do not use this method unless the object was created with std::shared_ptr<Order>(new Order(...)) or std::make_shared<Order>(...)
Parameters
timetime of this order.
Returns
A shared pointer to the current order.

◆ withTradeId()

Order & dxfcpp::Order::withTradeId ( std::int64_t tradeId)
inlinenoexcept

Changes trade ID.

Returns the current order.

Parameters
tradeIdThe trade ID.
Returns
The current order.

◆ withTradePrice()

Order & dxfcpp::Order::withTradePrice ( double tradePrice)
inlinenoexcept

Changes trade price.

Returns the current order.

Parameters
tradePriceThe trade price.
Returns
The current order.

◆ withTradePriceShared()

Order::Ptr dxfcpp::Order::withTradePriceShared ( double tradePrice)
inlinenoexcept

Changes trade price.

Returns a shared pointer to the current order.

Warning
Please do not use this method unless the object was created with std::shared_ptr<Order>(new Order(...)) or std::make_shared<Order>(...)
Parameters
tradePriceThe trade price.
Returns
A shared pointer to the current order.

◆ withTradeShared()

Order::Ptr dxfcpp::Order::withTradeShared ( std::int64_t tradeId)
inlinenoexcept

Changes trade ID.

Returns a shared pointer to the current order.

Warning
Please do not use this method unless the object was created with std::shared_ptr<Order>(new Order(...)) or std::make_shared<Order>(...)
Parameters
tradeIdThe trade ID.
Returns
A shared pointer to the current order.

◆ withTradeSize()

Order & dxfcpp::Order::withTradeSize ( double tradeSize)
inlinenoexcept

Changes trade size.

Returns the current order.

Parameters
tradeSizeThe trade size.
Returns
The current order.

◆ withTradeSizeShared()

Order::Ptr dxfcpp::Order::withTradeSizeShared ( double tradeSize)
inlinenoexcept

Changes trade size.

Returns a shared pointer to the current order.

Warning
Please do not use this method unless the object was created with std::shared_ptr<Order>(new Order(...)) or std::make_shared<Order>(...)
Parameters
tradeSizeThe trade size.
Returns
A shared pointer to the current order.