BetaTrader
A HFT Eco-System
Loading...
Searching...
No Matches
CancelOrder.h
Go to the documentation of this file.
1//
2// Created by sujal on 21-10-2025.
3//
4
5#pragma once
6#include "common/Order.h"
9
10namespace trading_core {
18 class CancelOrder : public Command {
19 public:
26 explicit CancelOrder(const common::ClientID& clientId,
27 const common::Timestamp timestamp,
28 const common::OrderID orderId)
29 : Command(CommandType::CancelOrder, clientId, timestamp),
30 mOrderId(orderId) {};
31
33 [[nodiscard]] common::OrderID getOrderId() const { return mOrderId; }
34
35 private:
37 };
38} // namespace trading_core
A command to cancel an existing order in the trading engine.
Definition CancelOrder.h:18
common::OrderID getOrderId() const
Gets the ID of the order to be cancelled.
Definition CancelOrder.h:33
common::OrderID mOrderId
The ID of the order to be cancelled.
Definition CancelOrder.h:36
CancelOrder(const common::ClientID &clientId, const common::Timestamp timestamp, const common::OrderID orderId)
Constructs a new CancelOrder command.
Definition CancelOrder.h:26
An internal representation of a request, converted from an FIX message into this object for faster pr...
Definition Command.h:22
std::chrono::system_clock::time_point Timestamp
A type alias for std::chrono::system_clock::time_point.
Definition Time.h:15
uint64_t OrderID
A type alias for unique order identifiers.
Definition Types.h:134
std::string ClientID
A type alias for client identifiers.
Definition Types.h:140
Definition CancelOrder.h:10
CommandType
Represents the different types of commands that can be processed by the trading engine.
Definition CommandType.h:13