33 PriceSize(sbe_int64_t price_, sbe_int64_t quantity_) {
60 std::string returnString;
62 double pricen = std::pow(10.0, -9) * price;
63 double qtyn = std::pow(10.0, -5) * quantity;
75 std::string returnString;
77 returnString =
"price: " +
100 template <
typename T>
103 std::stringstream stream;
double quantityToDouble()
Get the double representation of quantity.
Definition: PriceSize.hpp:94
PriceSize(const PriceSize &p2)
A deep copy Copy Constructor
Definition: PriceSize.hpp:41
void setPrice(sbe_int64_t price_)
Set a new price value
Definition: PriceSize.hpp:46
std::string ToString(T val)
Stringize a type using the standard sstream formatting.
Definition: PriceSize.hpp:101
static const int64_t QTY_EXPONENT
The number of decimal places in the quantity type.
Definition: PriceSize.hpp:21
std::string toString()
Stringize PriceSize showing stringized decimals.
Definition: PriceSize.hpp:58
double priceToDouble()
Get the double representation of price.
Definition: PriceSize.hpp:88
static const int64_t PRICE_EXPONENT
The number of decimal places in the price type.
Definition: PriceSize.hpp:24
PriceSize(sbe_int64_t price_, sbe_int64_t quantity_)
The constructor that initializes price and quantity to the passed values.
Definition: PriceSize.hpp:33
void setQuantity(sbe_int64_t quantity_)
Set a new quantity value
Definition: PriceSize.hpp:53
std::string toRawString()
Stringize PriceSize showing the raw data member price and quantity values.
Definition: PriceSize.hpp:74
PriceSize()
Default constructor that initializes price and quantity to 0.
Definition: PriceSize.hpp:27
Definition: PriceSize.hpp:12