Open Inventor Reference
SoNodeList Class Reference

Maintains a list of pointers to nodes. More...

#include <Inventor/SoLists.h>

Inheritance diagram for SoNodeList:
SoBaseList SbPList SoChildList

Public Member Functions

 SoNodeList ()
 
 SoNodeList (int size)
 
 SoNodeList (const SoNodeList &l)
 
 ~SoNodeList ()
 Destructor. More...
 
void append (SoNode *ptr)
 Adds a pointer to the end of the list. More...
 
SoNodeListoperator= (const SoNodeList &l)
 Copies a list, keeping all reference counts correct. More...
 
SoNodeoperator[] (int i) const
 
- Public Member Functions inherited from SoBaseList
 SoBaseList ()
 Constructor. More...
 
 SoBaseList (int size)
 Constructor that pre-allocates storage for size pointers. More...
 
 SoBaseList (const SoBaseList &l)
 Constructor that copies the contents of another list. More...
 
 ~SoBaseList ()
 Destructor. More...
 
void append (SoBase *ptr)
 Adds a pointer to the end of the list. More...
 
void insert (SoBase *ptr, int addBefore)
 Inserts given pointer in list before pointer with given index. More...
 
void remove (int which)
 Removes pointer with given index. More...
 
void truncate (int start)
 Removes all pointers after one with given index, inclusive. More...
 
void copy (const SoBaseList &l)
 Copies a list, keeping all reference counts correct. More...
 
SoBaseListoperator= (const SoBaseList &l)
 Copies a list, keeping all reference counts correct. More...
 
SoBaseoperator[] (int i) const
 Access an element of a list. More...
 
void set (int i, SoBase *ptr)
 Sets an element of a list. More...
 
void addReferences (bool flag)
 Indicates whether to call ref() and unref() for bases in the list when adding/removing them. More...
 
- Public Member Functions inherited from SbPList
 SbPList ()
 Constructor. More...
 
 SbPList (int initSize)
 initSize specifies an initial size for the list, which is useful as an optimization if you can estimate the length of the list before you construct it. More...
 
 SbPList (const SbPList &pl)
 Copy constructor. More...
 
 ~SbPList ()
 Destructor. More...
 
void append (void *ptr)
 Adds given pointer to end of list. More...
 
int find (const void *ptr) const
 Returns index of given pointer in list, or -1 if not found. More...
 
void insert (void *ptr, int addBefore)
 Inserts given pointer in list before pointer with given index. More...
 
void remove (int which)
 Removes pointer with given index. More...
 
int getLength () const
 Returns number of pointers in list. More...
 
void truncate (int start)
 Removes all pointers after one with given index, inclusive. More...
 
void copy (const SbPList &pl)
 Copy a list. More...
 
SbPListoperator= (const SbPList &pl)
 Assignment operator; copies list into this list. More...
 
void *& operator[] (int i) const
 Returns pointer with given index. More...
 
bool operator== (const SbPList &pl) const
 Equality and inequality operators. More...
 
bool operator!= (const SbPList &pl) const
 Equality and inequality operators. More...
 
void * get (int i) const
 Internal versions of [] that do not check for bounds: More...
 
void set (int i, void *j)
 

Detailed Description

This subclass of SoBaseList holds lists of pointers to SoNodes. It updates reference counts to nodes in the list whenever adding or removing pointers.

See Also
SoNode

Definition at line 177 of file SoLists.h.

Constructor & Destructor Documentation

◆ SoNodeList() [1/3]

SoNodeList::SoNodeList ( )
inline

Definition at line 179 of file SoLists.h.

◆ SoNodeList() [2/3]

SoNodeList::SoNodeList ( int  size)
inline

Definition at line 180 of file SoLists.h.

◆ SoNodeList() [3/3]

SoNodeList::SoNodeList ( const SoNodeList l)
inline

Definition at line 181 of file SoLists.h.

◆ ~SoNodeList()

SoNodeList::~SoNodeList ( )
inline

Definition at line 183 of file SoLists.h.

Member Function Documentation

◆ append()

void SoNodeList::append ( SoNode ptr)
inline

Definition at line 186 of file SoLists.h.

◆ operator=()

SoNodeList& SoNodeList::operator= ( const SoNodeList l)
inline

Definition at line 190 of file SoLists.h.

References SoBaseList::copy().

◆ operator[]()

SoNode* SoNodeList::operator[] ( int  i) const
inline

Definition at line 193 of file SoLists.h.


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