Main Page   Namespace List   Class Hierarchy   Compound List   File List   Namespace Members   Compound Members   File Members  

ZResReader Class Reference

Base class for resource readers. More...

#include <ZResource.h>

Inheritance diagram for ZResReader::

ZResFileReader ZSkin List of all members.

Public Methods

virtual ~ZResReader ()
 virtual distructor. More...

virtual bool exists (const QString &ID) const=0
 return bool indicating whether or not a resource exists. More...

virtual bool get (const QString &ID, unsigned char **ppOutData, int *pOutLength) const=0
 get data for a resource. More...

virtual QString getFirstID ()
 get the first resource ID in this resource reader. More...

virtual QString getNextID ()
 get the next resource ID in this resource reader. More...


Detailed Description

Base class for resource readers.

A resource reader is used to get icons and other resources. Most of the methods of this class are not implemented.


Constructor & Destructor Documentation

ZResReader::~ZResReader ( ) [virtual]
 

virtual distructor.

Derived classes should reimplement if they have cleanup to do.


Member Function Documentation

bool ZResReader::exists ( const QString & ID ) const [pure virtual]
 

return bool indicating whether or not a resource exists.

Parameters:
ID   resource ID to lookup (something.g for a graphic, for example)
Returns:
bool indicating whether or not the resource exists

Reimplemented in ZResFileReader, and ZSkin.

bool ZResReader::get ( const QString & ID,
unsigned char ** ppOutData,
int * pOutLength ) const [pure virtual]
 

get data for a resource.

Parameters:
ID   the resource ID for the resource
ppOutData   out-pointer for the resource data
pOutLength   out-integer for the size in bytes of the data

Note:
Do not delete/de-allocate the pointer returned from this function.

Reimplemented in ZResFileReader, and ZSkin.

QString ZResReader::getFirstID ( ) [virtual]
 

get the first resource ID in this resource reader.

Note:
this function is not thread safe
Returns:
first resource ID

Reimplemented in ZResFileReader.

QString ZResReader::getNextID ( ) [virtual]
 

get the next resource ID in this resource reader.

Note:
this function in not thread safe
Returns:
current resource ID, increments iterator

Reimplemented in ZResFileReader.


The documentation for this class was generated from the following file:
Generated at Wed Mar 3 13:23:08 2004 by doxygen1.2.8.1 written by Dimitri van Heesch, © 1997-2001