RawArchive Class Reference

#include <RawArchive.h>

Inheritance diagram for RawArchive:

Pentagram::Archive UsecodeFlex List of all members.

Public Member Functions

 ENABLE_RUNTIME_CLASSTYPE ()
 RawArchive ()
 RawArchive (ArchiveFile *af)
 RawArchive (IDataSource *ids)
 RawArchive (const std::string &path)
virtual ~RawArchive ()
virtual void cache (uint32 index)
virtual void uncache (uint32 index)
virtual bool isCached (uint32 index)
virtual const uint8get_object_nodel (uint32 index)
virtual uint8get_object (uint32 index)
virtual uint32 get_size (uint32 index)
virtual IDataSourceget_datasource (uint32 index)

Protected Attributes

std::vector< uint8 * > objects

Detailed Description

Definition at line 27 of file RawArchive.h.


Constructor & Destructor Documentation

RawArchive::RawArchive (  )  [inline]

Definition at line 32 of file RawArchive.h.

RawArchive::RawArchive ( ArchiveFile af  )  [inline, explicit]

Definition at line 33 of file RawArchive.h.

RawArchive::RawArchive ( IDataSource ids  )  [inline, explicit]

Definition at line 34 of file RawArchive.h.

RawArchive::RawArchive ( const std::string &  path  )  [inline, explicit]

Definition at line 35 of file RawArchive.h.

RawArchive::~RawArchive (  )  [virtual]

Definition at line 27 of file RawArchive.cpp.


Member Function Documentation

void RawArchive::cache ( uint32  index  )  [virtual]

Cache a single object.

Implements Pentagram::Archive.

Definition at line 32 of file RawArchive.cpp.

References Pentagram::Archive::count, Pentagram::Archive::getRawObject(), and objects.

RawArchive::ENABLE_RUNTIME_CLASSTYPE (  ) 

Reimplemented from Pentagram::Archive.

IDataSource * RawArchive::get_datasource ( uint32  index  )  [virtual]

return object as IDataSource. Delete the IDataSource afterwards, but DON'T delete/modify the buffer it points to.

Definition at line 90 of file RawArchive.cpp.

References Pentagram::Archive::cache(), Pentagram::Archive::count, Pentagram::Archive::getRawSize(), and objects.

Referenced by WpnOvlayDat::load(), GameData::loadRemorseData(), GameData::loadU8Data(), SKFPlayer::run(), SKFPlayer::SKFPlayer(), and World::switchMap().

uint8 * RawArchive::get_object ( uint32  index  )  [virtual]

return object. delete afterwards. This will not cache the object

Definition at line 68 of file RawArchive.cpp.

References Pentagram::Archive::count, Pentagram::Archive::getRawObject(), Pentagram::Archive::getRawSize(), and objects.

Referenced by SKFPlayer::run().

const uint8 * RawArchive::get_object_nodel ( uint32  index  )  [virtual]

return object. DON'T delete or modify!

Definition at line 61 of file RawArchive.cpp.

References Pentagram::Archive::cache(), Pentagram::Archive::count, and objects.

Referenced by GameDetector::detect(), UsecodeFlex::get_class(), UsecodeFlex::get_class_base_offset(), and UsecodeFlex::get_class_name().

uint32 RawArchive::get_size ( uint32  index  )  [virtual]

get size of object

Definition at line 84 of file RawArchive.cpp.

References Pentagram::Archive::count, and Pentagram::Archive::getRawSize().

Referenced by GameDetector::detect(), UsecodeFlex::get_class_base_offset(), UsecodeFlex::get_class_event_count(), UsecodeFlex::get_class_name(), UsecodeFlex::get_class_size(), and SKFPlayer::run().

bool RawArchive::isCached ( uint32  index  )  [virtual]

Check if an object is cached.

Implements Pentagram::Archive.

Definition at line 53 of file RawArchive.cpp.

References Pentagram::Archive::count, and objects.

void RawArchive::uncache ( uint32  index  )  [virtual]

Uncache a single object Potentially dangerous. See uncache()

Implements Pentagram::Archive.

Definition at line 42 of file RawArchive.cpp.

References Pentagram::Archive::count, and objects.


Member Data Documentation

std::vector<uint8*> RawArchive::objects [protected]

Definition at line 57 of file RawArchive.h.

Referenced by cache(), get_datasource(), get_object(), get_object_nodel(), isCached(), and uncache().


The documentation for this class was generated from the following files:
Generated on Fri Jul 27 22:29:49 2007 for pentagram by  doxygen 1.4.7