![]() |
MarketFactory C# API 3.0
|
A thin immutable wrapper for a floating point number. More...
Public Member Functions | |
| MFDecimal (string s) | |
| Constructor which accepts a string value. More... | |
| MFDecimal | abs () |
| Absolute value. More... | |
| int | CompareTo (Object o) |
| Implements Comparable method compareTo. More... | |
| bool | Equals (MFDecimal o) |
| Comparison operator: equal. More... | |
| bool | gt (MFDecimal o) |
| Comparison operator: greater-than. More... | |
| bool | gte (MFDecimal o) |
| Comparison operator: greater-than or equal. More... | |
| bool | lt (MFDecimal o) |
| Comparison operator: less-than. More... | |
| bool | lte (MFDecimal o) |
| Comparison operator: less-than or equal. More... | |
| MFDecimal | neg () |
| Negate value. More... | |
| double | toDouble () |
| Convert the value. More... | |
| long | toLong () |
| Convert the value. More... | |
| override string | ToString () |
| Provide access to the raw value. More... | |
Static Public Member Functions | |
| static bool | isValid (MFDecimal o) |
| Check if MFDecimal object has valid value. More... | |
| static MFDecimal | valueOf (string s) |
| Returns a MFDecimal object for the given representation of a FP number. More... | |
| static MFDecimal | valueOf (decimal num) |
| Returns a MFDecimal object for the given representation of a FP number. More... | |
| static MFDecimal | valueOf (double num) |
| Returns a MFDecimal object for the given representation of a FP number. More... | |
| static MFDecimal | valueOf (long num) |
| Returns a MFDecimal object for the given representation of a FP number. More... | |
Static Public Attributes | |
| static MFDecimal | NA = new MFDecimal("NA") |
| Special value: Not Applicable. More... | |
| static MFDecimal | NDA = new MFDecimal("NDA") |
| Special value: No Data Available. More... | |
| static MFDecimal | NMA = new MFDecimal("NMA") |
| Special value: No Market Available. More... | |
| static MFDecimal | ZERO = new MFDecimal("0") |
| Special value: Zero (as a convenience). More... | |
A thin immutable wrapper for a floating point number.
Must be 15 digits or less.
| MFDecimal | ( | string | s | ) |
Constructor which accepts a string value.
|
static |
Returns a MFDecimal object for the given representation of a FP number.
|
static |
Returns a MFDecimal object for the given representation of a FP number.
|
static |
Returns a MFDecimal object for the given representation of a FP number.
|
static |
Returns a MFDecimal object for the given representation of a FP number.
| long toLong | ( | ) |
Convert the value.
Will throw NotSupportedException if not valid. Will throw FormatException if value is out of range.
| double toDouble | ( | ) |
Convert the value.
Will throw NotSupportedException if not valid.
| override string ToString | ( | ) |
Provide access to the raw value.
| bool Equals | ( | MFDecimal | o | ) |
Comparison operator: equal.
| bool lte | ( | MFDecimal | o | ) |
Comparison operator: less-than or equal.
Will throw NotSupportedException if either of the objects is not valid.
| bool gte | ( | MFDecimal | o | ) |
Comparison operator: greater-than or equal.
Will throw NotSupportedException if either of the objects is not valid.
| bool lt | ( | MFDecimal | o | ) |
Comparison operator: less-than.
Will throw NotSupportedException if either of the objects is not valid.
| bool gt | ( | MFDecimal | o | ) |
Comparison operator: greater-than.
Will throw NotSupportedException if either of the objects is not valid.
| MFDecimal neg | ( | ) |
Negate value.
| MFDecimal abs | ( | ) |
Absolute value.
| int CompareTo | ( | Object | o | ) |
Implements Comparable method compareTo.