#include <baciValue.h>
Generic data type used in BACI Class BACIValue is a data type wrapper for all BACI supported types. It provides several methods needed by BACI (compare operators, abs. diff., etc.)
typedef unsigned char baci::BACIValue::octet |
An 8-bit unsigned integer.
Enumeration of all supported data types. If it's not listed here, it cannot be packed into a BACIValue.
baci::BACIValue::BACIValue | ( | ) |
Standard Contructor. The wrapped value will carry a Type::type_null value.
baci::BACIValue::BACIValue | ( | const Type | type, | |
const unsigned long | bound | |||
) |
Constructor with initialized type. By using this constructor, one can create a BACIValue object with any type, although the value is not directly settable.
type | Type of the wrapped value. | |
bound | bound (for varialble length types) |
baci::BACIValue::BACIValue | ( | const BACIValue & | value | ) |
Copy constructor: construct a value that will store the same data as the specified value.
value | A pre-existing BACIValue object |
baci::BACIValue::BACIValue | ( | const BACIdouble & | value | ) |
Constructor BACIdouble
value | A constant reference to a value which will be this BACIValue object's underlying value. |
baci::BACIValue::BACIValue | ( | const BACIfloat & | value | ) |
Constructor BACIfoat
value | A constant reference to a value which will be this BACIValue object's underlying value. |
baci::BACIValue::BACIValue | ( | const BACIlong & | value | ) |
Constructor BACIlong
value | A constant reference to a value which will be this BACIValue object's underlying value. |
baci::BACIValue::BACIValue | ( | const BACIlongLong & | value | ) |
baci::BACIValue::BACIValue | ( | const BACIuLongLong & | value | ) |
Constructor realType
value | A constant reference to a value which will be this BACIValue object's underlying value. |
baci::BACIValue::BACIValue | ( | const ACE_CString & | value | ) |
Constructor ACE_CString
value | A constant reference to a value which will be this BACIValue object's underlying value. |
baci::BACIValue::BACIValue | ( | const char * | value | ) |
Constructor char*
value | A constant reference to a value which will be this BACIValue object's underlying value. |
baci::BACIValue::BACIValue | ( | const void *& | value | ) |
Constructor - Special case
value | A constant reference to a value which will be this BACIValue object's underlying value. |
baci::BACIValue::BACIValue | ( | void * | value | ) |
Constructor - pointer (Special case
value | A constant reference to a value which will be this BACIValue object's underlying value. |
baci::BACIValue::BACIValue | ( | const BACIdoubleSeq & | value | ) |
Constructor BACIdoubleSeq
value | A constant reference to a value which will be this BACIValue object's underlying value. |
baci::BACIValue::BACIValue | ( | const BACIfloatSeq & | value | ) |
Constructor BACIfloatSeq
value | A constant reference to a value which will be this BACIValue object's underlying value. |
baci::BACIValue::BACIValue | ( | const BACIlongSeq & | value | ) |
Constructor BACIlongSeq
value | A constant reference to a value which will be this BACIValue object's underlying value. |
baci::BACIValue::BACIValue | ( | const BACIstringSeq & | value | ) |
Constructor BACIstringSeq
value | A constant reference to a value which will be this BACIValue object's underlying value. |
baci::BACIValue::BACIValue | ( | const BACIpattern & | value, | |
const CORBA::Any & | any | |||
) |
Constructor CORBA::Any. Deprecated. Used to support CORBA enums. It is used by test in baci module.
baci::BACIValue::~BACIValue | ( | ) |
Destructor
BACIdoubleSeq baci::BACIValue::doubleSeqValue | ( | ) | const |
Returns this object's underlying BACI value as a double sequence.
bool baci::BACIValue::doubleSeqValue | ( | const BACIdoubleSeq & | value | ) |
Mutator
value | Reference to a BACIdoubleSeq that this object will copy. |
BACIdouble baci::BACIValue::doubleValue | ( | ) | const |
Returns this object's underlying BACI value as a double.
bool baci::BACIValue::doubleValue | ( | const BACIdouble & | value | ) |
Mutator
value | Reference to a BACIdouble that this object will copy. |
bool baci::BACIValue::enumValue | ( | const BACIpattern & | value, | |
const CORBA::Any & | anyVal | |||
) |
Mutator
value | Reference to a CORBA::Any that this object will copy. |
CORBA::Any baci::BACIValue::enumValue | ( | ) | const |
Deprecated.
bool baci::BACIValue::floatSeqValue | ( | const BACIfloatSeq & | value | ) |
Mutator
value | Reference to a BACIfloatSeq that this object will copy. |
BACIfloatSeq baci::BACIValue::floatSeqValue | ( | ) | const |
Returns this object's underlying BACI value as a double sequence.
BACIfloat baci::BACIValue::floatValue | ( | ) | const |
Returns this object's underlying BACI value as a long.
bool baci::BACIValue::floatValue | ( | const BACIfloat & | value | ) |
Mutator
value | Reference to a BACIfloat that this object will copy. |
bool baci::BACIValue::fromString | ( | const ACE_CString | value, | |
bool | specifyType = false | |||
) |
Convert from a string into a BACI type and encode it into this object.
value | value represented as string | |
bool | if true (false is default) value type is also given (eg. <double>12.8) in input string, otherwise set type is used |
void baci::BACIValue::getAny | ( | CORBA::Any & | any | ) | const |
const char* baci::BACIValue::getArchiveType | ( | ) | const [inline] |
Get value type
unsigned long baci::BACIValue::getBound | ( | ) | const [inline] |
Get value bound (for variable length data types; eg. strings)
Type baci::BACIValue::getType | ( | ) | const [inline] |
Get value type
BACIdouble baci::BACIValue::getValue | ( | BACIdouble * | v = 0 |
) | const |
Returns this object's underlying BACI value as a double.
v | is a BACIdouble *. Invoker should just provide a null reference. |
Returns this object's underlying BACI value as a float.
v | is a BACIfloat *. Invoker should just provide a null reference. |
Returns this object's underlying BACI value as a long.
v | is a BACIlong *. Invoker should just provide a null reference. |
BACIlongLong baci::BACIValue::getValue | ( | BACIlongLong * | v = 0 |
) | const |
Returns this object's underlying BACI value as a long long.
v | is a BACIlongLong *. Invoker should just provide a null reference. |
BACIuLongLong baci::BACIValue::getValue | ( | BACIuLongLong * | v = 0 |
) | const |
Returns this object's underlying BACI value as an unsigned long long.
v | is a BACIuLongLong *. Invoker should just provide a null reference. |
CORBA::Any baci::BACIValue::getValue | ( | CORBA::Any * | v = 0 |
) | const |
Returns this object's underlying BACI value as a pattern.
v | is a BACIpattern *. Invoker should just provide a null reference. |
v | is a CORBA::Any *. Invoker should just provide a null reference. |
void* baci::BACIValue::getValue | ( | void ** | v = 0 |
) | const |
Returns this object's underlying BACI value as a void pointer.
v | is a void pointer *. Invoker should just provide a null reference. |
BACIdoubleSeq baci::BACIValue::getValue | ( | BACIdoubleSeq * | v = 0 |
) | const |
Returns this object's underlying BACI value as a double sequence.
v | is a BACIdoubleSeq *. Invoker should just provide a null reference. |
BACIfloatSeq baci::BACIValue::getValue | ( | BACIfloatSeq * | v = 0 |
) | const |
Returns this object's underlying BACI value as a float sequence.
v | is a BACIfloatSeq *. Invoker should just provide a null reference. |
BACIlongSeq baci::BACIValue::getValue | ( | BACIlongSeq * | v = 0 |
) | const |
Returns this object's underlying BACI value as a long sequence.
v | is a BACIlongSeq *. Invoker should just provide a null reference. |
BACIstringSeq baci::BACIValue::getValue | ( | BACIstringSeq * | v = 0 |
) | const |
Returns this object's underlying BACI value as a string sequence.
v | is a BACIstringSeq *. Invoker should just provide a null reference. |
ACE_CString baci::BACIValue::getValue | ( | ACE_CString * | v = 0 |
) | const |
Given a pointer to an ACE C string, this method returns the stringified value of this object.
v | is an ACE_CString *. Invoker should just provide a null reference. |
char* baci::BACIValue::getValue | ( | const char ** | v = 0 |
) | const |
Given a const pointer to character pointers, this method returns the stringified value of this object.
v | is a constant char**. Invoker should just provide a null reference. |
char* baci::BACIValue::getValue | ( | char ** | v = 0 |
) | const |
Given a pointer to character pointers, this method returns the stringified value of this object.
v | is a char**. Invoker should just provide a null reference. |
unsigned long baci::BACIValue::isNull | ( | ) | const [inline] |
Is value null value (not initialized)
Check if absolute difference between values is less than delta value
value | value | |
delta | delta value |
bool baci::BACIValue::lessThanPercentDelta | ( | const BACIValue & | value, | |
const BACIValue & | delta | |||
) | const |
Check if percentual difference between values is less than delta value
value | value | |
delta | percentual delta value |
BACIlongLong baci::BACIValue::longLongValue | ( | ) | const |
Returns this object's underlying BACI value as a long long.
bool baci::BACIValue::longLongValue | ( | const BACIlongLong & | value | ) |
Mutator
value | Reference to a BACIlongLong that this object will copy. |
bool baci::BACIValue::longSeqValue | ( | const BACIlongSeq & | value | ) |
Mutator
value | Reference to a BACIlongSeq that this object will copy. |
BACIlongSeq baci::BACIValue::longSeqValue | ( | ) | const |
Returns this object's underlying BACI value as a long sequence.
BACIlong baci::BACIValue::longValue | ( | ) | const |
Returns this object's underlying BACI value as a long.
bool baci::BACIValue::longValue | ( | const BACIlong & | value | ) |
Mutator
value | Reference to a BACIlong that this object will copy. |
static Type baci::BACIValue::mapType | ( | BACIuLongLong * | v = 0 |
) | [inline, static] |
Given a pointer to a baci::BACIuLongLong, this static method returns a the Type enumeration value.
v | Pointer to a BACI data type |
Given a pointer to a baci::BACIfloat, this static method returns a the Type enumeration value.
v | Pointer to a BACI data type |
Given a pointer to a baci::BACIlong, this static method returns a the Type enumeration value.
v | Pointer to a BACI data type |
static Type baci::BACIValue::mapType | ( | void ** | v = 0 |
) | [inline, static] |
Given a pointer to a void*, this static method returns a the Type enumeration value.
v | Pointer to a BACI data type |
static Type baci::BACIValue::mapType | ( | ACE_CString * | v = 0 |
) | [inline, static] |
Given a pointer to an ACE_CString, this static method returns a the Type enumeration value.
v | Pointer to a BACI data type |
static Type baci::BACIValue::mapType | ( | BACIdoubleSeq * | v = 0 |
) | [inline, static] |
Given a pointer to a baci::BACIdoubleSeq, this static method returns a the Type enumeration value.
v | Pointer to a BACI data type |
static Type baci::BACIValue::mapType | ( | BACIfloatSeq * | v = 0 |
) | [inline, static] |
Given a pointer to a baci::BACIfloatSeq, this static method returns a the Type enumeration value.
v | Pointer to a BACI data type |
static Type baci::BACIValue::mapType | ( | BACIlongSeq * | v = 0 |
) | [inline, static] |
Given a pointer to a baci::BACIlongSeq, this static method returns a the Type enumeration value.
v | Pointer to a BACI data type |
static Type baci::BACIValue::mapType | ( | BACIlongLong * | v = 0 |
) | [inline, static] |
Given a pointer to a baci::BACIlongLong, this static method returns a the Type enumeration value.
v | Pointer to a BACI data type |
static Type baci::BACIValue::mapType | ( | BACIdouble * | v = 0 |
) | [inline, static] |
Given a pointer to a baci::BACIdouble, this static method returns a the Type enumeration value.
v | Pointer to a BACI data type |
static Type baci::BACIValue::mapType | ( | BACIstringSeq * | v = 0 |
) | [inline, static] |
Given a pointer to a baci::BACIstringSeq, this static method returns a the Type enumeration value.
v | Pointer to a BACI data type |
static Type baci::BACIValue::mapType | ( | char ** | v = 0 |
) | [inline, static] |
Given a pointer to a baci::BACIpattern, this static method returns a the Type enumeration value.
v | Pointer to a BACI data type |
v | Pointer to a BACI data type |
bool baci::BACIValue::noDelta | ( | ) | const |
Check if value equals no change (e.g. for double 0.0, int 0)
bool baci::BACIValue::operator< | ( | const BACIValue & | value | ) | const |
Check less-than Operator
bool baci::BACIValue::operator<= | ( | const BACIValue & | value | ) | const |
Check less-than or equal to Operator
bool baci::BACIValue::operator== | ( | const BACIValue & | value | ) | const |
Check equals to Operator
bool baci::BACIValue::patternValue | ( | const BACIpattern & | value | ) | [inline] |
Mutator
value | Reference to a BACIpattern that this object will copy. |
BACIpattern baci::BACIValue::patternValue | ( | ) | const [inline] |
Returns this object's underlying BACI value as a pattern.
void* baci::BACIValue::pointerValue | ( | ) | const |
Returns this object's underlying BACI value as a void pointer.
bool baci::BACIValue::pointerValue | ( | void * | value | ) |
Mutator
value | Reference to a void pointer that this object will copy. |
void baci::BACIValue::reset | ( | ) |
Resets value to non-initialized state(VALUE_UNINITIALIZED, type_null type).
bool baci::BACIValue::setType | ( | Type | type, | |
unsigned long | bound = 0 | |||
) |
Set the data type that this value will store. Makes the value capable of storing data of type Type. If the type currently being stored by the filed does not match Type, it is properly disposed. After using this function, the user should not assume that the data has been initialized, i.e. using accessor before a mutator is illegal. Example:
BACIValue value; value.setType(BACIValue::type_string);
bool baci::BACIValue::setValue | ( | const BACIfloatSeq & | value | ) |
Mutator
value | Reference to a BACIfloatSeq that this object will copy. |
bool baci::BACIValue::setValue | ( | const BACIdoubleSeq & | value | ) |
Mutator
value | Reference to a BACIdoubleSeq that this object will copy. |
bool baci::BACIValue::setValue | ( | const BACIuLongLong & | value | ) |
Mutator
value | Reference to a BACIuLongLong that this object will copy. |
bool baci::BACIValue::setValue | ( | const char * | value | ) |
Mutator
value | Reference to a character pointer that this object will copy. |
bool baci::BACIValue::setValue | ( | const ACE_CString & | value | ) |
Mutator
value | Reference to an ACE C string that this object will copy. |
bool baci::BACIValue::setValue | ( | const BACIdouble & | value | ) |
Mutator
value | Reference to a BACIdouble that this object will copy. |
bool baci::BACIValue::setValue | ( | const BACIstringSeq & | value | ) |
Mutator
value | Reference to a BACIstringSeq that this object will copy. |
bool baci::BACIValue::setValue | ( | const BACIlongSeq & | value | ) |
Mutator
value | Reference to a BACIlongSeq that this object will copy. |
bool baci::BACIValue::setValue | ( | const BACIfloat & | value | ) |
Mutator
value | Reference to a BACIfloat that this object will copy. |
bool baci::BACIValue::setValue | ( | const BACIlong & | value | ) |
Mutator
value | Reference to a BACIlong that this object will copy. |
bool baci::BACIValue::setValue | ( | const BACIlongLong & | value | ) |
Mutator
value | Reference to a BACIuLongLong that this object will copy. |
bool baci::BACIValue::stringSeqValue | ( | const BACIstringSeq & | value | ) |
Mutator
value | Reference to a BACIstringSeq that this object will copy. |
BACIstringSeq baci::BACIValue::stringSeqValue | ( | ) | const |
Returns this object's underlying BACI value as a string sequence.
const ACE_TCHAR* baci::BACIValue::stringValue | ( | ) | const |
Stringifies this object's underlying BACI value.
bool baci::BACIValue::stringValue | ( | const ACE_CString & | value | ) |
Mutator
value | Reference to a BACIpattern that this object will copy. |
value | Reference to a enum that this object will copy. |
value | Reference to an ACE C string that this object will copy. |
bool baci::BACIValue::stringValue | ( | const char * | value | ) |
Mutator
value | Reference to a character pointer that this object will copy. |
bool baci::BACIValue::toString | ( | ACE_CString & | value, | |
bool | specifyType = false | |||
) | const |
Convert to string
value | where the string's value will be written to | |
bool | if true (false is default) value type is also given (eg. <double>12.8), which could help in decoding data value (as implemented in fromString method) |
BACIuLongLong baci::BACIValue::uLongLongValue | ( | ) | const |
Returns this object's underlying BACI value as an unsigned long long.
bool baci::BACIValue::uLongLongValue | ( | const BACIuLongLong & | value | ) |
Mutator
value | Reference to a BACIuLongLong that this object will copy. |
unsigned long baci::BACIValue::whyIsNull | ( | ) | const [inline] |
Return the reason why the value was set as null value.
union { ... } [protected] |
CORBA::Any baci::BACIValue::any_m [protected] |
This any is used as a hack to support enumeration properties. Unless this BACIValue object is hiding an enumeration, do not use this.
const ACE_CString baci::BACIValue::archiveTypeName[] [static] |
Array of strings initialized to contain what are essentially the same values as the Type enum. Values are: "invalid","invalid","string","double","long","long", "doubleSeq" (not supported by logging),"longSeq","longLong", "uLongLong","longString" Furthermore, this array can be indexed using the Type enum.
unsigned long baci::BACIValue::bound |
double baci::BACIValue::inlineData_m[2] |
Inlined data can be up to 8 bytes in length. This is sufficient for storing octets, short, long, and longlong integers, doubles and floats.
bool baci::BACIValue::isEnum_m [protected] |
This is set to true if the BACIValue is really an enumeration.
const BACIValue baci::BACIValue::NullValue [static] |
A global predefined null BACIValue.
void* baci::BACIValue::pointer |
struct { ... } baci::BACIValue::ptr_m |
Other types store a pointer to the actual data and a bound on the amount of data that can be stored there (e.g., number of characters for strings). A bound of 0 indicates "no limits".
Type baci::BACIValue::type_m [protected] |
Identifies the type of data currently being stored.
const ACE_CString baci::BACIValue::typeName[] [static] |
unsigned long baci::BACIValue::whyNull_m |
Describes why the value has type null