|
Open CASCADE Technology
6.7.1
|
#include <NCollection_SList.hxx>

Data Structures | |
| class | SListNode |
| The node of SList. More... | |
Public Member Functions | |
| NCollection_SList (const Handle< NCollection_BaseAllocator > &theAllocator=0L) | |
| Empty constructor. More... | |
| NCollection_SList (const TheItemType &theItem, const NCollection_SList &theTail) | |
| Constructor. More... | |
| NCollection_SList (const NCollection_SList &theOther) | |
| Copy constructor. More... | |
| void | Clear (void) |
| Clear the items out. More... | |
| NCollection_SList & | operator= (const NCollection_SList &theOther) |
| Make this list identical to theOther. More... | |
| virtual void | Assign (const NCollection_BaseCollection< TheItemType > &theOther) |
| Replace this list by the items of theOther collection. More... | |
| Standard_Boolean | IsEmpty (void) const |
| IsEmpty query. More... | |
| virtual const TheItemType & | Value (void) const |
| Value - constant access. More... | |
| virtual TheItemType & | ChangeValue (void) const |
| ChangeValue - variable access. More... | |
| void | SetValue (const TheItemType &theItem) |
| SetValue. More... | |
| const NCollection_SList & | Tail (void) const |
| Tail. More... | |
| NCollection_SList & | ChangeTail (void) |
| ChangeTail. More... | |
| void | SetTail (NCollection_SList &theList) |
| SetTail. More... | |
| void | Construct (const TheItemType &theItem) |
| Construct. More... | |
| NCollection_SList | Constructed (const TheItemType &theItem) const |
| Constructed. More... | |
| void | ToTail (void) |
| ToTail. More... | |
| void | Initialize (const NCollection_SList &theOther) |
| Initialize (~Assign) More... | |
| void | Init (const NCollection_SList &theOther) |
| Init (virtual method of base iterator) More... | |
| virtual Standard_Boolean | More (void) const |
| More (~!IsEmpty) More... | |
| virtual void | Next (void) |
| Next (~ToTail) More... | |
| virtual Standard_Integer | Size (void) const |
| Size - Number of items. More... | |
| ~NCollection_SList (void) | |
| Destructor - clears the SList. More... | |
Public Member Functions inherited from NCollection_BaseCollection< TheItemType > | |
| NCollection_BaseCollection (const Handle< NCollection_BaseAllocator > &theAllocator=0L) | |
| Common for all collections constructor takes care of theAllocator. More... | |
| virtual | ~NCollection_BaseCollection (void) |
| Destructor - must be implemented to release the memory. More... | |
| const Handle < NCollection_BaseAllocator > & | Allocator () const |
| Returns attached allocator. More... | |
Additional Inherited Members | |
Protected Member Functions inherited from NCollection_BaseCollection< TheItemType > | |
| const Handle < NCollection_BaseAllocator > & | IterAllocator (void) const |
| void | exchangeAllocators (NCollection_BaseCollection &theOther) |
| Exchange allocators of two collections. More... | |
Protected Member Functions inherited from NCollection_BaseCollection< TheItemType >::Iterator | |
| Iterator (void) | |
| Empty constructor. More... | |
| virtual | ~Iterator (void) |
| Virtual destructor is necessary for classes with virtual methods. More... | |
| const Iterator & | operator= (const Iterator &) |
| operator= is prohibited More... | |
| Iterator (const Iterator &) | |
| Copy constructor **. More... | |
Protected Attributes inherited from NCollection_BaseCollection< TheItemType > | |
| Handle< NCollection_BaseAllocator > | myAllocator |
Purpose: An SList is a LISP like list of Items. An SList is : . Empty. . Or it has a Value and a Tail which is an other SList.
The Tail of an empty list is an empty list. SList are shared. It means that they can be modified through other lists. SList may be used as Iterators. They have Next, More, and value methods. To iterate on the content of the list S just do.
SList Iterator; for (Iterator = S; Iterator.More(); Iterator.Next()) X = Iterator.Value();
Memory usage is automatically managed for SLists (using reference counts).
Example: If S1 and S2 are SLists : if S1.Value() is X.
And the following is done : S2 = S1; S2.SetValue(Y);
S1.Value() becomes also Y. So SList must be used with care. Mainly the SetValue() method is dangerous.
|
inline |
Empty constructor.
|
inline |
Constructor.
|
inline |
Copy constructor.
|
inline |
Destructor - clears the SList.
|
inlinevirtual |
Replace this list by the items of theOther collection.
Implements NCollection_BaseCollection< TheItemType >.
|
inline |
ChangeTail.
|
inlinevirtual |
ChangeValue - variable access.
Implements NCollection_BaseCollection< TheItemType >::Iterator.
|
inline |
Clear the items out.
|
inline |
Construct.
|
inline |
Constructed.
|
inline |
Init (virtual method of base iterator)
|
inline |
Initialize (~Assign)
|
inline |
IsEmpty query.
|
inlinevirtual |
More (~!IsEmpty)
Implements NCollection_BaseCollection< TheItemType >::Iterator.
|
inlinevirtual |
Next (~ToTail)
Implements NCollection_BaseCollection< TheItemType >::Iterator.
|
inline |
Make this list identical to theOther.
|
inline |
SetTail.
|
inline |
SetValue.
|
inlinevirtual |
Size - Number of items.
Implements NCollection_BaseCollection< TheItemType >.
|
inline |
Tail.
|
inline |
ToTail.
|
inlinevirtual |
Value - constant access.
Implements NCollection_BaseCollection< TheItemType >::Iterator.
1.8.5