Slick OrderBook 1.1.0
High-Performance C++23 OrderBook Library
Loading...
Searching...
No Matches
slick::orderbook::OrderUpdate Struct Reference

Level 3 order update event Note: quantity = 0 implies the order should be deleted. More...

#include <events.hpp>

Collaboration diagram for slick::orderbook::OrderUpdate:

Public Member Functions

 OrderUpdate () noexcept=default
 
 OrderUpdate (SymbolId sym, OrderId id, Side s, Price p, Quantity q, Price op, Quantity oq, Timestamp ts, uint16_t idx=0, uint64_t prio=0, uint8_t flags=0, uint64_t seq=0) noexcept
 
constexpr bool isDelete () const noexcept
 Check if this is a delete action.
 
constexpr bool priceChanged () const noexcept
 Check if price changed (order was added or moved to different price)
 
constexpr bool quantityChanged () const noexcept
 Check if quantity changed.
 
constexpr bool isTopN (uint16_t n) const noexcept
 Check if this order's price level is in the top N levels.
 
constexpr bool isLastInBatch () const noexcept
 Check if this is the last update in a batch.
 

Public Attributes

Timestamp timestamp
 
uint64_t seq_num
 
OrderId order_id
 
Price price
 
Quantity quantity
 
Price old_price
 
Quantity old_qty
 
SymbolId symbol
 
uint16_t price_level_index
 
uint64_t priority
 
Side side
 
uint8_t change_flags
 

Detailed Description

Level 3 order update event Note: quantity = 0 implies the order should be deleted.

Definition at line 67 of file events.hpp.

Constructor & Destructor Documentation

◆ OrderUpdate() [1/2]

slick::orderbook::OrderUpdate::OrderUpdate ( )
defaultnoexcept

◆ OrderUpdate() [2/2]

slick::orderbook::OrderUpdate::OrderUpdate ( SymbolId  sym,
OrderId  id,
Side  s,
Price  p,
Quantity  q,
Price  op,
Quantity  oq,
Timestamp  ts,
uint16_t  idx = 0,
uint64_t  prio = 0,
uint8_t  flags = 0,
uint64_t  seq = 0 
)
inlinenoexcept

Definition at line 83 of file events.hpp.

Member Function Documentation

◆ isDelete()

constexpr bool slick::orderbook::OrderUpdate::isDelete ( ) const
inlineconstexprnoexcept

Check if this is a delete action.

Definition at line 89 of file events.hpp.

◆ isLastInBatch()

constexpr bool slick::orderbook::OrderUpdate::isLastInBatch ( ) const
inlineconstexprnoexcept

Check if this is the last update in a batch.

Definition at line 109 of file events.hpp.

References slick::orderbook::LastInBatch.

◆ isTopN()

constexpr bool slick::orderbook::OrderUpdate::isTopN ( uint16_t  n) const
inlineconstexprnoexcept

Check if this order's price level is in the top N levels.

Definition at line 104 of file events.hpp.

◆ priceChanged()

constexpr bool slick::orderbook::OrderUpdate::priceChanged ( ) const
inlineconstexprnoexcept

Check if price changed (order was added or moved to different price)

Definition at line 94 of file events.hpp.

References slick::orderbook::PriceChanged.

◆ quantityChanged()

constexpr bool slick::orderbook::OrderUpdate::quantityChanged ( ) const
inlineconstexprnoexcept

Check if quantity changed.

Definition at line 99 of file events.hpp.

References slick::orderbook::QuantityChanged.

Member Data Documentation

◆ change_flags

uint8_t slick::orderbook::OrderUpdate::change_flags

Definition at line 79 of file events.hpp.

◆ old_price

Price slick::orderbook::OrderUpdate::old_price

Definition at line 73 of file events.hpp.

◆ old_qty

Quantity slick::orderbook::OrderUpdate::old_qty

Definition at line 74 of file events.hpp.

◆ order_id

OrderId slick::orderbook::OrderUpdate::order_id

Definition at line 70 of file events.hpp.

Referenced by slick::orderbook::OrderBookL3::emitSnapshot().

◆ price

Price slick::orderbook::OrderUpdate::price

Definition at line 71 of file events.hpp.

◆ price_level_index

uint16_t slick::orderbook::OrderUpdate::price_level_index

Definition at line 76 of file events.hpp.

◆ priority

uint64_t slick::orderbook::OrderUpdate::priority

Definition at line 77 of file events.hpp.

◆ quantity

Quantity slick::orderbook::OrderUpdate::quantity

Definition at line 72 of file events.hpp.

◆ seq_num

uint64_t slick::orderbook::OrderUpdate::seq_num

Definition at line 69 of file events.hpp.

◆ side

Side slick::orderbook::OrderUpdate::side

Definition at line 78 of file events.hpp.

◆ symbol

SymbolId slick::orderbook::OrderUpdate::symbol

Definition at line 75 of file events.hpp.

◆ timestamp

Timestamp slick::orderbook::OrderUpdate::timestamp

Definition at line 68 of file events.hpp.


The documentation for this struct was generated from the following file: