#include <Database.h>
Public Member Functions | |
| CDatabase (const char *dbtFilename) | |
| ~CDatabase (void) | |
| CDatabaseTemplate * | GetTemplate (void) |
| void | AddIndex (const char *dbiFilename) |
| unsigned int | GetNumIndexes (void) |
| CDatabaseIndex * | GetIndex (Tag tag) |
| void | Mount (PODFILE *f) |
| void | Mount (const char *dbdFilename) |
| void | Unmount (void) |
| void | Dump (FILE *f) |
| unsigned long | GetRawRecordLength (void) |
| unsigned long | GetNumRecords (void) |
| unsigned long | GetNumFields (void) |
| CDatabaseRecord * | GetRecordByOffset (unsigned long offset) |
| unsigned long | RecordOffset (unsigned long index) |
| CDatabaseRecord * | GetRecordByIndex (unsigned long index) |
| unsigned long | Search (Tag index, const char *key) |
| unsigned long | Search (Tag index, double key) |
| unsigned long | Search (Tag index, long key) |
| unsigned long | SearchNext (void) |
| void | GetRawRecord (unsigned long offset, char *buffer) |
Protected Member Functions | |
| void | LoadTemplate (const char *dbtFilename) |
Private Attributes | |
| EDatabaseState | state |
| PODFILE * | podfile |
| unsigned long | signature |
| unsigned long | nRecords |
| unsigned long | recLength |
| CDatabaseTemplate | dbt |
| Template. | |
| std::vector< CDatabaseIndex * > | dbi |
| Vector of indices. | |
| char * | recordBuffer |
| Temporary raw record buffer. | |
| unsigned long | cacheOffset |
| DBD offset of last record read. | |
| CDatabaseRecord * | cacheRecord |
| Cached value of last record read. | |
| CDatabaseIndex * | search_index |
| Index used in last Search(). | |
Definition at line 199 of file Database.h.
|
|
Definition at line 78 of file DBDatabase.cpp. References cacheRecord, DB_UNMOUNTED, LoadTemplate(), podfile, recordBuffer, and state. |
|
|
Deallocate all dynamic memory from the heap, close all open files Definition at line 101 of file DBDatabase.cpp. References cacheRecord, dbi, recordBuffer, and Unmount(). |
|
|
Definition at line 136 of file DBDatabase.cpp. References dbi. Referenced by LoadDatabases(). |
|
|
Definition at line 609 of file DBDatabase.cpp. References DB_MOUNTED, DB_UNMOUNTED, dbi, dbt, CDatabaseTemplate::Dump(), CDatabaseField::Format(), CDatabaseRecord::GetField(), GetNumFields(), GetNumRecords(), GetRecordByIndex(), nRecords, and state. Referenced by debug_dump_apdb_cb(). |
|
|
Definition at line 146 of file DBDatabase.cpp. References dbi. Referenced by Search(). |
|
|
Definition at line 392 of file DBDatabase.cpp. References dbt, and CDatabaseTemplate::GetNumItems(). Referenced by Dump(), and GetRecordByOffset(). |
|
|
Definition at line 141 of file DBDatabase.cpp. References dbi. |
|
|
Definition at line 387 of file DBDatabase.cpp. References nRecords. Referenced by Dump(), and TeleportDirectoryNotify(). |
|
||||||||||||
|
Definition at line 552 of file DBDatabase.cpp. References DB_MOUNTED, podfile, pread(), pseek(), recLength, and state. Referenced by GetRecordByOffset(), SearchAirportsByFAA(), SearchAirportsByICAO(), and SearchNavaidsByGlobeTile(). |
|
|
Definition at line 382 of file DBDatabase.cpp. References recLength. Referenced by SearchAirportsByFAA(), SearchAirportsByICAO(), and SearchNavaidsByGlobeTile(). |
|
|
Definition at line 600 of file DBDatabase.cpp. References GetRecordByOffset(), and RecordOffset(). Referenced by Dump(), and TeleportDirectoryNotify(). |
|
|
Definition at line 561 of file DBDatabase.cpp. References CDatabaseRecord::AddField(), CDatabaseField::data, dbt, CDatabaseTemplate::GetItem(), GetNumFields(), GetRawRecord(), gtfo, CDatabaseTemplateItem::length, CDatabaseField::length, recordBuffer, CDatabaseTemplateItem::start, CDatabaseTemplateItem::type, and CDatabaseField::type. Referenced by GetRecordByIndex(), and TeleportDirectoryNotify(). |
|
|
Definition at line 127 of file DBDatabase.cpp. References dbt. |
|
|
Definition at line 122 of file DBDatabase.cpp. References dbt, and CDatabaseTemplate::Load(). Referenced by CDatabase(). |
|
|
Definition at line 205 of file DBDatabase.cpp. References globals, Mount(), SGlobals::pfs, and popen(). |
|
|
Definition at line 180 of file DBDatabase.cpp. References DBDHeader::checksum, DB_MOUNTED, dbt, DBDHeader::dummy, CDatabaseTemplate::GetNumItems(), nRecords, DBDHeader::nRecords, podfile, ReadULong(), recLength, DBDHeader::recLength, recordBuffer, DBDHeader::signature, state, DBDHeader::unknown0, and DBDHeader::unknown1. Referenced by LoadDatabases(), and Mount(). |
|
|
Definition at line 595 of file DBDatabase.cpp. References recLength. Referenced by GetRecordByIndex(). |
|
||||||||||||
|
Definition at line 438 of file DBDatabase.cpp. References DB_MOUNTED, GetIndex(), CDatabaseIndex::Search(), search_index, and state. |
|
||||||||||||
|
Definition at line 423 of file DBDatabase.cpp. References DB_MOUNTED, GetIndex(), CDatabaseIndex::Search(), search_index, and state. |
|
||||||||||||
|
Definition at line 408 of file DBDatabase.cpp. References DB_MOUNTED, GetIndex(), CDatabaseIndex::Search(), search_index, and state. Referenced by SearchAirportsByFAA(), SearchAirportsByICAO(), SearchNavaidsByGlobeTile(), and TeleportDirectoryNotify(). |
|
|
Definition at line 459 of file DBDatabase.cpp. References DB_MOUNTED, search_index, CDatabaseIndex::SearchNext(), and state. Referenced by SearchNavaidsByGlobeTile(), and TeleportDirectoryNotify(). |
|
|
Definition at line 217 of file DBDatabase.cpp. References pclose(), and podfile. Referenced by ~CDatabase(). |
|
|
Definition at line 252 of file Database.h. |
|
|
Definition at line 253 of file Database.h. Referenced by CDatabase(), and ~CDatabase(). |
|
|
Definition at line 248 of file Database.h. Referenced by AddIndex(), Dump(), GetIndex(), GetNumIndexes(), and ~CDatabase(). |
|
|
Definition at line 247 of file Database.h. Referenced by Dump(), GetNumFields(), GetRecordByOffset(), GetTemplate(), LoadTemplate(), and Mount(). |
|
|
Definition at line 244 of file Database.h. Referenced by Dump(), GetNumRecords(), and Mount(). |
|
|
Definition at line 242 of file Database.h. Referenced by CDatabase(), GetRawRecord(), Mount(), and Unmount(). |
|
|
Definition at line 245 of file Database.h. Referenced by GetRawRecord(), GetRawRecordLength(), Mount(), and RecordOffset(). |
|
|
Definition at line 250 of file Database.h. Referenced by CDatabase(), GetRecordByOffset(), Mount(), and ~CDatabase(). |
|
|
Definition at line 255 of file Database.h. Referenced by Search(), and SearchNext(). |
|
|
Definition at line 243 of file Database.h. |
|
|
Definition at line 241 of file Database.h. Referenced by CDatabase(), Dump(), GetRawRecord(), Mount(), Search(), and SearchNext(). |
|
|
Documentation generated by
|