Public Member Functions | |
void | add_multifile_record (PT(MultifileRecord) mfr) |
string | get_multifile_name (int index) const |
int | get_num_multifiles () const |
bool | multifile_exists (string mfname) const |
int | parse_header (const string &data) |
Verifies magic number, returns the number of multifiles or -1 if invalid. | |
int | parse_record_header (const string &data) |
Parses a file record (fr) header and returns the length of the next file record. | |
PT (MultifileRecord) get_multifile_record_named(string mfname) const | |
PT (MultifileRecord) parse_mfr(const string &data) | |
PT (FileRecord) parse_fr(const string &data) | |
bool | read (StreamReader &sr, bool want_server_info) |
void | write (ostream &out) const |
bool | write (StreamWriter &sw, bool want_server_info) |
bool | write_bogus_header (StreamWriter &sw) |
Writes the bogus header uncompressed with platform- independent byte ordering. | |
bool | write_header (ostream &write_stream) |
Writes the header uncompressed with platform- independent byte ordering. | |
Public Attributes | |
Filename | _filename |
MultifileRecords | _mfile_records |
Definition at line 171 of file downloadDb.h.
int DownloadDb::Db::parse_header | ( | const string & | data | ) |
Verifies magic number, returns the number of multifiles or -1 if invalid.
Definition at line 678 of file downloadDb.cxx.
References DatagramIterator::get_int32(), and DatagramIterator::get_uint32().
int DownloadDb::Db::parse_record_header | ( | const string & | data | ) |
Parses a file record (fr) header and returns the length of the next file record.
Definition at line 721 of file downloadDb.cxx.
References DatagramIterator::get_int32().
bool DownloadDb::Db::write_bogus_header | ( | StreamWriter & | sw | ) |
Writes the bogus header uncompressed with platform- independent byte ordering.
This header will get overwritten with the real magic number as the last step in the write
Definition at line 987 of file downloadDb.cxx.
References StreamWriter::add_int32(), and StreamWriter::add_uint32().
bool DownloadDb::Db::write_header | ( | ostream & | write_stream | ) |
Writes the header uncompressed with platform- independent byte ordering.
Definition at line 1004 of file downloadDb.cxx.
References Datagram::add_int32(), Datagram::add_uint32(), and Datagram::get_message().