In file diagdatum.h:

class diagObjectName

Basic class to manage the name and type of objects in the diagnostics storage.

Inheritance:


Public Methods

diagObjectName (const string& Name, int MaxIndex1, int MaxIndex2, gdsDataType Datatype, const void* DefValue, int MaxDim1 = 1, int MaxDim2 = 0, const string& Unit = "", bool write = true)
Constructor.
virtual ~diagObjectName ()
Destructor.
virtual bool isValid (const string& Name, bool write = true, string* normName = 0) const
Validates names.
static string makeName (const string& Name, int index1 = -1, int index2 = -1)
Make a name.

Protected Fields

string name
name of object
int maxIndex1
maximum index size, first dimension
int maxIndex2
maximum index size, second dimension
gdsDataType datatype
data type
int maxDim1
maximum dimension of value, first dimension
int maxDim2
maximum dimension of value, second dimension
const void* defValue
default value(s)
string unit
unit of object
bool writeaccess
write access to object?

Documentation

This class is a generic manager object for accessing diagnostics data and parameter objects within a diagnostics storage object. It is able to handle multi-dimensional data and indexed names. It doesn't contain data by itself, but rather contains information about the dimension of the object, its name and its indices. It is used to validate names and make sure object stored within the diagnostics storage object are of the right format.

diagObjectName(const string& Name, int MaxIndex1, int MaxIndex2, gdsDataType Datatype, const void* DefValue, int MaxDim1 = 1, int MaxDim2 = 0, const string& Unit = "", bool write = true)
Constructs a object name class. This object manages the name, indices, type, dimensions and default values of a data object or a parameter. MaxIndex1 and MaxIndex2 describe if indices are supported ad if yes, what their highest value can be. A MaxIndex of 0 means no index, otherwise MaxIndex must be the largest allowed index + 1. If indices are supported the name of the object is composed from its short name and the indices as follows: 'Name[index1][index2]'. The dimension of the data object or parameter are determined as follows: (1) if the MaxDim1 is zero, the object has no data asscoiated with it; (2) if MaxDim2 is zero and MaxDim1 is not, the object describes a vector; (3) if both MaxDim's are non-zero it describes a matrix; (4) if MaxDim is negative any value for the dimension is supported; (5) if MaxDim is positive it represents the maximum value allowed for the dimension. Additionally, one can specified whether the object can be modified, or whether it is read-only. Names are not case sensitive, and spaces and tabs are ignored.

Returns:
void
Parameters:
Name - name of the data object/parameter
MaxIndex1 - maximum value for first index
MaxIndex2 - maximum value for second index
Datatype - data type of object
DefValue - default value of data object/parameter
MaxDim1 - maximum value of first dimension
MaxDim2 - maximum value of second dimension
write - if false, data object/parameter is read-only

virtual ~diagObjectName()
Destructs a object name class.

virtual bool isValid(const string& Name, bool write = true, string* normName = 0) const
This function returns true if the specified name is valid. It checks name, indices ans write access. It can also return a normalized name (correct capitalization no spaces).

Returns:
true if valid name, false otherwise
Parameters:
Name - name of data object/parameter
write - if false only read access is requested
normName - normalized name (return)

static string makeName(const string& Name, int index1 = -1, int index2 = -1)
Makes a full name out of the short name and the indeices.

Returns:
full name
Parameters:
Name - short name of data object/parameter
index1 - first index; -1 for none
index2 - second index; -1 for none

string name
name of object

int maxIndex1
maximum index size, first dimension

int maxIndex2
maximum index size, second dimension

gdsDataType datatype
data type

int maxDim1
maximum dimension of value, first dimension

int maxDim2
maximum dimension of value, second dimension

const void* defValue
default value(s)

string unit
unit of object

bool writeaccess
write access to object?


Direct child classes:
diagObject
Author:
DS, February 99
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++