Sourceforge.net - The VCF's Project Host
   The VCF Website Home   |   Online Discussion Forums   |   Sourceforge.net Project Page   

VCFCOM::EnumObject< T > Class Template Reference

Template class to make it easy to create IEnumXXX objects. More...

#include <EnumObject.h>

List of all members.

Public Member Functions

 EnumObject ()
 EnumObject (const EnumObject &enumObj)
virtual ~EnumObject ()
virtual void add (T item)
 Use this function to add data to initialize the enum object.
void initList () throw ( VCF::CantCreateObjectException )
HRESULT _Next (ULONG elementsRequested, T *elementList, ULONG *elementsFetched)
 Retrieves the next elementsRequested items in the enumeration sequence.
HRESULT _Skip (ULONG elementsToSkip)
 Skips over the next specified number of elements in the enumeration sequence.
HRESULT _Reset (void)
 Resets the enumeration sequence to the beginning.

Protected Attributes

std::vector< _typename_ T > items_
_typename_ std::vector< _typename_
T >::iterator 
itemIterator_
unsigned long currentPos_


Detailed Description

template<class T>
class VCFCOM::EnumObject< T >

Template class to make it easy to create IEnumXXX objects.


Constructor & Destructor Documentation

template<class T>
VCFCOM::EnumObject< T >::EnumObject  )  [inline]
 

template<class T>
VCFCOM::EnumObject< T >::EnumObject const EnumObject< T > &  enumObj  )  [inline]
 

template<class T>
virtual VCFCOM::EnumObject< T >::~EnumObject  )  [inline, virtual]
 


Member Function Documentation

template<class T>
HRESULT VCFCOM::EnumObject< T >::_Next ULONG  elementsRequested,
T *  elementList,
ULONG *  elementsFetched
[inline]
 

Retrieves the next elementsRequested items in the enumeration sequence.

If there are fewer than the requested number of elements left in the sequence, it retrieves the remaining elements. The number of elements actually retrieved is returned through elementsFetched (unless the caller passed in NULL for that parameter).

Parameters:
ULONG elementsRequested - number of elements to fetch
T *elementList - an array of elements of type <T>
ULONG *elementsFetched - the numbers of items in the elementList array

template<class T>
HRESULT VCFCOM::EnumObject< T >::_Reset void   )  [inline]
 

Resets the enumeration sequence to the beginning.

template<class T>
HRESULT VCFCOM::EnumObject< T >::_Skip ULONG  elementsToSkip  )  [inline]
 

Skips over the next specified number of elements in the enumeration sequence.

Parameters:
ULONG elementsToSkip - the number of items to skip over

template<class T>
virtual void VCFCOM::EnumObject< T >::add item  )  [inline, virtual]
 

Use this function to add data to initialize the enum object.

template<class T>
void VCFCOM::EnumObject< T >::initList  )  throw ( VCF::CantCreateObjectException ) [inline]
 


Member Data Documentation

template<class T>
unsigned long VCFCOM::EnumObject< T >::currentPos_ [protected]
 

template<class T>
_typename_ std::vector<_typename_ T>::iterator VCFCOM::EnumObject< T >::itemIterator_ [protected]
 

template<class T>
std::vector<_typename_ T> VCFCOM::EnumObject< T >::items_ [protected]
 


The documentation for this class was generated from the following file:
   Comments or Suggestions?    License Information