|
Unicorn XML Toolkit Version 1.00.00 |
|||||||||
� PREV CLASS �� NEXT CLASS | FRAMES��NO FRAMES | |||||||||
SUMMARY: � CONSTR �|� FUNCTION �|�DATA | DETAIL: � CONSTR �|� FUNCTION �|�DATA |
class CSortedArray: public CInterface { public: CSortedArray(); virtual ~CSortedArray(); public: virtual void AddSortAttributes( const CSortAttributes &sortAttributes) = 0; virtual void Add( const XNode &pNode, const XSortKey &pKey) = 0; virtual void Sort() = 0; virtual int GetSize() = 0; virtual XNode GetAt(int nIndex) = 0; virtual XSortedArrayIndex CreateIndex() = 0; };
The abstract interface to sorted arrays of nodes.
The sort order is specified by the list of sort attributes attached to the array.
The array is not sorted automatically when new nodes
are added. The member function
Sort
must be explicitly called to sort the array.
CSortAttributes, CSortKey, CSortedArrayIndex, Dom::INode
Constructor/Destructor Summary | |
CSortedArray
();
����������Constructs the sorted array. |
|
~CSortedArray
();
����������Destroys the sorted array. |
Function Summary | |
void
|
AddSortAttributes
(const CSortAttributes &sortAttributes);
����������Adds the set of sort attributes to the end of the list of sort attributes attached to this array. |
void
|
Add
(const XNode &pNode, const XSortKey &pKey);
����������Adds the node to this array. |
void
|
Sort
();
����������Sorts this array. |
int
|
GetSize
();
����������Returns the number of nodes in this array. |
XNode
|
GetAt
(int nIndex);
����������Returns the node at the given index in this array. |
XSortedArrayIndex
|
CreateIndex
();
����������Creates an index for this array. |
Constructor/Destructor Detail |
CSortedArray();
Constructs the sorted array.
virtual ~CSortedArray();
Destroys the sorted array.
Function Detail |
virtual void AddSortAttributes( const CSortAttributes &sortAttributes) = 0;
Adds the set of sort attributes to the end of the list of sort attributes attached to this array.
sortAttributes
- the set of sort attributes to addvirtual void Add( const XNode &pNode, const XSortKey &pKey) = 0;
Adds the node to this array.
pNode
- the node to addpKey
- the sort key of the node to addvirtual void Sort() = 0;
Sorts this array.
virtual int GetSize() = 0;
Returns the number of nodes in this array.
virtual XNode GetAt(int nIndex) = 0;
Returns the node at the given index in this array.
nIndex
- the index of the node (zero-based)virtual XSortedArrayIndex CreateIndex() = 0;
Creates an index for this array.
The index profides an interface for sequential enumeration
of nodes in the sorted array.
See description of the
CSortedArrayIndex
class for details.
|
Unicorn XML Toolkit Version 1.00.00 |
|||||||||
� PREV CLASS �� NEXT CLASS | FRAMES��NO FRAMES | |||||||||
SUMMARY: � CONSTR �|� FUNCTION �|�DATA | DETAIL: � CONSTR �|� FUNCTION �|�DATA |