cloudbilling
v1
|
#include <money.h>
Public Member Functions | |
Money (const Json::Value &storage) | |
Money (Json::Value *storage) | |
virtual | ~Money () |
const StringPiece | GetTypeName () const |
bool | has_currency_code () const |
void | clear_currency_code () |
const StringPiece | get_currency_code () const |
void | set_currency_code (const StringPiece &value) |
bool | has_nanos () const |
void | clear_nanos () |
int32 | get_nanos () const |
void | set_nanos (int32 value) |
bool | has_units () const |
void | clear_units () |
int64 | get_units () const |
void | set_units (int64 value) |
Static Public Member Functions | |
static Money * | New () |
Represents an amount of money with its currency type.
|
explicit |
Standard constructor for an immutable data object instance.
[in] | storage | The underlying data storage for this instance. |
|
explicit |
Standard constructor for a mutable data object instance.
[in] | storage | The underlying data storage for this instance. |
|
virtual |
Standard destructor.
|
inline |
Clears the 'currencyCode
' attribute.
|
inline |
Clears the 'nanos
' attribute.
|
inline |
Clears the 'units
' attribute.
|
inline |
Get the value of the 'currencyCode
' attribute.
|
inline |
Get the value of the 'nanos
' attribute.
|
inline |
Get the value of the 'units
' attribute.
|
inline |
Returns a string denoting the type of this data object.
|
inline |
Determine if the 'currencyCode
' attribute was set.
currencyCode
' attribute was set.
|
inline |
Determine if the 'nanos
' attribute was set.
nanos
' attribute was set.
|
inline |
Determine if the 'units
' attribute was set.
units
' attribute was set.
|
static |
Creates a new default instance.
|
inline |
Change the 'currencyCode
' attribute.
The 3-letter currency code defined in ISO 4217.
[in] | value | The new value. |
|
inline |
Change the 'nanos
' attribute.
Number of nano (10^-9) units of the amount. The value must be between -999,999,999 and +999,999,999 inclusive. If units
is positive, nanos
must be positive or zero. If units
is zero, nanos
can be positive, zero, or negative. If units
is negative, nanos
must be negative or zero. For example $-1.75 is represented as units
=-1 and nanos
=-750,000,000.
[in] | value | The new value. |
|
inline |
Change the 'units
' attribute.
The whole units of the amount. For example if currencyCode
is "USD"
, then 1 unit is one US dollar.
[in] | value | The new value. |