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

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

Public Member Functions

constexpr DirectPriceLevel () noexcept=default
constexpr DirectPriceLevel (const DirectPriceLevel &other) noexcept=default
constexpr DirectPriceLevel (DirectPriceLevel &&other) noexcept=default
constexpr DirectPriceLevel (const Messaging::Decimal &price, Messaging::Int32 qty, Messaging::Int32 ordersQty) noexcept
 ~DirectPriceLevel ()=default
Messaging::Int32 & numberOfOrders () noexcept
constexpr Messaging::Int32 numberOfOrders () const noexcept
DirectPriceLevel & operator= (const DirectPriceLevel &other) noexcept=default
DirectPriceLevel & operator= (DirectPriceLevel &&other) noexcept=default
Public Member Functions inherited from ImpliedPriceLevel
constexpr ImpliedPriceLevel () noexcept=default
constexpr ImpliedPriceLevel (const ImpliedPriceLevel &other) noexcept=default
constexpr ImpliedPriceLevel (ImpliedPriceLevel &&other) noexcept=default
constexpr ImpliedPriceLevel (const Messaging::Decimal &price, MbpBookQuantity qty) noexcept
 ~ImpliedPriceLevel ()=default
constexpr bool exist () const noexcept
bool & exist () noexcept
constexpr const Messaging::Decimal & price () const noexcept
Messaging::Decimal & price () noexcept
constexpr MbpBookQuantity quantity () const noexcept
MbpBookQuantity & quantity () noexcept
ImpliedPriceLevel & operator= (const ImpliedPriceLevel &other) noexcept=default
ImpliedPriceLevel & operator= (ImpliedPriceLevel &&other) noexcept=default

Detailed Description

Stores direct price level data, including the aggregate quantity inherited from ImpliedPriceLevel and the number of orders available at the level.

Definition at line 31 of file DirectPriceLevel.h.

Constructor & Destructor Documentation

◆ DirectPriceLevel() [1/4]

DirectPriceLevel ( )
constexprdefaultnoexcept

Constructs an absent price level.

◆ DirectPriceLevel() [2/4]

DirectPriceLevel ( const DirectPriceLevel & other)
constexprdefaultnoexcept

Constructs a price level as a copy of another instance.

Parameters
otherPrice level whose state is copied.

◆ DirectPriceLevel() [3/4]

DirectPriceLevel ( DirectPriceLevel && other)
constexprdefaultnoexcept

Constructs a price level by moving another instance.

Parameters
otherPrice level whose state is moved.

◆ DirectPriceLevel() [4/4]

DirectPriceLevel ( const Messaging::Decimal & price,
Messaging::Int32 qty,
Messaging::Int32 ordersQty )
inlineconstexprnoexcept

Constructs a present price level with the specified attributes.

Parameters
pricePrice value for the level.
qtyAggregate quantity available at the level.
ordersQtyNumber of orders available at the level.

Definition at line 49 of file DirectPriceLevel.h.

◆ ~DirectPriceLevel()

~DirectPriceLevel ( )
default

Destroys the price level.

Member Function Documentation

◆ numberOfOrders() [1/2]

Messaging::Int32 numberOfOrders ( ) const
inlineconstexprnoexcept

Gets the number of orders at the level.

Returns
Number of orders available at the level.
Note
The returned value is meaningful as book data only when exist() returns true. Absent levels retain a stored/default value.

Definition at line 75 of file DirectPriceLevel.h.

◆ numberOfOrders() [2/2]

Messaging::Int32 & numberOfOrders ( )
inlinenoexcept

Provides mutable access to the number of orders at the level.

Returns
Reference to the number of orders stored for the level.
Note
Changing the number of orders does not change the presence flag returned by exist(). If the level is absent, the modified value remains stored but is not meaningful as book data until the level is marked present.

Definition at line 64 of file DirectPriceLevel.h.

◆ operator=() [1/2]

DirectPriceLevel & operator= ( const DirectPriceLevel & other)
defaultnoexcept

Replaces this price level with a copy of another instance.

Parameters
otherPrice level whose state is copied.
Returns
Reference to this price level.

◆ operator=() [2/2]

DirectPriceLevel & operator= ( DirectPriceLevel && other)
defaultnoexcept

Replaces this price level by moving another instance.

Parameters
otherPrice level whose state is moved.
Returns
Reference to this price level.