VR-Forces 4.0.4 Class Documentation
Public Member Functions | Protected Member Functions | Protected Attributes
DtVpfRow Class Reference

a class representing a row of data from a table. More...

List of all members.

Public Member Functions

 DtVpfRow (const DtVpfRow &row)
 Copy constructor is private to prevent copying.
DtVpfRow & operator= (const DtVpfRow &row)
 Assignment operator is private to prevent copying.
 DtVpfRow (DtVpfTable *table)
 Constructor takes the table that this column belongs to.
virtual ~DtVpfRow ()
 Destructor.
virtual bool loadRow (int row)
 loads this row with data from the columns at the given index
virtual const DtVpfTable * table () const
 returns the table that owns this row
virtual const DtVpfData & operator[] (const unsigned int data) const
 allows indexed access to the elements of the row
virtual int size () const
 returns the number of elements in this row
virtual bool hasField (const DtString &field_name) const
 determines if the row has the named field
virtual const DtVpfIntData * getIntField (const DtString &field) const
 Data specific type of data access.
virtual const DtVpfFloatData * getFloatField (const DtString &field) const
virtual const DtVpf3CoordData * getCoordField (const DtString &field) const
virtual const DtVpfTextData * getTextField (const DtString &field) const
virtual const DtVpfTripletData * getTripletField (const DtString &field) const

Protected Member Functions

virtual DtVpfData * getField (const DtString &field) const
 function to find the requested field used by the data specific types to get the field

Protected Attributes

std::vector< DtVpfData * > myData
DtVpfTable * myTable

Detailed Description

a class representing a row of data from a table.

Rows don't really own any data, the columns own the data. The row only owns pointers to the data across the columns.


Constructor & Destructor Documentation

DtVpfRow::DtVpfRow ( const DtVpfRow &  row)

Copy constructor is private to prevent copying.

Constructor takes the table that this column belongs to.

virtual DtVpfRow::~DtVpfRow ( ) [virtual]

Destructor.


Member Function Documentation

DtVpfRow& DtVpfRow::operator= ( const DtVpfRow &  row)

Assignment operator is private to prevent copying.

virtual bool DtVpfRow::loadRow ( int  row) [virtual]

loads this row with data from the columns at the given index

Returns:
A boolean that represents the success or failure of the load
virtual const DtVpfTable* DtVpfRow::table ( ) const [virtual]

returns the table that owns this row

Returns:
A pointer to a DtVpfTable that owns this row
virtual const DtVpfData& DtVpfRow::operator[] ( const unsigned int  data) const [virtual]

allows indexed access to the elements of the row

Returns:
A pointer to the data that is at the requested index
Exceptions:
DtInvalidInputif the index is out of range
virtual int DtVpfRow::size ( ) const [virtual]

returns the number of elements in this row

Returns:
An integer representing the number of elements in this row
virtual bool DtVpfRow::hasField ( const DtString &  field_name) const [virtual]

determines if the row has the named field

Returns:
A boolean indicating whether or not the row has the requested field
virtual const DtVpfIntData* DtVpfRow::getIntField ( const DtString &  field) const [virtual]

Data specific type of data access.

Exceptions:
DtInvalidInputif the field is not the right type
virtual const DtVpfFloatData* DtVpfRow::getFloatField ( const DtString &  field) const [virtual]
virtual const DtVpf3CoordData* DtVpfRow::getCoordField ( const DtString &  field) const [virtual]
virtual const DtVpfTextData* DtVpfRow::getTextField ( const DtString &  field) const [virtual]
virtual const DtVpfTripletData* DtVpfRow::getTripletField ( const DtString &  field) const [virtual]
virtual DtVpfData* DtVpfRow::getField ( const DtString &  field) const [protected, virtual]

function to find the requested field used by the data specific types to get the field

Exceptions:
DtInvalidInputif the field does not exist

Member Data Documentation

std::vector<DtVpfData*> DtVpfRow::myData [protected]

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

Document ID: Generated on Fri Jun 29 16:33:32 EDT 2012 from SVN revision 116588
Copyright © 2005-2012 VT MÄK Inc. All Rights Reserved (www.mak.com)