tntdb  1.3
tntdb::Decimal Class Reference

Public Types

typedef long LongType
 
typedef unsigned long UnsignedLongType
 

Public Member Functions

 Decimal (long double value)
 
 Decimal (const std::string &value)
 
 Decimal (long mantissa, short exponent)
 
const std::string & mantissa () const
 
short exponent () const
 
bool negative () const
 
bool isInfinity (bool positiveInfinity=true) const
 
bool isPositiveInfinity () const
 
bool isNegativeInfinity () const
 
bool isNaN () const
 
bool isZero () const
 
void setDouble (long double value)
 
long double getDouble () const
 
void setInteger (short l, short exponent=0)
 
void setInteger (int l, short exponent=0)
 
void setInteger (long l, short exponent=0)
 
void setInteger (long long l, short exponent=0)
 
void setInteger (unsigned short l, short exponent=0)
 
void setInteger (unsigned int l, short exponent=0)
 
void setInteger (unsigned long l, short exponent=0)
 
void setInteger (unsigned long long l, short exponent=0)
 
template<typename IntType >
IntType getInteger () const
 
std::string toString () const
 
std::string toStringSci () const
 
std::string toStringFix () const
 
Decimal operator- () const
 
bool operator== (const Decimal &other) const
 
bool operator!= (const Decimal &other) const
 
bool operator< (const Decimal &other) const
 
bool operator> (const Decimal &other) const
 
bool operator<= (const Decimal &other) const
 
bool operator>= (const Decimal &other) const
 

Static Public Member Functions

static Decimal infinity ()
 
static Decimal nan ()
 

Friends

class Parser
 

The documentation for this class was generated from the following file: