Virtual U.org
Get Personal Training on VU Today
    
Top shadow
 
 register/help
User Name:

Password:

Database class Reference
Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members  

Database Class Reference

Utility class for reading in a database file. More...

#include <ODB.H>

Inheritance diagram for Database:

File List of all members.

Public Methods

 Database (char *=0, int=0)
 ~Database ()
void open (char *, int=0)
void open_from_buf (char *)
char * read (long=0)
void go (long recNo)
void close ()
long rec_count ()
long recno ()

Detailed Description

Utility class for reading in a database file.

Definition at line 14 of file ODB.H.


Constructor & Destructor Documentation

Database::Database char *    dbFileName = 0,
int    bufferAll = 0
 

[char*] fileName = the name of the DBF file to be opened [int] bufferAll = read the whole database into memory or not

Definition at line 14 of file ODB.CPP.

References NULL.

Database::~Database  
 

Definition at line 28 of file ODB.CPP.

References close().


Member Function Documentation

void Database::close  
 

Database::close()

Definition at line 131 of file ODB.CPP.

References mem_del, and NULL.

Referenced by ~Database().

void Database::go long    recNo [inline]
 

Definition at line 61 of file ODB.H.

void Database::open char *    fileName,
int    bufferAll = 0
 

Database::open( char* fileName )

<char*> fileName = the name of the DBF file to be opened [int] bufferAll = read the whole database into memory or not (default : 0)

return 1 : opened successfully 0 : opening failure

Definition at line 45 of file ODB.CPP.

void Database::open_from_buf char *    dataPtr
 

Open the database from an buffer with the database pre-read in

<char*> dataPtr = the pointer to the pre-read database in the memory

Definition at line 76 of file ODB.CPP.

Referenced by GameSet::open_db().

char * Database::read long    recNo = 0
 

Database::read( long recNum )

[recNum] = the record number of the record to be read (default : current record no.)

return : <char*> success, the pointer to the reading buffer <NULL> fail

Definition at line 102 of file ODB.CPP.

References NULL.

Referenced by SpriteFrameRes::load_info().

long Database::rec_count   [inline]
 

Definition at line 64 of file ODB.H.

Referenced by SpriteFrameRes::load_info().

long Database::recno   [inline]
 

Definition at line 65 of file ODB.H.


The documentation for this class was generated from the following files:
Generated on Fri Aug 23 01:39:03 2002 for VirtualU by doxygen1.2.17