In file gdsdatum.h:

class gdsNamedDatum : public gdsNamedStorage, public gdsDatum

Class to store a named data field.

Inheritance:


Public Fields

mutable recursivemutex mux
mutex to protect object
string unit
Describes the unit of a data field.
int level
Nesting level

Public Methods

gdsNamedDatum ()
Default constructor.
gdsNamedDatum (const string& Name, gdsDataType DataType, const void* Value, int dim1 = 1, int dim2 = 0, int dim3 = 0, int dim4 = 0, const string& Unit = "", const string& Comment = "")
Constructor.
gdsNamedDatum (const string& Name, const gdsDatum& Value, const string& Unit = "", const string& Comment = "")
Constructor.

Inherited from gdsNamedStorage:

Public Fields

string name
string comment

Public Methods

bool operator == (const gdsNamedStorage& x) const
bool operator == (const string& x) const
bool operator != (const string& x) const
bool operator != (const gdsNamedStorage& x) const
bool operator <= (const gdsNamedStorage& x) const
bool operator < (const gdsNamedStorage& x) const
bool operator < (const string& x) const
bool operator >= (const gdsNamedStorage& x) const
bool operator > (const gdsNamedStorage& x) const

Inherited from gdsDatum:

Public Classes

enum encodingtype
ascii
ascii
binary
binary
uuencode
uuencoding
base64
base64 encoding

Public Fields

typedef std::vector <int> dimension_t
gdsDataType datatype
dimension_t dimension
void* value
encodingtype encoding

Public Methods

friend std::istream& operator >> (std::istream&, gdsDatum&)
friend std::ostream& operator << (std::ostream&, const gdsDatum&)
virtual bool assignDatum(const gdsDatum& dat)
static bool encode(std::ostream& os, const char* val, int len, encodingtype ctype = base64, int indent = 0)
static bool decode(std::istream& is, char* val, int len, encodingtype ctype = base64)
static bool decode(const char* code, int codelen, char* val, int len, encodingtype ctype = base64)
static std::string codeName(encodingtype ctype)
static encodingtype code(std::string name)
gdsDatum& operator= (const gdsDatum& dat)
bool resize(int dim1, int dim2 = 0, int dim3 = 0, int dim4 = 0)
int elSize() const
int elNumber() const
int size() const
int readValues(const string& txt)
void lock(bool writeaccess = false) const
bool trylock(bool writeaccess = false) const
void unlock() const

Protected Fields

mutable readwritelock rwlock

Documentation

This class is used to store a named data field. It is self describing and contains the data type, the number of elements (array dimensions), the name of the data field and its unit.
mutable recursivemutex mux
mutex to protect object

string unit
Describes the unit of a data field.

int level
Nesting level

gdsNamedDatum()
Constructs a named data field with no name and empty values.
Returns:
void

gdsNamedDatum(const string& Name, gdsDataType DataType, const void* Value, int dim1 = 1, int dim2 = 0, int dim3 = 0, int dim4 = 0, const string& Unit = "", const string& Comment = "")
Constructs a named data field. The supplied data field is copied (the caller is responsible to free the supplied data field if necessary.
Returns:
void
Parameters:
Name - name of data field
DataType - type of data field
Value - pointer to data field
dim1 - first dimension of data field (default 1)
dim2 - second dimension of data field (default 0)
dim3 - third dimension of data field (default 0)
dim4 - fourth dimension of data field (default 0)
Unit - unit of data field
Comment - comment string for describing data field

gdsNamedDatum(const string& Name, const gdsDatum& Value, const string& Unit = "", const string& Comment = "")
Constructs a named data field. The supplied data field object is copied (the caller is responsible to free the supplied data field if necessary.
Returns:
void
Parameters:
Name - name of data field
Value - data field object
Unit - unit of data field
Comment - comment string for describing data field


Direct child classes:
gdsParameter
gdsDataObject
Author:
DS, November 98
See Also:
Diagnostics storage API

alphabetic index hierarchy of classes


Please send questions and comments to sigg_d@ligo-wa.caltech.edu


generated by doc++