T& at( const Key& key );
const T& at( const Key& key ) const;
Returns a reference to the mapped value of the element with key equivalent to
key. If no such element exists, an exception of type
std::out_of_range is thrown.
|key||-||the key of the element to find|
Reference to the mapped value of the requested element.
std::out_of_range if the container does not have an element with the specified
Logarithmic in the size of the container.
The following behavior-changing defect reports were applied retroactively to previously published C++ standards.
|DR||Applied to||Behavior as published||Correct behavior|
|LWG 464||C++98|| ||added|
|LWG 703||C++98||the complexity requirement was missing||added|
| access or insert specified element
(public member function)
Licensed under the Creative Commons Attribution-ShareAlike Unported License v3.0.