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

Data Structures | |
| class | DataMapNode |
| class | Iterator |
Public Member Functions | |
| NCollection_DataMap (const Standard_Integer NbBuckets=1, const Handle< NCollection_BaseAllocator > &theAllocator=0L) | |
| Constructor. More... | |
| NCollection_DataMap (const NCollection_DataMap &theOther) | |
| Copy constructor. More... | |
| virtual void | Assign (const NCollection_BaseCollection< TheItemType > &theOther) |
| Assign another collection. More... | |
| void | Exchange (NCollection_DataMap &theOther) |
| Exchange the content of two maps without re-allocations. Notice that allocators will be swapped as well! More... | |
| NCollection_DataMap & | operator= (const NCollection_DataMap &theOther) |
| = another map More... | |
| void | ReSize (const Standard_Integer N) |
| ReSize. More... | |
| Standard_Boolean | Bind (const TheKeyType &theKey, const TheItemType &theItem) |
| Bind. More... | |
| Standard_Boolean | IsBound (const TheKeyType &K) const |
| IsBound. More... | |
| Standard_Boolean | UnBind (const TheKeyType &K) |
| UnBind. More... | |
| const TheItemType & | Find (const TheKeyType &theKey) const |
| Find. More... | |
| Standard_Boolean | Find (const TheKeyType &theKey, TheItemType &theValue) const |
| Find value for key with copying. More... | |
| const TheItemType & | operator() (const TheKeyType &theKey) const |
| operator () More... | |
| TheItemType & | ChangeFind (const TheKeyType &theKey) |
| ChangeFind. More... | |
| TheItemType & | operator() (const TheKeyType &theKey) |
| operator () More... | |
| void | Clear (const Standard_Boolean doReleaseMemory=Standard_True) |
| Clear data. If doReleaseMemory is false then the table of buckets is not released and will be reused. More... | |
| void | Clear (const Handle< NCollection_BaseAllocator > &theAllocator) |
| Clear data and reset allocator. More... | |
| ~NCollection_DataMap (void) | |
| Destructor. More... | |
| virtual Standard_Integer | Size (void) const |
| Size. 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... | |
Public Member Functions inherited from NCollection_BaseMap | |
| Standard_Integer | NbBuckets () const |
| NbBuckets. More... | |
| Standard_Integer | Extent () const |
| Extent. More... | |
| Standard_Boolean | IsEmpty () const |
| IsEmpty. More... | |
| void | Statistics (Standard_OStream &S) const |
| Statistics. More... | |
Purpose: The DataMap is a Map to store keys with associated Items. See Map from NCollection for a discussion about the number of buckets.
The DataMap can be seen as an extended array where the Keys are the indices. For this reason the operator () is defined on DataMap to fetch an Item from a Key. So the following syntax can be used :
anItem = aMap(aKey); aMap(aKey) = anItem;
This analogy has its limit. aMap(aKey) = anItem can be done only if aKey was previously bound to an item in the map.
|
inline |
Constructor.
|
inline |
Copy constructor.
|
inline |
Destructor.
|
inlinevirtual |
Assign another collection.
Implements NCollection_BaseCollection< TheItemType >.
|
inline |
Bind.
|
inline |
ChangeFind.
|
inline |
Clear data. If doReleaseMemory is false then the table of buckets is not released and will be reused.
|
inline |
Clear data and reset allocator.
|
inline |
Exchange the content of two maps without re-allocations. Notice that allocators will be swapped as well!
|
inline |
Find.
|
inline |
Find value for key with copying.
|
inline |
IsBound.
|
inline |
operator ()
|
inline |
operator ()
|
inline |
= another map
|
inline |
ReSize.
|
inlinevirtual |
Size.
Implements NCollection_BaseCollection< TheItemType >.
|
inline |
UnBind.
1.8.5