![]() |
VR-Forces 5.0.3 Developer's Guide
|
This class is the table that holds a file from the VPF database.
Public Member Functions | |
| DtVpfTable (const DtFilename &path) | |
| virtual | ~DtVpfTable () |
| virtual std::istream & | file () |
| virtual const DtFilename & | fileName () const |
| virtual const DtFilename & | filePath () |
| virtual bool | mustSwap () const |
| virtual const DtVpfColumn * | column (const DtString &columnName) const |
| virtual const DtColumnList * | columns () const |
| virtual unsigned int | numColumns () const |
| virtual const DtVpfRow * | row (int unsigned rowNumber) const |
| virtual const DtVpfRow * | rowById (int unsigned id) const |
| virtual const DtRowList * | rows () const |
| virtual unsigned int | numRows () const |
| virtual const DtVpfTable * | intDescriptionTable () const |
| virtual const DtVpfTable * | charDescriptionTable () const |
Protected Member Functions | |
| virtual bool | readTable () |
| virtual bool | readHeader () |
| virtual bool | readData () |
| virtual void | calculateByteOrder () |
| virtual bool | loadValueDescriptionTable (const DtString &tableName) |
Protected Attributes | |
| int | myHeaderLength |
| DtByteOrderEnum | myFileByteOrder |
| DtByteOrderEnum | myMachineByteOrder |
| DtString | myTableDescription |
| DtString | myNarrativeTableFileName |
| DtFilename | myFileName |
| DtFilename | myFilePath |
| std::ifstream | myFile |
| std::ifstream::pos_type | myFileSize |
| DtColumnList | myColumns |
| DtRowList | myRows |
| DtVpfTable * | myIntDescriptions |
| DtVpfTable * | myCharDescriptions |
Private Types | |
| enum | DtByteOrderEnum { LSB, MSB } |
Private Member Functions | |
| DtVpfTable (const DtVpfTable &table) | |
| DtVpfTable & | operator= (const DtVpfTable &table) |
|
private |
|
private |
Copy constructor is private to prevent copying.
| DtVpfTable::DtVpfTable | ( | const DtFilename & | path | ) |
Constructor takes an absolute path to the table.
| DtInvalid | Input if path is incorrect |
|
virtual |
destructor
|
private |
Assignment operator is private to prevent copying.
|
virtual |
a file stream of the file used for reading the table in
|
virtual |
the name of the table's file
|
virtual |
the path to the table's file
|
virtual |
determines if the byte order of the machine and the file match
|
virtual |
returns a column with a given name will throw an exception if there is not a column of the given name
| DtInvalidInput | if the column name does not exist |
|
virtual |
return a pointer to the list of columns
returns the number of columns that this table has loaded
returns a row with the given index with thrown an exception if the row does not exist
| DtInvalidInput | if the row index is out of range |
returns a row with the given ID (since all rows have IDs) with thrown an exception if the row does not exist
| DtInvalidInput | if the row index is out of range |
|
virtual |
returns a pointer to the list of rows
returns the number of rows that this table has loaded
|
virtual |
returns the table that contains the integer data descriptions
|
virtual |
returns the table that contains the character data descriptions
|
protectedvirtual |
loads the entire table from disk
|
protectedvirtual |
loads the table header from disk
|
protectedvirtual |
loads the table data from disk
|
protectedvirtual |
determine the byte order of this machine
loads the value description table from disk
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |