Xalan-C++ API Documentation

The Xalan C++ XSLT Processor Version 1.10

Classes | Public Types | Public Member Functions | Static Public Member Functions | List of all members
MutableNodeRefList Class Reference

Local implementation of MutableNodeRefList. More...

Inheritance diagram for MutableNodeRefList:
NodeRefList NodeRefListBase

Classes

class  addNodeInDocOrderFunctor
 

Public Types

typedef
NodeListVectorType::iterator 
NodeListIteratorType
 
- Public Types inherited from NodeRefList
typedef XalanVector< XalanNode * > NodeListVectorType
 
- Public Types inherited from NodeRefListBase
typedef unsigned int size_type
 

Public Member Functions

 MutableNodeRefList (MemoryManagerType &theManager)
 Construct an empty mutable node list. More...
 
 MutableNodeRefList (const MutableNodeRefList &theSource, MemoryManagerType &theManager)
 Construct a mutable node list from another list. More...
 
 MutableNodeRefList (const NodeRefListBase &theSource, MemoryManagerType &theManager)
 Construct a mutable node list from another list. More...
 
virtual ~MutableNodeRefList ()
 
MutableNodeRefListoperator= (const MutableNodeRefList &theRHS)
 
MutableNodeRefListoperator= (const NodeRefList &theRHS)
 
MutableNodeRefListoperator= (const NodeRefListBase &theRHS)
 
MutableNodeRefListoperator= (const XalanNodeList *theRHS)
 
void addNode (XalanNode *n)
 Add a node at to the list. More...
 
void insertNode (XalanNode *n, size_type pos)
 Insert a node at a given position. More...
 
void removeNode (const XalanNode *n)
 Remove a node from the list. More...
 
void removeNode (size_type pos)
 Remove a node from the list. More...
 
void clear ()
 Remove all nodes. More...
 
void setNode (size_type pos, XalanNode *n=0)
 Set a item. More...
 
void addNodes (const XalanNodeList &nodelist)
 Copy NodeList members into this nodelist, adding in document order. More...
 
void addNodes (const NodeRefListBase &nodelist)
 Copy NodeList members into this nodelist, adding in document order. More...
 
void addNodesInDocOrder (const XalanNodeList &nodelist, XPathExecutionContext &executionContext)
 Copy NodeList members into this nodelist, adding in document order. More...
 
void addNodesInDocOrder (const NodeRefListBase &nodelist, XPathExecutionContext &executionContext)
 Copy NodeList members into this nodelist, adding in document order. More...
 
void addNodesInDocOrder (const MutableNodeRefList &nodelist, XPathExecutionContext &executionContext)
 Copy NodeList members into this nodelist, adding in document order. More...
 
void addNodeInDocOrder (XalanNode *node, XPathExecutionContext &executionContext)
 Add a node into list where it should occur in document order. More...
 
void clearNulls ()
 Clear any null entries in the node list. More...
 
void reverse ()
 Reverse the nodes in the list. More...
 
void reserve (size_type theCount)
 Reserve space for the supplied number of nodes. More...
 
bool getUnknownOrder () const
 See if the order of the nodes is an unknown order. More...
 
void setUnknownOrder ()
 
bool getDocumentOrder () const
 See if the order of the nodes is document order. More...
 
void setDocumentOrder ()
 Set the known order of the nodes. More...
 
bool getReverseDocumentOrder () const
 See if the order of the nodes is reverse document order. More...
 
void setReverseDocumentOrder ()
 Set the known order of the nodes. More...
 
void swap (MutableNodeRefList &theOther)
 
- Public Member Functions inherited from NodeRefList
 NodeRefList (MemoryManagerType &theManager XALAN_DEFAULT_CONSTRACTOR_MEMORY_MGR)
 
 NodeRefList (const NodeRefList &theSource, MemoryManagerType &theManager XALAN_DEFAULT_CONSTRACTOR_MEMORY_MGR)
 Construct a node list from another. More...
 
MemoryManagerTypegetMemoryManager ()
 
 NodeRefList (const NodeRefListBase &theSource, MemoryManagerType &theManager XALAN_DEFAULT_CONSTRACTOR_MEMORY_MGR)
 Construct a node list from another. More...
 
virtual ~NodeRefList ()
 
NodeRefListoperator= (const NodeRefListBase &theRHS)
 
NodeRefListoperator= (const NodeRefList &theRHS)
 
bool empty () const
 
virtual XalanNodeitem (size_type index) const
 Returns the indexth item in the collection. More...
 
virtual size_type getLength () const
 Determine the number of nodes in the list. More...
 
virtual size_type indexOf (const XalanNode *theNode) const
 Retrieve the zero based index of the node in the list. More...
 
bool checkForDuplicates (MemoryManagerType &theManager) const
 
void swap (NodeRefList &theOther)
 
- Public Member Functions inherited from NodeRefListBase
 NodeRefListBase ()
 
virtual ~NodeRefListBase ()
 

Static Public Member Functions

static MutableNodeRefListcreate (MemoryManagerType &theManager)
 

Additional Inherited Members

- Static Public Attributes inherited from NodeRefListBase
static const size_type npos
 
- Protected Types inherited from NodeRefList
enum  { eDefaultVectorSize = 100 }
 
