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

TResourceCollection Class Reference

Implements a sorted, streamable collection of resources. More...

#include <resource.h>

Inheritance diagram for TResourceCollection::

TStringCollection TSortedCollection TNSSortedCollection TCollection TNSCollection TNSCollection TStreamable TObject TObject List of all members.

Public Methods

 TResourceCollection (StreamableInit)
 TResourceCollection (short aLimit, short aDelta)
virtual void* keyOf (void *item)

Static Public Methods

TStreamablebuild ()

Static Public Attributes

const char* const name

Detailed Description

TResourceCollection is a derivative of TStringCollection, which makes it a sorted, streamable collection. It is used with TResourceFile to implement collections of resources. A resource file is a stream that is indexed by key strings. Each resource item points to an object of type TResourceItem.

Definition at line 147 of file resource.h.


Constructor & Destructor Documentation

TResourceCollection::TResourceCollection ( StreamableInit ) [inline]
 

Each streamable class needs a "builder" to allocate the correct memory for its objects together with the initialized vtable pointers. This is achieved by calling this constructor with an argument of type StreamableInit.

Definition at line 156 of file resource.h.

TResourceCollection::TResourceCollection ( short aLimit,
short aDelta )
 

Creates a resource collection with initial size `aLimit' and the ability to resize by `aDelta'.


Member Function Documentation

TStreamable * TResourceCollection::build ( ) [static]
 

Called to create an object in certain stream-reading situations.

Reimplemented from TStringCollection.

void * TResourceCollection::keyOf ( void * item ) [virtual]
 

Returns the key of the given item.

Reimplemented from TNSSortedCollection.


Member Data Documentation

const char *const TResourceCollection::name [static]
 

Class name used by the stream manager.

Reimplemented from TStringCollection.

Definition at line 196 of file resource.h.


The documentation for this class was generated from the following file:
Generated at Sat Sep 22 20:19:32 2001 for TVision by doxygen1.2.8.1 written by Dimitri van Heesch, © 1997-2001