#include <ot_num.h>
Public Member Functions | |
virtual | ~ot_num () |
destructor | |
bool | operator== (const ot_obj *o) const |
Eq operator. | |
void | asXml (ostream &s=cout, int i=0) const |
bool | asData (ostream &s) const |
const X | get (void) const |
Protected Member Functions | |
ot_num (OT_OBJECT_TYPE t, X val) | |
Protected Attributes | |
X | m_value |
Value. |
Base class for the numeric object type
Get object type
t | The object type object | |
val | X value |
Print the XML rappresentation of object into output stream
s | The output stream | |
i | The indent spaces |
Implements ot_obj.
References ot_obj::getType(), ot_num< X >::m_value, ot_lib::OT_FLOAT, and ot_lib::OT_INT.
bool ot_num< X >::asData | ( | ostream & | s | ) | const [inline, virtual] |
Build a binary image of data object
s | The output stream |
Implements ot_obj.
References ot_obj::getType(), and ot_num< X >::m_value.
const X ot_num< X >::get | ( | void | ) | const [inline] |
Get X value
Value.
Referenced by ot_num< X >::asData(), ot_num< X >::asXml(), ot_num< unsigned int >::get(), ot_uint::operator*(), ot_int::operator*(), ot_float::operator*(), ot_uint::operator*=(), ot_int::operator*=(), ot_float::operator*=(), ot_uint::operator+(), ot_int::operator+(), ot_float::operator+(), ot_uint::operator+=(), ot_int::operator+=(), ot_float::operator+=(), ot_uint::operator-(), ot_int::operator-(), ot_float::operator-(), ot_uint::operator-=(), ot_int::operator-=(), ot_float::operator-=(), ot_uint::operator/(), ot_int::operator/(), ot_float::operator/(), ot_uint::operator/=(), ot_int::operator/=(), ot_float::operator/=(), ot_uint::operator=(), ot_int::operator=(), ot_float::operator=(), ot_uint::operator==(), ot_num< unsigned int >::operator==(), ot_int::operator==(), and ot_float::operator==().