- Protected Member Functions inherited from NodeRefList
void ensureAllocation (NodeListVectorType::size_type theSize=0)
 Ensure that an allocation is either the default allocation amount, or the amount specified in the parameter, whichever is larger. More...
 
- Protected Attributes inherited from NodeRefList
NodeListVectorType m_nodeList
 

Detailed Description

Local implementation of MutableNodeRefList.

This class is for internal use only.

Member Typedef Documentation

Constructor & Destructor Documentation

MutableNodeRefList::MutableNodeRefList ( MemoryManagerType theManager)
explicit

Construct an empty mutable node list.

MutableNodeRefList::MutableNodeRefList ( const MutableNodeRefList theSource,
MemoryManagerType theManager 
)

Construct a mutable node list from another list.

Parameters
theSourcesource list
MutableNodeRefList::MutableNodeRefList ( const NodeRefListBase theSource,
MemoryManagerType theManager 
)
explicit

Construct a mutable node list from another list.

Parameters
theSourcesource list
virtual MutableNodeRefList::~MutableNodeRefList ( )
virtual

Member Function Documentation

void MutableNodeRefList::addNode ( XalanNode n)

Add a node at to the list.

Parameters
nnode to add
void MutableNodeRefList::addNodeInDocOrder ( XalanNode node,
XPathExecutionContext executionContext 
)

Add a node into list where it should occur in document order.

Parameters
nodenode object to add
executionContextthe current execution context
void MutableNodeRefList::addNodes ( const XalanNodeList nodelist)

Copy NodeList members into this nodelist, adding in document order.

If a node is null, don't add it.

Parameters
nodelistnode list to add
void MutableNodeRefList::addNodes ( const NodeRefListBase nodelist)

Copy NodeList members into this nodelist, adding in document order.

If a node is null, don't add it.

Parameters
nodelistnode list to add
void MutableNodeRefList::addNodesInDocOrder ( const XalanNodeList nodelist,
XPathExecutionContext executionContext 
)

Copy NodeList members into this nodelist, adding in document order.

Parameters
nodelistnode list to add
executionContextthe current execution context
void MutableNodeRefList::addNodesInDocOrder ( const NodeRefListBase nodelist,
XPathExecutionContext executionContext 
)

Copy NodeList members into this nodelist, adding in document order.

Parameters
nodelistnode list to add
executionContextthe current execution context
void MutableNodeRefList::addNodesInDocOrder ( const MutableNodeRefList nodelist,
XPathExecutionContext executionContext 
)

Copy NodeList members into this nodelist, adding in document order.

Parameters
nodelistnode list to add
executionContextthe current execution context
void MutableNodeRefList::clear ( )

Remove all nodes.

void MutableNodeRefList::clearNulls ( )

Clear any null entries in the node list.

static MutableNodeRefList* MutableNodeRefList::create ( MemoryManagerType theManager)
static
bool MutableNodeRefList::getDocumentOrder ( ) const

See if the order of the nodes is document order.

bool MutableNodeRefList::getReverseDocumentOrder ( ) const

See if the order of the nodes is reverse document order.

bool MutableNodeRefList::getUnknownOrder ( ) const

See if the order of the nodes is an unknown order.

void MutableNodeRefList::insertNode ( XalanNode n,
size_type  pos 
)

Insert a node at a given position.

Parameters
nnode to insert
posposition of insertion
MutableNodeRefList& MutableNodeRefList::operator= ( const MutableNodeRefList theRHS)
MutableNodeRefList& MutableNodeRefList::operator= ( const NodeRefList theRHS)
MutableNodeRefList& MutableNodeRefList::operator= ( const NodeRefListBase theRHS)
MutableNodeRefList& MutableNodeRefList::operator= ( const XalanNodeList theRHS)
void MutableNodeRefList::removeNode ( const XalanNode n)

Remove a node from the list.

Parameters
nnode to insert
void MutableNodeRefList::removeNode ( size_type  pos)

Remove a node from the list.

Parameters
posposition of node in list
void MutableNodeRefList::reserve ( size_type  theCount)

Reserve space for the supplied number of nodes.

This is taken as an optimization, and may be ignored. You might want to call this when you know the number of nodes you're about to add to this list.

Remember to take into account the current size of the list when calling this. That means you will probably want to add the result of getLength() to the number of nodes you're planning to add.

Parameters
theCountthe number of nodes to reserve space for
void MutableNodeRefList::reverse ( )

Reverse the nodes in the list.

void MutableNodeRefList::setDocumentOrder ( )

Set the known order of the nodes.

This should only be done when the order is known. Otherwise, disaster will ensue.

void MutableNodeRefList::setNode ( size_type  pos,
XalanNode n = 0 
)

Set a item.

Parameters
posposition of node to modify
nnode to insert, default is empty node
void MutableNodeRefList::setReverseDocumentOrder ( )

Set the known order of the nodes.

This should only be done when the order is known. Otherwise, disaster will ensue.

void MutableNodeRefList::setUnknownOrder ( )
void MutableNodeRefList::swap ( MutableNodeRefList theOther)

The documentation for this class was generated from the following file:

Interpreting class diagrams

Doxygen and GraphViz are used to generate this API documentation from the Xalan-C header files.

dot

Xalan-C++ XSLT Processor Version 1.10
Copyright © 1999-2004 The Apache Software Foundation. All Rights Reserved.

Apache Logo