Orderbook Simulation
OrderbookSim is a C++ application simulating a financial market order book. It efficiently manages and matches buy and sell orders while calculating the Volume-Weighted Average Price (VWAP).
|
Defines the OrderType enum and related utility functions for handling different order types. More...
#include <string>
Go to the source code of this file.
Enumerations | |
enum class | OrderType { GoodTillCancel , FillAndKill , Market , GoodForDay , FillOrKill } |
Specifies the different types of orders that can be used in a trading system. More... | |
Functions | |
std::string | orderTypeToString (OrderType type) |
Converts an OrderType to its corresponding string representation. More... | |
OrderType | intToOrdertType (int type) |
Converts an integer value to the corresponding OrderType. More... | |
Defines the OrderType enum and related utility functions for handling different order types.
The OrderType enum represents various types of orders in a trading system, and utility functions are provided to convert between the enum and string representations or integer values.
|
strong |
Specifies the different types of orders that can be used in a trading system.
Each type of order has specific rules for how it should be handled in the order book.
|
inline |
Converts an integer value to the corresponding OrderType.
This function maps integer values to OrderType values, allowing for easy conversions from user inputs or data sources where order types are represented by integers.
type | An integer representing the order type. |
|
inline |
Converts an OrderType to its corresponding string representation.
This function provides a string representation of each order type for easier display and logging.
type | The OrderType to convert to a string. |