casacore
|
Representation class for an Ordered Map. More...
#include <OrderedMap.h>
Public Types | |
enum | { OrderedMapRepVersion } |
Public Types inherited from casacore::MapRep< key, value > | |
enum | { MapRepVersion } |
Public Member Functions | |
OrderedMapRep (const value &, uInt size) | |
Creates a map with the specified default value, "value", and the internal block size. More... | |
OrderedMapRep (const value &) | |
Creates a map with the specified default value, "value". More... | |
value * | isDefined (const key &) |
These functions check to see if a mapping is defined between the specified key and some value. More... | |
const value * | isDefined (const key &) const |
Returns a non-zero value if a mapping is defined for the key parameter. More... | |
uInt | ndefined () const |
Returns the number of user defined mappings. More... | |
value & | define (const key &, const value &) |
Defines a mapping (ie. More... | |
void | remove (const key &) |
Undefines a mapping (ie. More... | |
void | clear () |
Clear the entire map (ie. More... | |
MapIterRep< key, value > * | getRep (Map< key, value > *) const |
MapRep< key, value > * | Clone () const |
uInt | nused () const |
Get the number of mappings. More... | |
uInt | ntot () const |
uInt | incr () const |
Get or set the Block allocation increment. More... | |
uInt | incr (uInt nri) |
~OrderedMapRep () | |
Removes a map. More... | |
Public Member Functions inherited from casacore::NoticeSource | |
NoticeSource () | |
virtual | ~NoticeSource () |
void | notify (const Notice ¬e) |
Sends the note to all NoticeTarget s in the target list. More... | |
Public Member Functions inherited from casacore::MapRep< key, value > | |
MapRep (const value &dflt) | |
This is the only MapRep constructor. More... | |
value & | operator() (const key &ky) |
This is the mapping function which maps keys to values. More... | |
const value & | operator() (const key &ky) const |
value & | defaultVal () |
Returns the default value for the Map. More... | |
const value & | defaultVal () const |
virtual | ~MapRep () |
Does nothing. More... | |
Protected Member Functions | |
Int | findKey (const key &, Bool &) const |
Binary search for the key. More... | |
Protected Attributes | |
PtrBlock< OrderedPair< key, value > * > | kvblk |
The blocks to hold the keys and values and the total, used and increment size of these blocks. More... | |
uInt | nrtot |
uInt | nrused |
uInt | nrincr |
uInt | lastRef |
The index of the last key used. More... | |
Protected Attributes inherited from casacore::MapRep< key, value > | |
value | DefaultVal |
This is the default value which is return when no match is found. More... | |
Friends | |
class | OrderedMap< key, value > |
Representation class for an Ordered Map.
Definition at line 102 of file OrderedMap.h.
anonymous enum |
Enumerator | |
---|---|
OrderedMapRepVersion |
Definition at line 169 of file OrderedMap.h.
casacore::OrderedMapRep< key, value >::OrderedMapRep | ( | const value & | , |
uInt | size | ||
) |
Creates a map with the specified default value, "value", and the internal block size.
casacore::OrderedMapRep< key, value >::OrderedMapRep | ( | const value & | ) |
Creates a map with the specified default value, "value".
casacore::OrderedMapRep< key, value >::~OrderedMapRep | ( | ) |
Removes a map.
|
virtual |
|
virtual |
Implements casacore::MapRep< key, value >.
|
virtual |
|
protected |
Binary search for the key.
|
virtual |
Implements casacore::MapRep< key, value >.
|
inline |
Get or set the Block allocation increment.
Definition at line 160 of file OrderedMap.h.
References casacore::OrderedMapRep< key, value >::nrincr.
|
inline |
Definition at line 161 of file OrderedMap.h.
References casacore::OrderedMapRep< key, value >::nrincr.
|
virtual |
These functions check to see if a mapping is defined between the specified key and some value.
If one is, a pointer to the value is returned, otherwise 0 is returned.
Implements casacore::MapRep< key, value >.
|
virtual |
Returns a non-zero value if a mapping is defined for the key parameter.
Implements casacore::MapRep< key, value >.
|
virtual |
Returns the number of user defined mappings.
Implements casacore::MapRep< key, value >.
|
inline |
Definition at line 154 of file OrderedMap.h.
References casacore::OrderedMapRep< key, value >::nrtot.
|
inline |
Get the number of mappings.
Definition at line 153 of file OrderedMap.h.
References casacore::OrderedMapRep< key, value >::nrused.
|
virtual |
|
friend |
Definition at line 88 of file OrderedMap.h.
|
protected |
The blocks to hold the keys and values and the total, used and increment size of these blocks.
Definition at line 174 of file OrderedMap.h.
|
protected |
The index of the last key used.
Definition at line 180 of file OrderedMap.h.
|
protected |
Definition at line 177 of file OrderedMap.h.
Referenced by casacore::OrderedMapRep< key, value >::incr().
|
protected |
Definition at line 175 of file OrderedMap.h.
Referenced by casacore::OrderedMapRep< key, value >::ntot().
|
protected |
Definition at line 176 of file OrderedMap.h.
Referenced by casacore::OrderedMapRep< key, value >::nused().