std::pointer_to_unary_function

template< class Arg, class Result > class pointer_to_unary_function : public std::unary_function<Arg, Result>; (until C++17)(deprecated since C++11) std::pointer_to_unary_function is a function object that acts as a wrapper around a unary function. Member functions (constructor) constructs a new pointer_to_unary_function object with the supplied function (public member function) operator() calls the stored function (public member function) std::poi

std::vector::empty

bool empty() const; Checks if the container has no elements, i.e. whether begin() == end(). Parameters (none). Return value true if the container is empty, false otherwise. Exceptions (none) (until C++11) noexcept specification: noexcept (since C++11) Complexity Constant. Example The following code uses empty to check if a std::vector<int> contains any elements: #include <vector> #include <iostream> int main() { std::vector<int> numbers;

std::regex_traits::translate_nocase

CharT translate_nocase(CharT c) const; Obtains the comparison key for the character c, such that all characters that are equivalent to this character in the imbued locale, ignoring the case differences, if any, produce the same key. When the regex library needs to match two characters c1 and c2 and the flag std::regex_constants::icase is true, it executes regex_traits<>::translate_nocase(c1) == regex_traits<>::translate_nocase(c2). Standard library specializations of std::re

Namespaces

Namespaces provide a method for preventing name conflicts in large projects. Symbols declared inside a namespace block are placed in a named scope that prevents them from being mistaken for identically-named symbols in other scopes. Multiple namespace blocks with the same name are allowed. All declarations within those blocks are declared in the named scope. Syntax namespace ns_name { declarations } (1) inline namespace ns_name { declarations } (2) (since C++11) namespace { decl

enum

Usage declaration of an enumeration type

std::stack::emplace

template< class... Args > void emplace( Args&&... args ); (since C++11) Pushes new element on top of the stack. The element is constructed in-place, i.e. no copy or move operations are performed. The constructor of the element is called with exactly the same arguments as supplied to the function. Effectively calls c.emplace_back(std::forward<Args>(args)...). Parameters args - arguments to forward to the constructor of the element Return value (none).

std::condition_variable::wait

void wait( std::unique_lock<std::mutex>& lock ); (1) (since C++11) template< class Predicate > void wait( std::unique_lock<std::mutex>& lock, Predicate pred ); (2) (since C++11) wait causes the current thread to block until the condition variable is notified or a spurious wakeup occurs, optionally looping until some predicate is satisfied. 1) Atomically releases lock, blocks the current executing thread, and adds it to the list of threads waiting on *thi

std::locale::facet

Defined in header <locale> class locale::facet; std::locale::facet is the base class for facets. It provides a common base class so that locales could store pointers to the facets they implement in a single indexed container, and it abstracts support for facet reference counting. Whenever a facet is added to a locale, the locale increments the reference count in the facet (through an implementation-specific mechanism). Whenever a locale is destructed or modified, it decreme

std::basic_ofstream::is_open

bool is_open(); (until C++11) bool is_open() const; (since C++11) Checks if the file stream has an associated file. Effectively calls rdbuf()->is_open(). Parameters (none). Return value true if the file stream has an associated file, false otherwise. Example See also open opens a file and associates it with the stream (public member function) close closes the associated file (public member function)

std::basic_istream::readsome

std::streamsize readsome( char_type* s, std::streamsize count ); Extracts up to count immediately available characters from the input stream. The extracted characters are stored into the character array pointed to by s. Behaves as UnformattedInputFunction. After constructing and checking the sentry object, If rdbuf()->in_avail() == -1, calls setstate(eofbit) and extracts no characters. If rdbuf()->in_avail() == 0, extracts no characters. If rdbuf()->in_avail() > 0, extr