std::list

Defined in header <list> template< class T, class Allocator = std::allocator<T> > class list; std::list is a container that supports constant time insertion and removal of elements from anywhere in the container. Fast random access is not supported. It is usually implemented as a doubly-linked list. Compared to std::forward_list this container provides bidirectional iteration capability while being less space efficient. Addition, removal and moving the e

std::equal_range

Defined in header <algorithm> template< class ForwardIt, class T > std::pair<ForwardIt,ForwardIt> equal_range( ForwardIt first, ForwardIt last, const T& value ); (1) template< class ForwardIt, class T, class Compare > std::pair<ForwardIt,ForwardIt> equal_range( ForwardIt first, ForwardIt last, const T& value, Compare comp ); (2) Returns a range containing all elements equivalent to value in th

std::strtof

Defined in header <cstdlib> float strtof( const char* str, char** str_end ); (since C++11) double strtod( const char* str, char** str_end ); long double strtold( const char* str, char** str_end ); (since C++11) Interprets a floating point value in a byte string pointed to by str. Function discards any whitespace characters (as determined by std::isspace()) until first non-whitespace character is found. Then it takes as many characters as possible to f

Fundamental types

(See also type for type system overview and the list of type-related utilities that are provided by the C++ library). Void type void - type with an empty set of values. It is an incomplete type that cannot be completed (consequently, objects of type void are disallowed). There are no arrays of void, nor references to void. However, pointers to void and functions returning type void (procedures in other languages) are permitted. std::nullptr_t Boolean type bool - type, capable of

std::basic_ios::set_rdbuf

protected: void set_rdbuf( std::basic_streambuf<CharT,Traits>* sb ); Sets the associated stream buffer to sb without clearing the error state. This member function is protected: it is called by the move constructors of the derived streams such as std::basic_ofstream or std::basic_istringstream, as the final step after constructing the base class and after moving the stream buffer: only the most derived stream class knows how to correctly move the stream buffer, but std::basic_ios

std::future::wait_until

template< class Clock, class Duration > std::future_status wait_until( const std::chrono::time_point<Clock,Duration>& timeout_time ) const; (since C++11) wait_until waits for a result to become available. It blocks until specified timeout_time has been reached or the result becomes available, whichever comes first. The return value indicates why wait_until returned. The behavior is undefined if valid()== false before the call to this function. Parameters timeout_time

std::hash

template<class T, class Deleter> struct hash<unique_ptr<T, Deleter>>; (since C++11) The template specialization of std::hash for std::unique_ptr<T, Deleter> allows users to obtain hashes of objects of type std::unique_ptr<T, Deleter>. For a given std::unique_ptr<T, Deleter> p, this specialization ensures that std::hash<std::unique_ptr<T, Deleter>>()(p) == std::hash<T*>()(p.get()). Example #include <iostream> #include <m

std::swap(std::shared_lock)

template< class Mutex > void swap( shared_lock<Mutex>& lhs, shared_lock<Mutex>& rhs ); (since C++14) Specializes the std::swap algorithm for std::shared_lock. Exchanges the state of lhs with that of rhs. Effectively calls lhs.swap(rhs). Parameters lhs, rhs - lock wrappers whose states to swap Return value (none). Exceptions noexcept specification: noexcept Example See also swap swaps the data members with another shared_

Class declaration

Classes and structs are user-defined types, defined by class-specifier, which appears in decl-specifier-seq of the declaration syntax. The class specifier has the following syntax: class-key attr class-head-name base-clause { member-specification } class-key - one of class or struct. The keywords are identical except for the default member access and the default base class access. attr(C++11) - optional sequence of any number of attributes, may include alignas specifier c

std::chrono::duration_values::max

static constexpr Rep max(); Returns the largest possible representation. Parameters (none). Return value returns std::numeric_limits<Rep>::max(). See also max [static] returns the special duration value max (public static member function of std::chrono::duration) zero [static] returns a zero-length representation (public static member function) min [static] returns the smallest possible representation (public static member function)