xsil::MetaTable Class Reference
[Xsil document preparation]

Xsil table with automatic filling. More...

#include <MetaTable.hh>

Inheritance diagram for xsil::MetaTable:

xsil::table xsil::xobj

List of all members.

Public Member Functions

 MetaTable (void)
 Empty table constructor.
 MetaTable (const char *Name, const char *Type=0)
 MetaTable (const MetaTable &x)
virtual ~MetaTable (void)
void check (const char *title, int csize=0) const
void clear (void)
void defineColumn (const char *Name, const int *Addr)
void defineColumn (const char *Name, const long *Addr)
void defineColumn (const char *Name, const float *Addr)
void defineColumn (const char *Name, const double *Addr)
void defineColumn (const char *Name, const char *Addr, bool ilwc=false)
void defineColumn (const char *Name, const std::string *Addr, bool ilwc=false)
void defineColumn (const char *Name, const UCVec *Addr)
void defineColumn (const char *Name, const MetaTable *Addr, const char *Col=0)
int getNColumn (void) const
int getNRow (void) const
void putRow (void)
void resetStream (void)
std::string citeTable (const std::string &col) const
std::string citeTable (const std::string &col, int row) const

Classes

class  eventcolumn
 Data pointer class.


Detailed Description

Xsil table with automatic filling.

Specialization of xsil table class that incorporates automatic filling and reference capabilities. The user defines the MetaTable column structure by calling a defineColumn method for each data column. The second argument of defineColumn defines the data tyoe and the address of the mail-box variable that will contain the appropriate data each time a new row is added with via the putRow method.

Author:
John Zweizig
Version:
1.1; Last modified March 5, 2008

Constructor & Destructor Documentation

xsil::MetaTable::MetaTable ( void   ) 

Empty table constructor.

Construct an empty Meta-table.

xsil::MetaTable::MetaTable ( const char *  Name,
const char *  Type = 0 
)

Construct a Named Meta-table. brief Name meta-table constructor.

xsil::MetaTable::MetaTable ( const MetaTable x  ) 

Construct a Named Meta-table. brief Name meta-table constructor.

virtual xsil::MetaTable::~MetaTable ( void   )  [virtual]

Create an identical copy og the meta-table and return a pointer to the copy. brief Clone a Meta-table. Destroy a meta-table. brief Meta-table destructor.


Member Function Documentation

void xsil::MetaTable::check ( const char *  title,
int  csize = 0 
) const

Dump out the column data. brief Clear metatable.

void xsil::MetaTable::clear ( void   ) 

Clear all table column data. brief Clear metatable.

void xsil::MetaTable::defineColumn ( const char *  Name,
const int *  Addr 
)

Specify a table column. The column name and type are included. An address field specifies a static address from which the data will be copied. brief Add a column to the table.

Parameters:
Name Column name attribute field.
Addr Pointer to the data field.

void xsil::MetaTable::defineColumn ( const char *  Name,
const long *  Addr 
)

Specify a table column. The column name and type are included. An address field specifies a static address from which the data will be copied. brief Add a column to the table.

Parameters:
Name Column name attribute field.
Addr Pointer to the data field.

void xsil::MetaTable::defineColumn ( const char *  Name,
const float *  Addr 
)

Specify a table column. The column name and type are included. An address field specifies a static address from which the data will be copied. brief Add a column to the table.

Parameters:
Name Column name attribute field.
Addr Pointer to the data field.

void xsil::MetaTable::defineColumn ( const char *  Name,
const double *  Addr 
)

Specify a table column. The column name and type are included. An address field specifies a static address from which the data will be copied. brief Add a column to the table.

Parameters:
Name Column name attribute field.
Addr Pointer to the data field.

void xsil::MetaTable::defineColumn ( const char *  Name,
const char *  Addr,
bool  ilwc = false 
)

Specify a table column. The column name and type are included. An address field specifies a static address from which the data will be copied. brief Add a column to the table.

Parameters:
Name Column name attribute field.
Addr Pointer to the data field.
ilwc Data type "ilwd:char" (true) or lstring (false).

void xsil::MetaTable::defineColumn ( const char *  Name,
const std::string *  Addr,
bool  ilwc = false 
)

Specify a table column. The column name and type are included. An address field specifies a static address from which the data will be copied. brief Add a column to the table.

Parameters:
Name Column name attribute field.
Addr Pointer to the data field.
ilwc Data type "ilwd:char" (true) or lstring (false).

void xsil::MetaTable::defineColumn ( const char *  Name,
const UCVec Addr 
)

Specify a table column. The column name and type are included. An address field specifies a static address from which the data will be copied. brief Add a column to the table.

Parameters:
Name Column name attribute field.
Addr Pointer to the data field.

void xsil::MetaTable::defineColumn ( const char *  Name,
const MetaTable Addr,
const char *  Col = 0 
)

Specify a table reference column. brief Add a column to the table.

Parameters:
Name Column name attribute field.
Addr Pointer to the table to be referenced.
Col Name of column to be referenced.

int xsil::MetaTable::getNColumn ( void   )  const [inline]

Get the number of data columns that have already been defined. brief Get the number of columns.

Returns:
Current number of columns.

int xsil::MetaTable::getNRow ( void   )  const [inline]

Get the number of data rows that have already been defined. brief Get the number of rows.

void xsil::MetaTable::putRow ( void   ) 

Copy all specified data fields (one for each table column) into the data stream. brief Copy an event into the data stream.

void xsil::MetaTable::resetStream ( void   ) 

Delete the contens of the table data stream. brief Reset the data stream.

std::string xsil::MetaTable::citeTable ( const std::string &  col  )  const

Return a reference string to the last row of the table. The citation is of the form <table>:<column>:<row>. brief Get a reference to the last row of the table.

std::string xsil::MetaTable::citeTable ( const std::string &  col,
int  row 
) const

Return a reference string to the specified row of the table. The citation is of the form <table>:<column>:<row>. No validity check is performed on either the column name or the row number. brief Get a reference to the last row of the table.


The documentation for this class was generated from the following file:
Generated on Sun Mar 8 19:21:50 2009 for dmt by  doxygen 1.5.4