Extension of the STL map.
More...
#include </tmp/marcocle/lhcb-release/1122/GAUDI/GAUDI_v27r0/InstallArea/x86_64-slc6-gcc49-opt/include/GaudiKernel/Map.h>
Inherits Gaudi::Utils::MapBase, and Gaudi::Utils::MapBase.
Inherited by GaudiUtils::HashMap< K, T, H, M >, GaudiUtils::HashMap< K, T, H, M >, GaudiUtils::HashMap< const void *, EntryType >, GaudiUtils::HashMap< const void *, EntryType >, GaudiUtils::HashMap< Gaudi::StringKey, Leaf >, GaudiUtils::HashMap< Gaudi::StringKey, Leaf >, GaudiUtils::HashMap< Gaudi::StringKey, Node >, GaudiUtils::HashMap< Gaudi::StringKey, Node >, GaudiUtils::HashMap< Gaudi::StringKey, std::unique_ptr< ListenerList > >, GaudiUtils::HashMap< Gaudi::StringKey, std::unique_ptr< ListenerList > >, GaudiUtils::HashMap< long, void * >, GaudiUtils::HashMap< long, void * >, GaudiUtils::HashMap< std::string, Gaudi::Utils::TypeNameString >, GaudiUtils::HashMap< std::string, Gaudi::Utils::TypeNameString >, GaudiUtils::HashMap< std::string, IFileAccess * >, GaudiUtils::HashMap< std::string, IFileAccess * >, GaudiUtils::HashMap< std::string, int >, GaudiUtils::HashMap< std::string, int >, GaudiUtils::HashMap< std::string, NameMap >, GaudiUtils::HashMap< std::string, NameMap >, GaudiUtils::HashMap< std::string, SmartIF< IAlgorithm > >, GaudiUtils::HashMap< std::string, SmartIF< IAlgorithm > >, GaudiUtils::HashMap< std::string, std::string >, GaudiUtils::HashMap< std::string, std::string >, GaudiUtils::HashMap< std::string, std::unique_ptr< Address > >, GaudiUtils::HashMap< std::string, std::unique_ptr< Address > >, GaudiUtils::HashMap< std::string, std::unique_ptr< Bool > >, GaudiUtils::HashMap< std::string, std::unique_ptr< Bool > >, GaudiUtils::HashMap< std::string, std::unique_ptr< Char > >, GaudiUtils::HashMap< std::string, std::unique_ptr< Char > >, GaudiUtils::HashMap< std::string, std::unique_ptr< Double > >, GaudiUtils::HashMap< std::string, std::unique_ptr< Double > >, GaudiUtils::HashMap< std::string, std::unique_ptr< FArray > >, GaudiUtils::HashMap< std::string, std::unique_ptr< FArray > >, GaudiUtils::HashMap< std::string, std::unique_ptr< Float > >, GaudiUtils::HashMap< std::string, std::unique_ptr< Float > >, GaudiUtils::HashMap< std::string, std::unique_ptr< FMatrix > >, GaudiUtils::HashMap< std::string, std::unique_ptr< FMatrix > >, GaudiUtils::HashMap< std::string, std::unique_ptr< Int > >, GaudiUtils::HashMap< std::string, std::unique_ptr< Int > >, GaudiUtils::HashMap< std::string, std::unique_ptr< LongLong > >, GaudiUtils::HashMap< std::string, std::unique_ptr< LongLong > >, GaudiUtils::HashMap< std::string, std::unique_ptr< NTuple::Item< VALUE > > >, GaudiUtils::HashMap< std::string, std::unique_ptr< NTuple::Item< VALUE > > >, GaudiUtils::HashMap< std::string, std::unique_ptr< Short > >, GaudiUtils::HashMap< std::string, std::unique_ptr< Short > >, GaudiUtils::HashMap< std::string, std::unique_ptr< UChar > >, GaudiUtils::HashMap< std::string, std::unique_ptr< UChar > >, GaudiUtils::HashMap< std::string, std::unique_ptr< UInt > >, GaudiUtils::HashMap< std::string, std::unique_ptr< UInt > >, GaudiUtils::HashMap< std::string, std::unique_ptr< ULongLong > >, GaudiUtils::HashMap< std::string, std::unique_ptr< ULongLong > >, GaudiUtils::HashMap< std::string, std::unique_ptr< UShort > >, and GaudiUtils::HashMap< std::string, std::unique_ptr< UShort > >.
|
| Map ()=default |
| Standard constructor. More...
|
|
| Map (const map_type &other) |
| Constructor from a standard map. More...
|
|
template<typename In > |
| Map (In &&first, In &&last) |
| Construct from a subset. More...
|
|
virtual | ~Map ()=default |
| Virtual destructor. You can inherit from this map type. More...
|
|
iterator | begin () |
|
iterator | end () |
|
const_iterator | begin () const |
|
const_iterator | end () const |
|
mapped_type & | operator[] (const key_type &key) |
|
iterator | find (const key_type &key) |
|
const_iterator | find (const key_type &key) const |
|
size_type | count (const key_type &key) const |
|
iterator | lower_bound (const key_type &key) |
|
const_iterator | lower_bound (const key_type &key) const |
|
iterator | upper_bound (const key_type &key) |
|
const_iterator | upper_bound (const key_type &key) const |
|
std::pair< iterator, iterator > | equal_range (const key_type &key) |
|
std::pair< const_iterator, const_iterator > | equal_range (const key_type &key) const |
|
template<class... Args> |
std::pair< iterator, bool > | emplace (Args &&...args) |
|
template<typename ValueType > |
std::pair< iterator, bool > | insert (ValueType &&val) |
|
std::pair< iterator, bool > | insert (value_type &&val) |
|
template<typename In > |
void | insert (In &&first, In &&last) |
|
template<typename ValueType > |
iterator | insert (iterator, ValueType &&val) |
|
iterator | erase (const_iterator pos) |
|
size_type | erase (const key_type &key) |
|
iterator | erase (const_iterator first, const_iterator last) |
|
void | clear () |
|
size_type | size () const |
|
size_type | max_size () const |
|
bool | empty () const |
|
void | swap (map_type &other) |
|
const result_type & | operator() (const argument_type &key) const |
| Allow to use Map as an unary function. More...
|
|
const mapped_type & | operator[] (const key_type &key) const |
| Access elements of a const Map. More...
|
|
const result_type & | at (const argument_type &key) const |
| checked access to the map - Exceptions
-
std::out_of_range | for missing keys |
More...
|
|
Map & | merge (const map_type &other) |
| Merge two maps. More...
|
|
Map & | merge (const Map &other) |
| Merge two maps. More...
|
|
template<class K1 , class K2 , class K3 > |
Map & | merge (const Map< K1, K2, K3 > &other) |
| Merge two maps. More...
|
|
void | update (const key_type &key, const mapped_type &mapped) |
|
| operator map_type & () |
| Allows to use the Map wherever an std::map is explicitly requested. More...
|
|
| operator const map_type & () const |
|
const key_type & | key_at (const size_type index) const |
| useful method for python decoration: More...
|
|
const mapped_type & | value_at (const size_type index) const |
| useful method for python decoration: More...
|
|
| Map ()=default |
| Standard constructor. More...
|
|
| Map (const map_type &other) |
| Constructor from a standard map. More...
|
|
template<typename In > |
| Map (In &&first, In &&last) |
| Construct from a subset. More...
|
|
virtual | ~Map ()=default |
| Virtual destructor. You can inherit from this map type. More...
|
|
iterator | begin () |
|
iterator | end () |
|
const_iterator | begin () const |
|
const_iterator | end () const |
|
mapped_type & | operator[] (const key_type &key) |
|
iterator | find (const key_type &key) |
|
const_iterator | find (const key_type &key) const |
|
size_type | count (const key_type &key) const |
|
iterator | lower_bound (const key_type &key) |
|
const_iterator | lower_bound (const key_type &key) const |
|
iterator | upper_bound (const key_type &key) |
|
const_iterator | upper_bound (const key_type &key) const |
|
std::pair< iterator, iterator > | equal_range (const key_type &key) |
|
std::pair< const_iterator, const_iterator > | equal_range (const key_type &key) const |
|
template<class... Args> |
std::pair< iterator, bool > | emplace (Args &&...args) |
|
template<typename ValueType > |
std::pair< iterator, bool > | insert (ValueType &&val) |
|
std::pair< iterator, bool > | insert (value_type &&val) |
|
template<typename In > |
void | insert (In &&first, In &&last) |
|
template<typename ValueType > |
iterator | insert (iterator, ValueType &&val) |
|
iterator | erase (const_iterator pos) |
|
size_type | erase (const key_type &key) |
|
iterator | erase (const_iterator first, const_iterator last) |
|
void | clear () |
|
size_type | size () const |
|
size_type | max_size () const |
|
bool | empty () const |
|
void | swap (map_type &other) |
|
const result_type & | operator() (const argument_type &key) const |
| Allow to use Map as an unary function. More...
|
|
const mapped_type & | operator[] (const key_type &key) const |
| Access elements of a const Map. More...
|
|
const result_type & | at (const argument_type &key) const |
| checked access to the map - Exceptions
-
std::out_of_range | for missing keys |
More...
|
|
Map & | merge (const map_type &other) |
| Merge two maps. More...
|
|
Map & | merge (const Map &other) |
| Merge two maps. More...
|
|
template<class K1 , class K2 , class K3 > |
Map & | merge (const Map< K1, K2, K3 > &other) |
| Merge two maps. More...
|
|
void | update (const key_type &key, const mapped_type &mapped) |
|
| operator map_type & () |
| Allows to use the Map wherever an std::map is explicitly requested. More...
|
|
| operator const map_type & () const |
|
const key_type & | key_at (const size_type index) const |
| useful method for python decoration: More...
|
|
const mapped_type & | value_at (const size_type index) const |
| useful method for python decoration: More...
|
|
virtual | ~MapBase () |
| virtual destructor More...
|
|
virtual | ~MapBase () |
| virtual destructor More...
|
|
template<typename K, typename T, typename M = std::map<K,T>>
class GaudiUtils::Map< K, T, M >
Extension of the STL map.
Provides const accessors and can be extended by inheritance.
- See also
- std::map Note: in order to make it possible to use either a map or a hash_map, reverse iterators are not defined.
Due to helper base class Gaudi::Utils::MapBase, this class is "python-friendly", and one can perform all python manipulaitons in intuitive way:
>>>
m = ... ##
get the
map
...
>>> for key in m : print key, m[key] ## iteration over the map
...
>>> for key,value in m.iteritems() : print key, value
...
>>> keys = m.keys() ## get the list of keys
>>> values = m.values () ## get the list of values
>> items = m.items () ## get the list of items
>>> if 'one' in m ## check the presence of the key in map
>>> v = m.get(key', None) ##
return m[key]
for existing key,
else None
...
- Attention
- The syntax can be drastically simplified, if one redefines the setitem attribute:
>>>
m[key] =
value ## much more intuitive semantics
for key insertion
In a similar way __getitem__
and __delitem__
methods can be redefined.
- Attention
- To avoid the unnesessary expansion of dictionaries it is recommended to exclude from dictionary the following methods:
- lower_bound
- upper_bound
- equal_range
- insert
- Warning
- This action is required for
HashMap
to avodi the compilation problems
- See also
- Gaudi::Utils::MapBase
- Author
- Marco Clemencic
- Date
- 2005-10-06
Definition at line 82 of file Map.h.
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 92 of file Map.h.
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 92 of file Map.h.
template<typename K, typename T, typename M = std::map<K,T>>
template<typename K, typename T, typename M = std::map<K,T>>
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 95 of file Map.h.
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 95 of file Map.h.
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 99 of file Map.h.
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 99 of file Map.h.
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 88 of file Map.h.
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 88 of file Map.h.
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 87 of file Map.h.
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 87 of file Map.h.
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 89 of file Map.h.
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 89 of file Map.h.
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 93 of file Map.h.
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 93 of file Map.h.
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 97 of file Map.h.
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 97 of file Map.h.
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 94 of file Map.h.
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 94 of file Map.h.
template<typename K, typename T, typename M = std::map<K,T>>
template<typename K, typename T, typename M = std::map<K,T>>
Constructor from a standard map.
Definition at line 116 of file Map.h.
template<typename K, typename T, typename M = std::map<K,T>>
template<typename In >
Construct from a subset.
Definition at line 122 of file Map.h.
122 :
m_map(std::forward<In>(first),std::forward<In>(last)) {}
template<typename K, typename T, typename M = std::map<K,T>>
Virtual destructor. You can inherit from this map type.
template<typename K, typename T, typename M = std::map<K,T>>
template<typename K, typename T, typename M = std::map<K,T>>
Constructor from a standard map.
Definition at line 116 of file Map.h.
template<typename K, typename T, typename M = std::map<K,T>>
template<typename In >
Construct from a subset.
Definition at line 122 of file Map.h.
122 :
m_map(std::forward<In>(first),std::forward<In>(last)) {}
template<typename K, typename T, typename M = std::map<K,T>>
Virtual destructor. You can inherit from this map type.
template<typename K, typename T, typename M = std::map<K,T>>
checked access to the map
- Exceptions
-
std::out_of_range | for missing keys |
- Parameters
-
- Returns
- the value for the existing key
Definition at line 249 of file Map.h.
251 return m_map.at(key);
template<typename K, typename T, typename M = std::map<K,T>>
checked access to the map
- Exceptions
-
std::out_of_range | for missing keys |
- Parameters
-
- Returns
- the value for the existing key
Definition at line 249 of file Map.h.
251 return m_map.at(key);
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 131 of file Map.h.
131 {
return m_map.begin(); }
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 131 of file Map.h.
131 {
return m_map.begin(); }
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 134 of file Map.h.
134 {
return m_map.begin(); }
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 134 of file Map.h.
134 {
return m_map.begin(); }
template<typename K, typename T, typename M = std::map<K,T>>
template<typename K, typename T, typename M = std::map<K,T>>
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 152 of file Map.h.
152 {
return m_map.count(key); }
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 152 of file Map.h.
152 {
return m_map.count(key); }
template<typename K, typename T, typename M = std::map<K,T>>
template<class... Args>
Definition at line 166 of file Map.h.
166 {
return m_map.emplace(std::forward<Args>(
args)...); }
template<typename K, typename T, typename M = std::map<K,T>>
template<class... Args>
Definition at line 166 of file Map.h.
166 {
return m_map.emplace(std::forward<Args>(
args)...); }
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 184 of file Map.h.
184 {
return size() == 0; }
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 184 of file Map.h.
184 {
return size() == 0; }
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 132 of file Map.h.
132 {
return m_map.end(); }
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 132 of file Map.h.
132 {
return m_map.end(); }
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 135 of file Map.h.
135 {
return m_map.end(); }
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 135 of file Map.h.
135 {
return m_map.end(); }
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 159 of file Map.h.
160 {
return m_map.equal_range(key); }
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 159 of file Map.h.
160 {
return m_map.equal_range(key); }
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 161 of file Map.h.
162 {
return m_map.equal_range(key); }
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 161 of file Map.h.
162 {
return m_map.equal_range(key); }
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 175 of file Map.h.
175 {
return m_map.erase(pos); }
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 175 of file Map.h.
175 {
return m_map.erase(pos); }
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 176 of file Map.h.
176 {
return m_map.erase(key); }
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 176 of file Map.h.
176 {
return m_map.erase(key); }
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 177 of file Map.h.
177 {
return m_map.erase(first,last); }
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 177 of file Map.h.
177 {
return m_map.erase(first,last); }
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 149 of file Map.h.
149 {
return m_map.find(key); }
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 149 of file Map.h.
149 {
return m_map.find(key); }
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 150 of file Map.h.
150 {
return m_map.find(key); }
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 150 of file Map.h.
150 {
return m_map.find(key); }
template<typename K, typename T, typename M = std::map<K,T>>
template<typename ValueType >
Definition at line 168 of file Map.h.
168 {
return m_map.insert(std::forward<ValueType>(val)); }
template<typename K, typename T, typename M = std::map<K,T>>
template<typename ValueType >
Definition at line 168 of file Map.h.
168 {
return m_map.insert(std::forward<ValueType>(val)); }
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 169 of file Map.h.
169 {
return m_map.insert(std::forward<value_type>(val)); }
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 169 of file Map.h.
169 {
return m_map.insert(std::forward<value_type>(val)); }
template<typename K, typename T, typename M = std::map<K,T>>
template<typename In >
Definition at line 171 of file Map.h.
171 {
m_map.insert(std::forward<In>(first),std::forward<In>(last)); }
template<typename K, typename T, typename M = std::map<K,T>>
template<typename In >
Definition at line 171 of file Map.h.
171 {
m_map.insert(std::forward<In>(first),std::forward<In>(last)); }
template<typename K, typename T, typename M = std::map<K,T>>
template<typename ValueType >
Definition at line 173 of file Map.h.
174 {
return m_map.insert( std::forward<ValueType>(val) ).first ; }
template<typename K, typename T, typename M = std::map<K,T>>
template<typename ValueType >
Definition at line 173 of file Map.h.
174 {
return m_map.insert( std::forward<ValueType>(val) ).first ; }
template<typename K, typename T, typename M = std::map<K,T>>
useful method for python decoration:
- Parameters
-
- Returns
- the key at given index
- Exceptions
-
std::out_of_range | for invalid index |
Definition at line 291 of file Map.h.
293 if ( index >=
size() )
295 return std::next ( this->
begin() , index )->first ;
void throw_out_of_range_exception() const
throw std::out_of_range exception
template<typename K, typename T, typename M = std::map<K,T>>
useful method for python decoration:
- Parameters
-
- Returns
- the key at given index
- Exceptions
-
std::out_of_range | for invalid index |
Definition at line 291 of file Map.h.
293 if ( index >=
size() )
295 return std::next ( this->
begin() , index )->first ;
void throw_out_of_range_exception() const
throw std::out_of_range exception
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 154 of file Map.h.
154 {
return m_map.lower_bound(key); }
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 154 of file Map.h.
154 {
return m_map.lower_bound(key); }
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 155 of file Map.h.
155 {
return m_map.lower_bound(key); }
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 155 of file Map.h.
155 {
return m_map.lower_bound(key); }
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 183 of file Map.h.
183 {
return m_map.max_size(); }
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 183 of file Map.h.
183 {
return m_map.max_size(); }
template<typename K, typename T, typename M = std::map<K,T>>
Merge two maps.
Definition at line 255 of file Map.h.
auto begin(reverse_wrapper< T > &w)
auto end(reverse_wrapper< T > &w)
template<typename K, typename T, typename M = std::map<K,T>>
Merge two maps.
Definition at line 255 of file Map.h.
auto begin(reverse_wrapper< T > &w)
auto end(reverse_wrapper< T > &w)
template<typename K, typename T, typename M = std::map<K,T>>
Merge two maps.
Definition at line 261 of file Map.h.
auto begin(reverse_wrapper< T > &w)
auto end(reverse_wrapper< T > &w)
template<typename K, typename T, typename M = std::map<K,T>>
Merge two maps.
Definition at line 261 of file Map.h.
auto begin(reverse_wrapper< T > &w)
auto end(reverse_wrapper< T > &w)
template<typename K, typename T, typename M = std::map<K,T>>
template<class K1 , class K2 , class K3 >
Merge two maps.
Definition at line 268 of file Map.h.
auto begin(reverse_wrapper< T > &w)
auto end(reverse_wrapper< T > &w)
template<typename K, typename T, typename M = std::map<K,T>>
template<class K1 , class K2 , class K3 >
Merge two maps.
Definition at line 268 of file Map.h.
auto begin(reverse_wrapper< T > &w)
auto end(reverse_wrapper< T > &w)
template<typename K, typename T, typename M = std::map<K,T>>
template<typename K, typename T, typename M = std::map<K,T>>
template<typename K, typename T, typename M = std::map<K,T>>
Allows to use the Map wherever an std::map is explicitly requested.
Definition at line 281 of file Map.h.
template<typename K, typename T, typename M = std::map<K,T>>
Allows to use the Map wherever an std::map is explicitly requested.
Definition at line 281 of file Map.h.
template<typename K, typename T, typename M = std::map<K,T>>
Allow to use Map as an unary function.
There is no automatic extension of the map for missing keys!
- Attention
- The behaviour is different from std::map
KEY key = ... ;
std::cout <<
" Value: " <<
m(key) <<
std::end ;
- Parameters
-
- Returns
- the mapped value(const reference!) for the existing key, and the default value overwise
return the default value if not present
Definition at line 211 of file Map.h.
214 auto it =
m_map.find(key);
static const result_type s_null_value
template<typename K, typename T, typename M = std::map<K,T>>
Allow to use Map as an unary function.
There is no automatic extension of the map for missing keys!
- Attention
- The behaviour is different from std::map
KEY key = ... ;
std::cout <<
" Value: " <<
m(key) <<
std::end ;
- Parameters
-
- Returns
- the mapped value(const reference!) for the existing key, and the default value overwise
return the default value if not present
Definition at line 211 of file Map.h.
214 auto it =
m_map.find(key);
static const result_type s_null_value
template<typename K, typename T, typename M = std::map<K,T>>
template<typename K, typename T, typename M = std::map<K,T>>
template<typename K, typename T, typename M = std::map<K,T>>
Access elements of a const Map.
There is no automatic extension of the map for missing keys!
- Attention
- The behaviour is different from std::map
KEY key = ... ;
std::cout <<
" Value: " << m[key] <<
std::end ;
- Parameters
-
- Returns
- the mapped value(const reference!) for the existing key, and the default value overwise
Definition at line 241 of file Map.h.
242 {
return (*
this)(key); }
template<typename K, typename T, typename M = std::map<K,T>>
Access elements of a const Map.
There is no automatic extension of the map for missing keys!
- Attention
- The behaviour is different from std::map
KEY key = ... ;
std::cout <<
" Value: " << m[key] <<
std::end ;
- Parameters
-
- Returns
- the mapped value(const reference!) for the existing key, and the default value overwise
Definition at line 241 of file Map.h.
242 {
return (*
this)(key); }
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 182 of file Map.h.
182 {
return m_map.size(); }
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 182 of file Map.h.
182 {
return m_map.size(); }
template<typename K, typename T, typename M = std::map<K,T>>
template<typename K, typename T, typename M = std::map<K,T>>
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 275 of file Map.h.
276 { (*this)[ key ] = mapped ; }
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 275 of file Map.h.
276 { (*this)[ key ] = mapped ; }
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 156 of file Map.h.
156 {
return m_map.upper_bound(key); }
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 156 of file Map.h.
156 {
return m_map.upper_bound(key); }
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 157 of file Map.h.
157 {
return m_map.upper_bound(key); }
template<typename K, typename T, typename M = std::map<K,T>>
Definition at line 157 of file Map.h.
157 {
return m_map.upper_bound(key); }
template<typename K, typename T, typename M = std::map<K,T>>
useful method for python decoration:
- Parameters
-
- Returns
- the value at given index
- Exceptions
-
std::out_of_range | for invalid index |
Definition at line 302 of file Map.h.
304 if ( index >=
size() )
306 return std::next( this->
begin() , index )->second ;
void throw_out_of_range_exception() const
throw std::out_of_range exception
template<typename K, typename T, typename M = std::map<K,T>>
useful method for python decoration:
- Parameters
-
- Returns
- the value at given index
- Exceptions
-
std::out_of_range | for invalid index |
Definition at line 302 of file Map.h.
304 if ( index >=
size() )
306 return std::next( this->
begin() , index )->second ;
void throw_out_of_range_exception() const
throw std::out_of_range exception
template<typename K, typename T, typename M = std::map<K,T>>
template<typename K, typename T, typename M = std::map<K,T>>
The documentation for this class was generated from the following file:
- InstallArea/x86_64-slc6-gcc49-opt/include/GaudiKernel/Map.h