casa  5.7.0-16
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Static Public Member Functions | Static Public Attributes | Private Member Functions | Static Private Member Functions | List of all members
CPrimitiveDataType Class Reference

A helper class for the enumeration PrimitiveDataType. More...

#include <CPrimitiveDataType.h>

Static Public Member Functions

static int version ()
 Return the major version number as an int. More...
 
static std::string revision ()
 Return the revision as a string. More...
 
static unsigned int size ()
 Return the number of enumerators declared in PrimitiveDataTypeMod::PrimitiveDataType. More...
 
static std::string name (const PrimitiveDataTypeMod::PrimitiveDataType &e)
 Returns an enumerator as a string. More...
 
static std::string toString (const PrimitiveDataTypeMod::PrimitiveDataType &f)
 Equivalent to the name method. More...
 
static const std::vector
< std::string > 
names ()
 Returns vector of all the enumerators as strings. More...
 
static
PrimitiveDataTypeMod::PrimitiveDataType 
newPrimitiveDataType (const std::string &name)
 Create a PrimitiveDataType enumeration object by specifying its name. More...
 
static
PrimitiveDataTypeMod::PrimitiveDataType 
literal (const std::string &name)
 
static
PrimitiveDataTypeMod::PrimitiveDataType 
from_int (unsigned int i)
 

Static Public Attributes

static const std::string & sINT16_TYPE
 Enumerators as strings. More...
 
static const std::string & sINT32_TYPE
 
static const std::string & sINT64_TYPE
 
static const std::string & sFLOAT32_TYPE
 
static const std::string & sFLOAT64_TYPE
 

Private Member Functions

 CPrimitiveDataType ()
 
 CPrimitiveDataType (const CPrimitiveDataType &)
 
CPrimitiveDataTypeoperator= (const CPrimitiveDataType &)
 

Static Private Member Functions

static std::string badString (const std::string &name)
 
static std::string badInt (unsigned int i)
 

Detailed Description

A helper class for the enumeration PrimitiveDataType.

Definition at line 89 of file CPrimitiveDataType.h.

Constructor & Destructor Documentation

CPrimitiveDataType::CPrimitiveDataType ( )
private
CPrimitiveDataType::CPrimitiveDataType ( const CPrimitiveDataType )
private

Member Function Documentation

static std::string CPrimitiveDataType::badInt ( unsigned int  i)
staticprivate
static std::string CPrimitiveDataType::badString ( const std::string &  name)
staticprivate
static PrimitiveDataTypeMod::PrimitiveDataType CPrimitiveDataType::from_int ( unsigned int  i)
static

Return a PrimitiveDataType's enumerator given an unsigned int.

Parameters
ithe index of the enumerator in PrimitiveDataTypeMod::PrimitiveDataType.
Returns
a PrimitiveDataTypeMod::PrimitiveDataType's enumerator.
Exceptions
astring containing an error message if no enumerator could be found for this integer.
static PrimitiveDataTypeMod::PrimitiveDataType CPrimitiveDataType::literal ( const std::string &  name)
static

Return a PrimitiveDataType's enumerator given a string.

Parameters
namethe string representation of the enumerator.
Returns
a PrimitiveDataTypeMod::PrimitiveDataType's enumerator.
Exceptions
astring containing an error message if no enumerator could be found for this name.
static std::string CPrimitiveDataType::name ( const PrimitiveDataTypeMod::PrimitiveDataType &  e)
static

Returns an enumerator as a string.

Parameters
ean enumerator of PrimitiveDataTypeMod::PrimitiveDataType.
Returns
a string.
static const std::vector<std::string> CPrimitiveDataType::names ( )
static

Returns vector of all the enumerators as strings.

The strings are stored in the vector in the same order than the enumerators are declared in the enumeration.

Returns
a vector of string.
static PrimitiveDataTypeMod::PrimitiveDataType CPrimitiveDataType::newPrimitiveDataType ( const std::string &  name)
static

Create a PrimitiveDataType enumeration object by specifying its name.

CPrimitiveDataType& CPrimitiveDataType::operator= ( const CPrimitiveDataType )
private
static std::string CPrimitiveDataType::revision ( )
static

Return the revision as a string.

Returns
a string
static unsigned int CPrimitiveDataType::size ( )
static

Return the number of enumerators declared in PrimitiveDataTypeMod::PrimitiveDataType.

Returns
an unsigned int.
static std::string CPrimitiveDataType::toString ( const PrimitiveDataTypeMod::PrimitiveDataType &  f)
inlinestatic

Equivalent to the name method.

Definition at line 139 of file CPrimitiveDataType.h.

static int CPrimitiveDataType::version ( )
static

Return the major version number as an int.

Returns
an int.

Member Data Documentation

const std::string& CPrimitiveDataType::sFLOAT32_TYPE
static

A const string equal to "FLOAT32_TYPE".

Definition at line 102 of file CPrimitiveDataType.h.

const std::string& CPrimitiveDataType::sFLOAT64_TYPE
static

A const string equal to "FLOAT64_TYPE".

Definition at line 104 of file CPrimitiveDataType.h.

const std::string& CPrimitiveDataType::sINT16_TYPE
static

Enumerators as strings.

A const string equal to "INT16_TYPE".

Definition at line 96 of file CPrimitiveDataType.h.

const std::string& CPrimitiveDataType::sINT32_TYPE
static

A const string equal to "INT32_TYPE".

Definition at line 98 of file CPrimitiveDataType.h.

const std::string& CPrimitiveDataType::sINT64_TYPE
static

A const string equal to "INT64_TYPE".

Definition at line 100 of file CPrimitiveDataType.h.


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