OnixS C++ CME MDP Premium Market Data Handler 5.11.1
Users' manual and API documentation
Loading...
Searching...
No Matches
Order Class Reference

#include <OnixS/CME/MDH/Order.h>

Public Member Functions

constexpr Order () noexcept=default
constexpr Order (OrderId id, OrderPriority priority, const Messaging::Decimal &price, DisplayQuantity quantity) noexcept
constexpr OrderId id () const noexcept
void id (OrderId id) noexcept
constexpr OrderPriority priority () const noexcept
void priority (OrderPriority priority) noexcept
constexpr const Messaging::Decimal & price () const noexcept
void price (const Messaging::Decimal &price) noexcept
constexpr DisplayQuantity quantity () const noexcept
void quantity (DisplayQuantity quantity) noexcept

Protected Attributes

OrderId id_ {OrderTraits::nullId()}
OrderPriority priority_ {OrderTraits::nullPriority()}
Messaging::Decimal price_ {OrderTraits::nullPriceMantissa(), 0}
DisplayQuantity quantity_ {OrderTraits::nullQuantity()}

Detailed Description

Stores the order identifier, matching priority, price, and displayed quantity. A default-constructed instance has null values for all attributes.

Definition at line 91 of file Order.h.

Constructor & Destructor Documentation

◆ Order() [1/2]

Order ( )
constexprdefaultnoexcept

Constructs an order with all attributes set to their null values.

◆ Order() [2/2]

Order ( OrderId id,
OrderPriority priority,
const Messaging::Decimal & price,
DisplayQuantity quantity )
inlineconstexprnoexcept

Constructs an order with the specified attributes.

Parameters
idOrder identifier.
priorityMatching priority of the order.
pricePrice of the order.
quantityDisplayed quantity of the order.

Definition at line 102 of file Order.h.

Member Function Documentation

◆ id() [1/2]

OrderId id ( ) const
inlineconstexprnoexcept

Gets the order identifier.

Returns
Identifier of the order.

Definition at line 113 of file Order.h.

◆ id() [2/2]

void id ( OrderId id)
inlinenoexcept

Sets the order identifier.

Parameters
idNew order identifier.

Definition at line 120 of file Order.h.

◆ price() [1/2]

const Messaging::Decimal & price ( ) const
inlineconstexprnoexcept

Gets the order price.

Returns
Price of the order.

Definition at line 143 of file Order.h.

◆ price() [2/2]

void price ( const Messaging::Decimal & price)
inlinenoexcept

Sets the order price.

Parameters
priceNew order price.

Definition at line 150 of file Order.h.

◆ priority() [1/2]

OrderPriority priority ( ) const
inlineconstexprnoexcept

Gets the matching priority.

Returns
Matching priority of the order.

Definition at line 128 of file Order.h.

◆ priority() [2/2]

void priority ( OrderPriority priority)
inlinenoexcept

Sets the matching priority.

Parameters
priorityNew matching priority.

Definition at line 135 of file Order.h.

◆ quantity() [1/2]

DisplayQuantity quantity ( ) const
inlineconstexprnoexcept

Gets the displayed quantity.

Returns
Displayed quantity of the order.

Definition at line 158 of file Order.h.

◆ quantity() [2/2]

void quantity ( DisplayQuantity quantity)
inlinenoexcept

Sets the displayed quantity.

Parameters
quantityNew displayed quantity.

Definition at line 165 of file Order.h.

Member Data Documentation

◆ id_

OrderId id_ {OrderTraits::nullId()}
protected

Definition at line 171 of file Order.h.

◆ price_

Definition at line 174 of file Order.h.

◆ priority_

OrderPriority priority_ {OrderTraits::nullPriority()}
protected

Definition at line 172 of file Order.h.

◆ quantity_

DisplayQuantity quantity_ {OrderTraits::nullQuantity()}
protected

Definition at line 175 of file Order.h.