|
OpenPit C++ SDK
C++17 SDK for the OpenPit pre-trade risk engine
|
Fixed-point leverage multiplier with one decimal place. More...
Public Member Functions | |
| Notional | CalculateMarginRequired (const Notional ¬ional) const |
| Calculates margin required for the supplied notional. More... | |
| constexpr bool | IsSet () const noexcept |
| constexpr | Leverage () noexcept=default |
| constexpr bool | operator!= (const Leverage &other) const noexcept |
| constexpr bool | operator< (const Leverage &other) const noexcept |
| constexpr bool | operator<= (const Leverage &other) const noexcept |
| constexpr bool | operator== (const Leverage &other) const noexcept |
| constexpr bool | operator> (const Leverage &other) const noexcept |
| constexpr bool | operator>= (const Leverage &other) const noexcept |
| std::string | ToString () const |
| constexpr float | Value () const noexcept |
Static Public Member Functions | |
| static Leverage | FromFloat (float multiplier) |
| Creates a finite multiplier rounded to the fixed-point scale. More... | |
| static Leverage | FromUint16 (std::uint16_t multiplier) |
| Creates an integral leverage multiplier. More... | |
Static Public Attributes | |
| static constexpr std::uint16_t | Max = 3000 |
| static constexpr std::uint16_t | Min = 1 |
| static constexpr std::uint16_t | NotSet = 0 |
| static constexpr std::uint16_t | Scale = 10 |
| static constexpr float | Step = 0.1F |
Fixed-point leverage multiplier with one decimal place.
|
constexprdefaultnoexcept |
|
inline |
Calculates margin required for the supplied notional.
|
inlinestatic |
Creates a finite multiplier rounded to the fixed-point scale.
|
inlinestatic |
Creates an integral leverage multiplier.
|
inlineconstexprnoexcept |
|
inlineconstexprnoexcept |
|
inlineconstexprnoexcept |
|
inlineconstexprnoexcept |
|
inlineconstexprnoexcept |
|
inlineconstexprnoexcept |
|
inlineconstexprnoexcept |
|
inline |
|
inlineconstexprnoexcept |
|
staticconstexpr |
|
staticconstexpr |
|
staticconstexpr |
|
staticconstexpr |
|
staticconstexpr |