Skip site navigation (1)Skip section navigation (2)

FreeBSD Manual Pages

  
 
  

home | help
std::map::at(3)		      C++ Standard Libary	       std::map::at(3)

NAME
       std::map::at - std::map::at

Synopsis
	  T& at( const Key& key	);	       (1)
	  const	T& at( const Key& key )	const; (2)

	  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.

Parameters
	  key -	the key	of the element to find

Return value
	  Reference to the mapped value	of the requested element

Exceptions
	  std::out_of_range if the container does not have an element with the
       specified key

Complexity
	  Logarithmic in the size of the container.

	 Defect	reports

	  The following	behavior-changing defect reports were applied retroac-
       tively to
	  previously published C++ standards.

	    DR	  Applied to	     Behavior as published	   Correct be-
       havior
	  LWG 464 C++98	     map did not have this member function added

See also
	  operator[] access or insert specified	element
		     (public member function)

http://cppreference.com		  2022.07.31		       std::map::at(3)

Want to link to this manual page? Use this URL:
<https://man.freebsd.org/cgi/man.cgi?query=std::map::at&sektion=3&manpath=FreeBSD+Ports+15.0>

home | help