|
Boost-Commit : |
Subject: [Boost-commit] svn:boost r64832 - in trunk/tools/boostbook/test/more: . tests tests/libs
From: daniel_james_at_[hidden]
Date: 2010-08-15 12:49:17
Author: danieljames
Date: 2010-08-15 12:49:10 EDT (Sun, 15 Aug 2010)
New Revision: 64832
URL: http://svn.boost.org/trac/boost/changeset/64832
Log:
Start developing automated boostbook tests.
Just a shoddy python script for now. The main point of using python is
to normalize the ids generated by boostbook, which make comparisons
difficult. I'll probably switch to using whatever build tool we settle
on.
Added:
trunk/tools/boostbook/test/more/
trunk/tools/boostbook/test/more/run-tests.py (contents, props changed)
trunk/tools/boostbook/test/more/tests/
trunk/tools/boostbook/test/more/tests/libs/
trunk/tools/boostbook/test/more/tests/libs/array.gold (contents, props changed)
trunk/tools/boostbook/test/more/tests/libs/array.xml (contents, props changed)
trunk/tools/boostbook/test/more/tests/libs/hash-ref.gold (contents, props changed)
trunk/tools/boostbook/test/more/tests/libs/hash-ref.xml (contents, props changed)
trunk/tools/boostbook/test/more/tests/libs/unordered-ref.gold (contents, props changed)
trunk/tools/boostbook/test/more/tests/libs/unordered-ref.xml (contents, props changed)
Added: trunk/tools/boostbook/test/more/run-tests.py
==============================================================================
--- (empty file)
+++ trunk/tools/boostbook/test/more/run-tests.py 2010-08-15 12:49:10 EDT (Sun, 15 Aug 2010)
@@ -0,0 +1,113 @@
+#!/usr/bin/env python
+
+"""Boostbook tests
+
+Usage: python build_docs.py [--generate-gold]
+"""
+
+import difflib, getopt, os, re, sys
+import lxml.ElementInclude
+from lxml import etree
+
+# Globals
+
+def usage_and_exit():
+ print __doc__
+ sys.exit(2)
+
+def main(argv):
+ script_directory = os.path.dirname(sys.argv[0])
+ boostbook_directory = os.path.join(script_directory, "../../xsl")
+
+ try:
+ opts, args = getopt.getopt(argv, "",
+ ["generate-gold"])
+ if(len(args)): usage_and_exit()
+ except getopt.GetoptError:
+ usage_and_exit()
+
+ generate_gold = False
+
+ for opt, arg in opts:
+ if opt == '--generate-gold':
+ generate_gold = True
+
+ # Walk the test directory
+
+ parser = etree.XMLParser()
+
+ try:
+ boostbook_xsl = etree.XSLT(
+ etree.parse(os.path.join(boostbook_directory, "docbook.xsl"), parser)
+ )
+ except lxml.etree.XMLSyntaxError as error:
+ print "Error parsing boostbook xsl:"
+ print error
+ sys.exit(1)
+
+ for root, dirs, files in os.walk(os.path.join(script_directory, 'tests')):
+ for filename in files:
+ (base, ext) = os.path.splitext(filename)
+ if (ext == '.xml'):
+ src_path = os.path.join(root, filename)
+ gold_path = os.path.join(root, base + '.gold')
+ try:
+ doc_text = run_boostbook(parser, boostbook_xsl, src_path)
+ except:
+ # TODO: Need better error reporting here:
+ print "Error running boostbook for " + src_path
+ continue
+
+ if (generate_gold):
+ with open(gold_path, 'w') as file:
+ file.write(doc_text)
+ else:
+ with open(gold_path, 'r') as file:
+ gold_text = file.read()
+ compare_xml(filename, doc_text, gold_text)
+
+def run_boostbook(parser, boostbook_xsl, file):
+ doc = boostbook_xsl(etree.parse(file, parser))
+ normalize_boostbook_ids(doc)
+ return etree.tostring(doc)
+
+def normalize_boostbook_ids(doc):
+ ids = {}
+ id_bases = {}
+
+ for node in doc.xpath("//*[starts-with(@id, 'id') or contains(@id, '_id')]"):
+ id = node.get('id')
+
+ if(id in ids):
+ print 'Duplicate id: ' + id
+
+ match = re.match("(id|.+_id)(\d+)((?:-bb)?)", id)
+ if(match):
+ count = 1
+ if(match.group(1) in id_bases):
+ count = id_bases[match.group(1)] + 1
+ id_bases[match.group(1)] = count
+ ids[id] = match.group(1) + str(count) + match.group(3)
+
+ for node in doc.xpath("//*[@linkend or @id]"):
+ x = node.get('linkend')
+ if(x in ids): node.set('linkend', ids[x])
+ x = node.get('id')
+ if(x in ids): node.set('id', ids[x])
+
+def compare_xml(file, doc_text, gold_text):
+ # Had hoped to use xmldiff but it turned out to be a pain to install.
+ # So instead just do a text diff.
+
+ if (doc_text != gold_text):
+ print "Error: " + file
+ print
+ sys.stdout.writelines(
+ difflib.unified_diff(
+ gold_text.splitlines(True),
+ doc_text.splitlines(True)
+ )
+ )
+
+if __name__ == "__main__":
+ main(sys.argv[1:])
\ No newline at end of file
Added: trunk/tools/boostbook/test/more/tests/libs/array.gold
==============================================================================
--- (empty file)
+++ trunk/tools/boostbook/test/more/tests/libs/array.gold 2010-08-15 12:49:10 EDT (Sun, 15 Aug 2010)
@@ -0,0 +1,309 @@
+<!DOCTYPE chapter PUBLIC "-//OASIS//DTD DocBook XML V4.2//EN" "http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd">
+<chapter xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" id="array" rev:last-revision="$Date$">
+ <chapterinfo><author>
+ <firstname>Nicolai</firstname>
+ <surname>Josuttis</surname>
+ </author><copyright>
+ <year>2001</year>
+ <year>2002</year>
+ <year>2003</year>
+ <year>2004</year>
+ <holder>Nicolai M. Josuttis</holder>
+ </copyright><legalnotice>
+ <para>Distributed under the Boost Software License, Version 1.0.
+ (See accompanying file <filename>LICENSE_1_0.txt</filename> or copy at
+ <ulink url="http://www.boost.org/LICENSE_1_0.txt">http://www.boost.org/LICENSE_1_0.txt>)
+ </para>
+ </legalnotice></chapterinfo>
+
+ <title>Boost.Array</title>
+
+ <section id="array.intro">
+ <title>Introduction</title>
+
+
+
+
+ <para>The C++ Standard Template Library STL as part of the C++
+ Standard Library provides a framework for processing algorithms on
+ different kind of containers. However, ordinary arrays don't
+ provide the interface of STL containers (although, they provide
+ the iterator interface of STL containers).</para>
+
+ <para>As replacement for ordinary arrays, the STL provides class
+ <computeroutput xmlns:xi="http://www.w3.org/2001/XInclude">std::vector</computeroutput>. However,
+ <computeroutput xmlns:xi="http://www.w3.org/2001/XInclude">std::vector<></computeroutput> provides
+ the semantics of dynamic arrays. Thus, it manages data to be able
+ to change the number of elements. This results in some overhead in
+ case only arrays with static size are needed.</para>
+
+ <para>In his book, <emphasis>Generic Programming and the
+ STL</emphasis>, Matthew H. Austern introduces a useful wrapper
+ class for ordinary arrays with static size, called
+ <computeroutput xmlns:xi="http://www.w3.org/2001/XInclude">block</computeroutput>. It is safer and has no worse performance than
+ ordinary arrays. In <emphasis>The C++ Programming
+ Language</emphasis>, 3rd edition, Bjarne Stroustrup introduces a
+ similar class, called <computeroutput xmlns:xi="http://www.w3.org/2001/XInclude">c_array</computeroutput>, which I (<ulink url="http://www.josuttis.com">Nicolai Josuttis</ulink>) present
+ slightly modified in my book <emphasis>The C++ Standard Library -
+ A Tutorial and Reference</emphasis>, called
+ <computeroutput xmlns:xi="http://www.w3.org/2001/XInclude">carray</computeroutput>. This is the essence of these approaches
+ spiced with many feedback from <ulink url="http://www.boost.org">boost</ulink>.</para>
+
+ <para>After considering different names, we decided to name this
+ class simply <computeroutput xmlns:xi="http://www.w3.org/2001/XInclude"><link linkend="boost.array">array</link></computeroutput>.</para>
+
+ <para>Note that this class is suggested to be part of the next
+ Technical Report, which will extend the C++ Standard (see
+ <ulink url="http://std.dkuug.dk/jtc1/sc22/wg21/docs/papers/2003/n1548.htm">http://std.dkuug.dk/jtc1/sc22/wg21/docs/papers/2003/n1548.htm>).</para>
+
+ <para>Class <computeroutput xmlns:xi="http://www.w3.org/2001/XInclude"><link linkend="boost.array">array</link></computeroutput> fulfills most
+ but not all of the requirements of "reversible containers" (see
+ Section 23.1, [lib.container.requirements] of the C++
+ Standard). The reasons array is not an reversible STL container is
+ because:
+ <itemizedlist spacing="compact">
+ <listitem><simpara>No constructors are provided.</simpara></listitem>
+ <listitem><simpara>Elements may have an undetermined initial value (see <xref linkend="array.rationale"/>).</simpara></listitem>
+ <listitem><simpara><computeroutput xmlns:xi="http://www.w3.org/2001/XInclude"><link linkend="boost.array.swap">swap</link></computeroutput>() has no constant complexity.</simpara></listitem>
+ <listitem><simpara><computeroutput xmlns:xi="http://www.w3.org/2001/XInclude"><link linkend="id17-bb">size</link></computeroutput>() is always constant, based on the second template argument of the type.</simpara></listitem>
+ <listitem><simpara>The container provides no allocator support.</simpara></listitem>
+ </itemizedlist>
+ </para>
+
+ <para>It doesn't fulfill the requirements of a "sequence" (see Section 23.1.1, [lib.sequence.reqmts] of the C++ Standard), except that:
+ <itemizedlist spacing="compact">
+ <listitem><simpara><computeroutput xmlns:xi="http://www.w3.org/2001/XInclude"><link linkend="id27-bb">front</link></computeroutput>() and <computeroutput xmlns:xi="http://www.w3.org/2001/XInclude"><link linkend="id30-bb">back</link></computeroutput>() are provided.</simpara></listitem>
+ <listitem><simpara><computeroutput xmlns:xi="http://www.w3.org/2001/XInclude"><link linkend="id21-bb">operator[]</link></computeroutput> and <computeroutput xmlns:xi="http://www.w3.org/2001/XInclude"><link linkend="id24-bb">at</link></computeroutput>() are provided.</simpara></listitem>
+ </itemizedlist>
+ </para>
+ </section>
+
+ <section id="array.reference"><title>Reference</title>
+ <section id="header.boost.array_hpp"><title>Header <<ulink url="../../boost/array.hpp">boost/array.hpp</ulink>></title><synopsis xmlns:xi="http://www.w3.org/2001/XInclude"><phrase role="keyword">namespace</phrase> <phrase role="identifier">boost</phrase> <phrase role="special">{</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> T<phrase role="special">,</phrase> <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> N<phrase role="special">></phrase> <phrase role="keyword">class</phrase> <link linkend="boost.array">array</link><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> T<phrase role="special">,</phrase> <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> N<phrase role="special">></phrase> <phrase role="keyword">void</phrase> <link linkend="boost.array.swap"><phrase role="identifier">swap</phrase></link><phrase role="special">(</phrase><link linkend="boost.array">array</link><phrase role="special"><</phrase><phrase role="identifier">T</phrase><phrase role="special">,</phrase> <phrase role="identifier">N</phrase><phrase role="special">></phrase><phrase role="special">&</phrase><phrase role="special">,</phrase> <link linkend="boost.array">array</link><phrase role="special"><</phrase><phrase role="identifier">T</phrase><phrase role="special">,</phrase> <phrase role="identifier">N</phrase><phrase role="special">></phrase><phrase role="special">&</phrase><phrase role="special">
)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> T<phrase role="special">,</phrase> <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> N<phrase role="special">></phrase>
+ <phrase role="keyword">bool</phrase> <link linkend="boost.array.operator=="><phrase role="keyword">operator</phrase><phrase role="special">==</phrase></link><phrase role="special">(</phrase><phrase role="keyword">const</phrase> <link linkend="boost.array">array</link><phrase role="special"><</phrase><phrase role="identifier">T</phrase><phrase role="special">,</phrase> <phrase role="identifier">N</phrase><phrase role="special">></phrase><phrase role="special">&</phrase><phrase role="special">,</phrase> <phrase role="keyword">const</phrase> <link linkend="boost.array">array</link><phrase role="special"><</phrase><phrase role="identifier">T</phrase><phrase role="special">,</phrase> <phrase role="identifier">N</phrase><phrase role="special">></phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> T<phrase role="special">,</phrase> <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> N<phrase role="special">></phrase>
+ <phrase role="keyword">bool</phrase> <link linkend="boost.array.operator!="><phrase role="keyword">operator</phrase><phrase role="special">!=</phrase></link><phrase role="special">(</phrase><phrase role="keyword">const</phrase> <link linkend="boost.array">array</link><phrase role="special"><</phrase><phrase role="identifier">T</phrase><phrase role="special">,</phrase> <phrase role="identifier">N</phrase><phrase role="special">></phrase><phrase role="special">&</phrase><phrase role="special">,</phrase> <phrase role="keyword">const</phrase> <link linkend="boost.array">array</link><phrase role="special"><</phrase><phrase role="identifier">T</phrase><phrase role="special">,</phrase> <phrase role="identifier">N</phrase><phrase role="special">></phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> T<phrase role="special">,</phrase> <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> N<phrase role="special">></phrase>
+ <phrase role="keyword">bool</phrase> <link linkend="boost.array.operator_id1"><phrase role="keyword">operator</phrase><phrase role="special"><</phrase></link><phrase role="special">(</phrase><phrase role="keyword">const</phrase> <link linkend="boost.array">array</link><phrase role="special"><</phrase><phrase role="identifier">T</phrase><phrase role="special">,</phrase> <phrase role="identifier">N</phrase><phrase role="special">></phrase><phrase role="special">&</phrase><phrase role="special">,</phrase> <phrase role="keyword">const</phrase> <link linkend="boost.array">array</link><phrase role="special"><</phrase><phrase role="identifier">T</phrase><phrase role="special">,</phrase> <phrase role="identifier">N</phrase><phrase role="special">></phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> T<phrase role="special">,</phrase> <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> N<phrase role="special">></phrase>
+ <phrase role="keyword">bool</phrase> <link linkend="boost.array.operator_id2"><phrase role="keyword">operator</phrase><phrase role="special">></phrase></link><phrase role="special">(</phrase><phrase role="keyword">const</phrase> <link linkend="boost.array">array</link><phrase role="special"><</phrase><phrase role="identifier">T</phrase><phrase role="special">,</phrase> <phrase role="identifier">N</phrase><phrase role="special">></phrase><phrase role="special">&</phrase><phrase role="special">,</phrase> <phrase role="keyword">const</phrase> <link linkend="boost.array">array</link><phrase role="special"><</phrase><phrase role="identifier">T</phrase><phrase role="special">,</phrase> <phrase role="identifier">N</phrase><phrase role="special">></phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> T<phrase role="special">,</phrase> <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> N<phrase role="special">></phrase>
+ <phrase role="keyword">bool</phrase> <link linkend="boost.array.operator_=_id1"><phrase role="keyword">operator</phrase><phrase role="special"><=</phrase></link><phrase role="special">(</phrase><phrase role="keyword">const</phrase> <link linkend="boost.array">array</link><phrase role="special"><</phrase><phrase role="identifier">T</phrase><phrase role="special">,</phrase> <phrase role="identifier">N</phrase><phrase role="special">></phrase><phrase role="special">&</phrase><phrase role="special">,</phrase> <phrase role="keyword">const</phrase> <link linkend="boost.array">array</link><phrase role="special"><</phrase><phrase role="identifier">T</phrase><phrase role="special">,</phrase> <phrase role="identifier">N</phrase><phrase role="special">></phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> T<phrase role="special">,</phrase> <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> N<phrase role="special">></phrase>
+ <phrase role="keyword">bool</phrase> <link linkend="boost.array.operator_=_id2"><phrase role="keyword">operator</phrase><phrase role="special">>=</phrase></link><phrase role="special">(</phrase><phrase role="keyword">const</phrase> <link linkend="boost.array">array</link><phrase role="special"><</phrase><phrase role="identifier">T</phrase><phrase role="special">,</phrase> <phrase role="identifier">N</phrase><phrase role="special">></phrase><phrase role="special">&</phrase><phrase role="special">,</phrase> <phrase role="keyword">const</phrase> <link linkend="boost.array">array</link><phrase role="special"><</phrase><phrase role="identifier">T</phrase><phrase role="special">,</phrase> <phrase role="identifier">N</phrase><phrase role="special">></phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="special">}</phrase></synopsis>
+ <refentry xmlns:xi="http://www.w3.org/2001/XInclude" id="boost.array"><refmeta><refentrytitle>Class template array</refentrytitle><manvolnum>3</manvolnum></refmeta><refnamediv><refname>boost::array</refname><refpurpose>STL compliant container wrapper for arrays of constant size</refpurpose></refnamediv><refsynopsisdiv><synopsis><phrase role="comment">// In header: <<link linkend="header.boost.array_hpp">boost/array.hpp</link>>
+
+</phrase><phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> T<phrase role="special">,</phrase> <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> N<phrase role="special">></phrase>
+<phrase role="keyword">class</phrase> <link linkend="boost.array">array</link> <phrase role="special">{</phrase>
+<phrase role="keyword">public</phrase><phrase role="special">:</phrase>
+ <phrase role="comment">// types</phrase>
+ <phrase role="keyword">typedef</phrase> <phrase role="identifier">T</phrase> <anchor id="boost.array.value_type"/><phrase role="identifier">value_type</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">typedef</phrase> <phrase role="identifier">T</phrase><phrase role="special">*</phrase> <anchor id="boost.array.iterator"/><phrase role="identifier">iterator</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">typedef</phrase> <phrase role="keyword">const</phrase> <phrase role="identifier">T</phrase><phrase role="special">*</phrase> <anchor id="boost.array.const_iterator"/><phrase role="identifier">const_iterator</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">typedef</phrase> std::reverse_iterator<phrase role="special"><</phrase><phrase role="identifier">iterator</phrase><phrase role="special">></phrase> <anchor id="boost.array.reverse_iterator"/><phrase role="identifier">reverse_iterator</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">typedef</phrase> std::reverse_iterator<phrase role="special"><</phrase><phrase role="identifier">const_iterator</phrase><phrase role="special">></phrase> <anchor id="boost.array.const_reverse_iterator"/><phrase role="identifier">const_reverse_iterator</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">typedef</phrase> <phrase role="identifier">T</phrase><phrase role="special">&</phrase> <anchor id="boost.array.reference"/><phrase role="identifier">reference</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">typedef</phrase> <phrase role="keyword">const</phrase> <phrase role="identifier">T</phrase><phrase role="special">&</phrase> <anchor id="boost.array.const_reference"/><phrase role="identifier">const_reference</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">typedef</phrase> <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <anchor id="boost.array.size_type"/><phrase role="identifier">size_type</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">typedef</phrase> <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">ptrdiff_t</phrase> <anchor id="boost.array.difference_type"/><phrase role="identifier">difference_type</phrase><phrase role="special">;</phrase>
+
+ <phrase role="comment">// static constants</phrase>
+ <phrase role="keyword">static</phrase> <phrase role="keyword">const</phrase> <phrase role="identifier">size_type</phrase> <phrase role="identifier">static_size</phrase> = <phrase role="identifier">N</phrase><phrase role="special">;</phrase>
+
+ <phrase role="comment">// <link linkend="boost.arrayconstruct-copy-destruct">construct/copy/destruct</link></phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> U<phrase role="special">></phrase> array& <link linkend="id1-bb"><phrase role="keyword">operator</phrase><phrase role="special">=</phrase></link><phrase role="special">(</phrase><phrase role="keyword">const</phrase> <link linkend="boost.array">array</link><phrase role="special"><</phrase><phrase role="identifier">U</phrase><phrase role="special">,</phrase> <phrase role="identifier">N</phrase><phrase role="special">></phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+
+ <phrase role="comment">// <link linkend="id2-bb">iterator support</link></phrase>
+ <phrase role="identifier">iterator</phrase> <link linkend="id4-bb"><phrase role="identifier">begin</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">const_iterator</phrase> <link linkend="id5-bb"><phrase role="identifier">begin</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">iterator</phrase> <link linkend="id7-bb"><phrase role="identifier">end</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">const_iterator</phrase> <link linkend="id8-bb"><phrase role="identifier">end</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+
+ <phrase role="comment">// <link linkend="id9-bb">reverse iterator support</link></phrase>
+ <phrase role="identifier">reverse_iterator</phrase> <link linkend="id11-bb"><phrase role="identifier">rbegin</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">const_reverse_iterator</phrase> <link linkend="id12-bb"><phrase role="identifier">rbegin</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">reverse_iterator</phrase> <link linkend="id14-bb"><phrase role="identifier">rend</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">const_reverse_iterator</phrase> <link linkend="id15-bb"><phrase role="identifier">rend</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+
+ <phrase role="comment">// <link linkend="id16-bb">capacity</link></phrase>
+ <phrase role="identifier">size_type</phrase> <link linkend="id17-bb"><phrase role="identifier">size</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">bool</phrase> <link linkend="id18-bb"><phrase role="identifier">empty</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">size_type</phrase> <link linkend="id19-bb"><phrase role="identifier">max_size</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+
+ <phrase role="comment">// <link linkend="id20-bb">element access</link></phrase>
+ <phrase role="identifier">reference</phrase> <link linkend="id22-bb"><phrase role="keyword">operator</phrase><phrase role="special">[</phrase><phrase role="special">]</phrase></link><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">const_reference</phrase> <link linkend="id23-bb"><phrase role="keyword">operator</phrase><phrase role="special">[</phrase><phrase role="special">]</phrase></link><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">reference</phrase> <link linkend="id25-bb"><phrase role="identifier">at</phrase></link><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">const_reference</phrase> <link linkend="id26-bb"><phrase role="identifier">at</phrase></link><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">reference</phrase> <link linkend="id28-bb"><phrase role="identifier">front</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">const_reference</phrase> <link linkend="id29-bb"><phrase role="identifier">front</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">reference</phrase> <link linkend="id31-bb"><phrase role="identifier">back</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">const_reference</phrase> <link linkend="id32-bb"><phrase role="identifier">back</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">const</phrase> <phrase role="identifier">T</phrase><phrase role="special">*</phrase> <link linkend="id33-bb"><phrase role="identifier">data</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">T</phrase><phrase role="special">*</phrase> <link linkend="id34-bb"><phrase role="identifier">c_array</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+
+ <phrase role="comment">// <link linkend="id35-bb">modifiers</link></phrase>
+ <phrase role="keyword">void</phrase> <link linkend="id36-bb"><phrase role="identifier">swap</phrase></link><phrase role="special">(</phrase><link linkend="boost.array">array</link><phrase role="special"><</phrase><phrase role="identifier">T</phrase><phrase role="special">,</phrase> <phrase role="identifier">N</phrase><phrase role="special">></phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">void</phrase> <link linkend="id37-bb"><phrase role="identifier">assign</phrase></link><phrase role="special">(</phrase><phrase role="keyword">const</phrase> <phrase role="identifier">T</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">T</phrase> elems[N]<phrase role="special">;</phrase>
+<phrase role="special">}</phrase><phrase role="special">;</phrase>
+
+<phrase role="comment">// <link linkend="id38-bb">specialized algorithms</link></phrase>
+<phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> T<phrase role="special">,</phrase> <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> N<phrase role="special">></phrase> <phrase role="keyword">void</phrase> <link linkend="boost.array.swap"><phrase role="identifier">swap</phrase></link><phrase role="special">(</phrase><link linkend="boost.array">array</link><phrase role="special"><</phrase><phrase role="identifier">T</phrase><phrase role="special">,</phrase> <phrase role="identifier">N</phrase><phrase role="special">></phrase><phrase role="special">&</phrase><phrase role="special">,</phrase> <link linkend="boost.array">array</link><phrase role="special"><</phrase><phrase role="identifier">T</phrase><phrase role="special">,</phrase> <phrase role="identifier">N</phrase><phrase role="special">></phrase><phrase role="special">&</phrase><phrase role="special">)<
/phrase><phrase role="special">;</phrase>
+
+<phrase role="comment">// <link linkend="id39-bb">comparisons</link></phrase>
+<phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> T<phrase role="special">,</phrase> <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> N<phrase role="special">></phrase>
+ <phrase role="keyword">bool</phrase> <link linkend="boost.array.operator=="><phrase role="keyword">operator</phrase><phrase role="special">==</phrase></link><phrase role="special">(</phrase><phrase role="keyword">const</phrase> <link linkend="boost.array">array</link><phrase role="special"><</phrase><phrase role="identifier">T</phrase><phrase role="special">,</phrase> <phrase role="identifier">N</phrase><phrase role="special">></phrase><phrase role="special">&</phrase><phrase role="special">,</phrase> <phrase role="keyword">const</phrase> <link linkend="boost.array">array</link><phrase role="special"><</phrase><phrase role="identifier">T</phrase><phrase role="special">,</phrase> <phrase role="identifier">N</phrase><phrase role="special">></phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> T<phrase role="special">,</phrase> <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> N<phrase role="special">></phrase>
+ <phrase role="keyword">bool</phrase> <link linkend="boost.array.operator!="><phrase role="keyword">operator</phrase><phrase role="special">!=</phrase></link><phrase role="special">(</phrase><phrase role="keyword">const</phrase> <link linkend="boost.array">array</link><phrase role="special"><</phrase><phrase role="identifier">T</phrase><phrase role="special">,</phrase> <phrase role="identifier">N</phrase><phrase role="special">></phrase><phrase role="special">&</phrase><phrase role="special">,</phrase> <phrase role="keyword">const</phrase> <link linkend="boost.array">array</link><phrase role="special"><</phrase><phrase role="identifier">T</phrase><phrase role="special">,</phrase> <phrase role="identifier">N</phrase><phrase role="special">></phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> T<phrase role="special">,</phrase> <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> N<phrase role="special">></phrase>
+ <phrase role="keyword">bool</phrase> <link linkend="boost.array.operator_id1"><phrase role="keyword">operator</phrase><phrase role="special"><</phrase></link><phrase role="special">(</phrase><phrase role="keyword">const</phrase> <link linkend="boost.array">array</link><phrase role="special"><</phrase><phrase role="identifier">T</phrase><phrase role="special">,</phrase> <phrase role="identifier">N</phrase><phrase role="special">></phrase><phrase role="special">&</phrase><phrase role="special">,</phrase> <phrase role="keyword">const</phrase> <link linkend="boost.array">array</link><phrase role="special"><</phrase><phrase role="identifier">T</phrase><phrase role="special">,</phrase> <phrase role="identifier">N</phrase><phrase role="special">></phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> T<phrase role="special">,</phrase> <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> N<phrase role="special">></phrase>
+ <phrase role="keyword">bool</phrase> <link linkend="boost.array.operator_id2"><phrase role="keyword">operator</phrase><phrase role="special">></phrase></link><phrase role="special">(</phrase><phrase role="keyword">const</phrase> <link linkend="boost.array">array</link><phrase role="special"><</phrase><phrase role="identifier">T</phrase><phrase role="special">,</phrase> <phrase role="identifier">N</phrase><phrase role="special">></phrase><phrase role="special">&</phrase><phrase role="special">,</phrase> <phrase role="keyword">const</phrase> <link linkend="boost.array">array</link><phrase role="special"><</phrase><phrase role="identifier">T</phrase><phrase role="special">,</phrase> <phrase role="identifier">N</phrase><phrase role="special">></phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> T<phrase role="special">,</phrase> <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> N<phrase role="special">></phrase>
+ <phrase role="keyword">bool</phrase> <link linkend="boost.array.operator_=_id1"><phrase role="keyword">operator</phrase><phrase role="special"><=</phrase></link><phrase role="special">(</phrase><phrase role="keyword">const</phrase> <link linkend="boost.array">array</link><phrase role="special"><</phrase><phrase role="identifier">T</phrase><phrase role="special">,</phrase> <phrase role="identifier">N</phrase><phrase role="special">></phrase><phrase role="special">&</phrase><phrase role="special">,</phrase> <phrase role="keyword">const</phrase> <link linkend="boost.array">array</link><phrase role="special"><</phrase><phrase role="identifier">T</phrase><phrase role="special">,</phrase> <phrase role="identifier">N</phrase><phrase role="special">></phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> T<phrase role="special">,</phrase> <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> N<phrase role="special">></phrase>
+ <phrase role="keyword">bool</phrase> <link linkend="boost.array.operator_=_id2"><phrase role="keyword">operator</phrase><phrase role="special">>=</phrase></link><phrase role="special">(</phrase><phrase role="keyword">const</phrase> <link linkend="boost.array">array</link><phrase role="special"><</phrase><phrase role="identifier">T</phrase><phrase role="special">,</phrase> <phrase role="identifier">N</phrase><phrase role="special">></phrase><phrase role="special">&</phrase><phrase role="special">,</phrase> <phrase role="keyword">const</phrase> <link linkend="boost.array">array</link><phrase role="special"><</phrase><phrase role="identifier">T</phrase><phrase role="special">,</phrase> <phrase role="identifier">N</phrase><phrase role="special">></phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase></synopsis></refsynopsisdiv><refsect1><title>Description</title><refsect2><title><anchor id="boost.arrayconstruct-copy-destruct"/><comput
eroutput>array</computeroutput>
+ public
+ construct/copy/destruct</title><orderedlist><listitem><para><literallayout class="monospaced"><phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> U<phrase role="special">></phrase> array& <anchor id="id1-bb"/><phrase role="keyword">operator</phrase><phrase role="special">=</phrase><phrase role="special">(</phrase><phrase role="keyword">const</phrase> <link linkend="boost.array">array</link><phrase role="special"><</phrase><phrase role="identifier">U</phrase><phrase role="special">,</phrase> <phrase role="identifier">N</phrase><phrase role="special">></phrase><phrase role="special">&</phrase> other<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Effects:</term><listitem><simpara><computeroutput>std::copy(rhs.<link linkend="id3-bb">begin</link>(),rhs.<link linkend="id6-bb">end</link>(), <link linkend="id3-bb">begin</link>())</computeroutput></simpara></listitem></varlistentry></variablelist></listitem></orderedlist></refsect2><refsect2><title><anchor id="id2-bb"/><computeroutput>array</computeroutput> iterator support</title><orderedlist><listitem><para><literallayout class="monospaced"><anchor id="id3-bb"/><phrase role="identifier">iterator</phrase> <anchor id="id4-bb"/><phrase role="identifier">begin</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="identifier">const_iterator</phrase> <anchor id="id5-bb"/><phrase role="identifier">begin</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><simpara>iterator for the first element</simpara></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><simpara>will not throw</simpara></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><anchor id="id6-bb"/><phrase role="identifier">iterator</phrase> <anchor id="id7-bb"/><phrase role="identifier">end</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="identifier">const_iterator</phrase> <anchor id="id8-bb"/><phrase role="identifier">end</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><simpara>iterator for position after the last element</simpara></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><simpara>will not throw</simpara></listitem></varlistentry></variablelist></listitem></orderedlist></refsect2><refsect2><title><anchor id="id9-bb"/><computeroutput>array</computeroutput> reverse iterator support</title><orderedlist><listitem><para><literallayout class="monospaced"><anchor id="id10-bb"/><phrase role="identifier">reverse_iterator</phrase> <anchor id="id11-bb"/><phrase role="identifier">rbegin</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="identifier">const_reverse_iterator</phrase> <anchor id="id12-bb"/><phrase role="identifier">rbegin</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><simpara>reverse iterator for the first element of reverse iteration</simpara></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><anchor id="id13-bb"/><phrase role="identifier">reverse_iterator</phrase> <anchor id="id14-bb"/><phrase role="identifier">rend</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="identifier">const_reverse_iterator</phrase> <anchor id="id15-bb"/><phrase role="identifier">rend</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><simpara>reverse iterator for position after the last element in reverse iteration</simpara></listitem></varlistentry></variablelist></listitem></orderedlist></refsect2><refsect2><title><anchor id="id16-bb"/><computeroutput>array</computeroutput> capacity</title><orderedlist><listitem><para><literallayout class="monospaced"><phrase role="identifier">size_type</phrase> <anchor id="id17-bb"/><phrase role="identifier">size</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><simpara><computeroutput>N</computeroutput></simpara></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="keyword">bool</phrase> <anchor id="id18-bb"/><phrase role="identifier">empty</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><simpara><computeroutput>N==0</computeroutput></simpara></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><simpara>will not throw</simpara></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">size_type</phrase> <anchor id="id19-bb"/><phrase role="identifier">max_size</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><simpara><computeroutput>N</computeroutput></simpara></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><simpara>will not throw</simpara></listitem></varlistentry></variablelist></listitem></orderedlist></refsect2><refsect2><title><anchor id="id20-bb"/><computeroutput>array</computeroutput> element access</title><orderedlist><listitem><para><literallayout class="monospaced"><anchor id="id21-bb"/><phrase role="identifier">reference</phrase> <anchor id="id22-bb"/><phrase role="keyword">operator</phrase><phrase role="special">[</phrase><phrase role="special">]</phrase><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase> i<phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="identifier">const_reference</phrase> <anchor id="id23-bb"/><phrase role="keyword">operator</phrase><phrase role="special">[</phrase><phrase role="special">]</phrase><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase> i<phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Requires:</term><listitem><simpara><computeroutput>i < N</computeroutput></simpara></listitem></varlistentry><varlistentry><term>Returns:</term><listitem><simpara>element with index <computeroutput>i</computeroutput></simpara></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><simpara>will not throw.</simpara></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><anchor id="id24-bb"/><phrase role="identifier">reference</phrase> <anchor id="id25-bb"/><phrase role="identifier">at</phrase><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase> i<phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="identifier">const_reference</phrase> <anchor id="id26-bb"/><phrase role="identifier">at</phrase><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase> i<phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><simpara>element with index <computeroutput>i</computeroutput></simpara></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><simpara><computeroutput>std::range_error</computeroutput> if <computeroutput>i >= N</computeroutput></simpara></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><anchor id="id27-bb"/><phrase role="identifier">reference</phrase> <anchor id="id28-bb"/><phrase role="identifier">front</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="identifier">const_reference</phrase> <anchor id="id29-bb"/><phrase role="identifier">front</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Requires:</term><listitem><simpara><computeroutput>N > 0</computeroutput></simpara></listitem></varlistentry><varlistentry><term>Returns:</term><listitem><simpara>the first element</simpara></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><simpara>will not throw</simpara></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><anchor id="id30-bb"/><phrase role="identifier">reference</phrase> <anchor id="id31-bb"/><phrase role="identifier">back</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="identifier">const_reference</phrase> <anchor id="id32-bb"/><phrase role="identifier">back</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Requires:</term><listitem><simpara><computeroutput>N > 0</computeroutput></simpara></listitem></varlistentry><varlistentry><term>Returns:</term><listitem><simpara>the last element</simpara></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><simpara>will not throw</simpara></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="keyword">const</phrase> <phrase role="identifier">T</phrase><phrase role="special">*</phrase> <anchor id="id33-bb"/><phrase role="identifier">data</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><simpara><computeroutput>elems</computeroutput></simpara></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><simpara>will not throw</simpara></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">T</phrase><phrase role="special">*</phrase> <anchor id="id34-bb"/><phrase role="identifier">c_array</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><simpara><computeroutput>elems</computeroutput></simpara></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><simpara>will not throw</simpara></listitem></varlistentry></variablelist></listitem></orderedlist></refsect2><refsect2><title><anchor id="id35-bb"/><computeroutput>array</computeroutput> modifiers</title><orderedlist><listitem><para><literallayout class="monospaced"><phrase role="keyword">void</phrase> <anchor id="id36-bb"/><phrase role="identifier">swap</phrase><phrase role="special">(</phrase><link linkend="boost.array">array</link><phrase role="special"><</phrase><phrase role="identifier">T</phrase><phrase role="special">,</phrase> <phrase role="identifier">N</phrase><phrase role="special">></phrase><phrase role="special">&</phrase> other<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Effects:</term><listitem><simpara><computeroutput>std::swap_ranges(<link linkend="id3-bb">begin</link>(), <link linkend="id6-bb">end</link>(), other.<link linkend="id3-bb">begin</link>())</computeroutput></simpara></listitem></varlistentry><varlistentry><term>Complexity:</term><listitem><simpara>linear in <computeroutput>N</computeroutput></simpara></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="keyword">void</phrase> <anchor id="id37-bb"/><phrase role="identifier">assign</phrase><phrase role="special">(</phrase><phrase role="keyword">const</phrase> <phrase role="identifier">T</phrase><phrase role="special">&</phrase> value<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Effects:</term><listitem><simpara><computeroutput>std::fill_n(<link linkend="id3-bb">begin</link>(), N, value)</computeroutput></simpara></listitem></varlistentry></variablelist></listitem></orderedlist></refsect2><refsect2><title><anchor id="id38-bb"/><computeroutput>array</computeroutput> specialized algorithms</title><orderedlist><listitem><para><literallayout class="monospaced"><phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> T<phrase role="special">,</phrase> <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> N<phrase role="special">></phrase> <phrase role="keyword">void</phrase> <anchor id="boost.array.swap"/><phrase role="identifier">swap</phrase><phrase role="special">(</phrase><link linkend="boost.array">array</link><phrase role="special"><</phrase><phrase role="identifier">T</phrase><phrase role="special">,</phrase> <phrase role="ide
ntifier">N</phrase><phrase role="special">></phrase><phrase role="special">&</phrase> x<phrase role="special">,</phrase> <link linkend="boost.array">array</link><phrase role="special"><</phrase><phrase role="identifier">T</phrase><phrase role="special">,</phrase> <phrase role="identifier">N</phrase><phrase role="special">></phrase><phrase role="special">&</phrase> y<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Effects:</term><listitem><simpara><computeroutput>x.<link linkend="id36-bb">swap</link>(y)</computeroutput></simpara></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><simpara>will not throw.</simpara></listitem></varlistentry></variablelist></listitem></orderedlist></refsect2><refsect2><title><anchor id="id39-bb"/><computeroutput>array</computeroutput> comparisons</title><orderedlist><listitem><para><literallayout class="monospaced"><phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> T<phrase role="special">,</phrase> <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> N<phrase role="special">></phrase>
+ <phrase role="keyword">bool</phrase> <anchor id="boost.array.operator=="/><phrase role="keyword">operator</phrase><phrase role="special">==</phrase><phrase role="special">(</phrase><phrase role="keyword">const</phrase> <link linkend="boost.array">array</link><phrase role="special"><</phrase><phrase role="identifier">T</phrase><phrase role="special">,</phrase> <phrase role="identifier">N</phrase><phrase role="special">></phrase><phrase role="special">&</phrase> x<phrase role="special">,</phrase> <phrase role="keyword">const</phrase> <link linkend="boost.array">array</link><phrase role="special"><</phrase><phrase role="identifier">T</phrase><phrase role="special">,</phrase> <phrase role="identifier">N</phrase><phrase role="special">></phrase><phrase role="special">&</phrase> y<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><simpara><computeroutput>std::equal(x.<link linkend="id3-bb">begin</link>(), x.<link linkend="id6-bb">end</link>(), y.<link linkend="id3-bb">begin</link>())</computeroutput></simpara></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> T<phrase role="special">,</phrase> <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> N<phrase role="special">></phrase>
+ <phrase role="keyword">bool</phrase> <anchor id="boost.array.operator!="/><phrase role="keyword">operator</phrase><phrase role="special">!=</phrase><phrase role="special">(</phrase><phrase role="keyword">const</phrase> <link linkend="boost.array">array</link><phrase role="special"><</phrase><phrase role="identifier">T</phrase><phrase role="special">,</phrase> <phrase role="identifier">N</phrase><phrase role="special">></phrase><phrase role="special">&</phrase> x<phrase role="special">,</phrase> <phrase role="keyword">const</phrase> <link linkend="boost.array">array</link><phrase role="special"><</phrase><phrase role="identifier">T</phrase><phrase role="special">,</phrase> <phrase role="identifier">N</phrase><phrase role="special">></phrase><phrase role="special">&</phrase> y<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><simpara><computeroutput>!(x == y)</computeroutput></simpara></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> T<phrase role="special">,</phrase> <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> N<phrase role="special">></phrase>
+ <phrase role="keyword">bool</phrase> <anchor id="boost.array.operator_id1"/><phrase role="keyword">operator</phrase><phrase role="special"><</phrase><phrase role="special">(</phrase><phrase role="keyword">const</phrase> <link linkend="boost.array">array</link><phrase role="special"><</phrase><phrase role="identifier">T</phrase><phrase role="special">,</phrase> <phrase role="identifier">N</phrase><phrase role="special">></phrase><phrase role="special">&</phrase> x<phrase role="special">,</phrase> <phrase role="keyword">const</phrase> <link linkend="boost.array">array</link><phrase role="special"><</phrase><phrase role="identifier">T</phrase><phrase role="special">,</phrase> <phrase role="identifier">N</phrase><phrase role="special">></phrase><phrase role="special">&</phrase> y<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><simpara><computeroutput>std::lexicographical_compare(x.<link linkend="id3-bb">begin</link>(), x.<link linkend="id6-bb">end</link>(), y.<link linkend="id3-bb">begin</link>(), y.<link linkend="id6-bb">end</link>())</computeroutput></simpara></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> T<phrase role="special">,</phrase> <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> N<phrase role="special">></phrase>
+ <phrase role="keyword">bool</phrase> <anchor id="boost.array.operator_id2"/><phrase role="keyword">operator</phrase><phrase role="special">></phrase><phrase role="special">(</phrase><phrase role="keyword">const</phrase> <link linkend="boost.array">array</link><phrase role="special"><</phrase><phrase role="identifier">T</phrase><phrase role="special">,</phrase> <phrase role="identifier">N</phrase><phrase role="special">></phrase><phrase role="special">&</phrase> x<phrase role="special">,</phrase> <phrase role="keyword">const</phrase> <link linkend="boost.array">array</link><phrase role="special"><</phrase><phrase role="identifier">T</phrase><phrase role="special">,</phrase> <phrase role="identifier">N</phrase><phrase role="special">></phrase><phrase role="special">&</phrase> y<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><simpara><computeroutput>y < x</computeroutput></simpara></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> T<phrase role="special">,</phrase> <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> N<phrase role="special">></phrase>
+ <phrase role="keyword">bool</phrase> <anchor id="boost.array.operator_=_id1"/><phrase role="keyword">operator</phrase><phrase role="special"><=</phrase><phrase role="special">(</phrase><phrase role="keyword">const</phrase> <link linkend="boost.array">array</link><phrase role="special"><</phrase><phrase role="identifier">T</phrase><phrase role="special">,</phrase> <phrase role="identifier">N</phrase><phrase role="special">></phrase><phrase role="special">&</phrase> x<phrase role="special">,</phrase> <phrase role="keyword">const</phrase> <link linkend="boost.array">array</link><phrase role="special"><</phrase><phrase role="identifier">T</phrase><phrase role="special">,</phrase> <phrase role="identifier">N</phrase><phrase role="special">></phrase><phrase role="special">&</phrase> y<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><simpara><computeroutput>!(y < x)</computeroutput></simpara></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> T<phrase role="special">,</phrase> <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> N<phrase role="special">></phrase>
+ <phrase role="keyword">bool</phrase> <anchor id="boost.array.operator_=_id2"/><phrase role="keyword">operator</phrase><phrase role="special">>=</phrase><phrase role="special">(</phrase><phrase role="keyword">const</phrase> <link linkend="boost.array">array</link><phrase role="special"><</phrase><phrase role="identifier">T</phrase><phrase role="special">,</phrase> <phrase role="identifier">N</phrase><phrase role="special">></phrase><phrase role="special">&</phrase> x<phrase role="special">,</phrase> <phrase role="keyword">const</phrase> <link linkend="boost.array">array</link><phrase role="special"><</phrase><phrase role="identifier">T</phrase><phrase role="special">,</phrase> <phrase role="identifier">N</phrase><phrase role="special">></phrase><phrase role="special">&</phrase> y<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><simpara><computeroutput>!(x < y)</computeroutput></simpara></listitem></varlistentry></variablelist></listitem></orderedlist></refsect2></refsect1></refentry>
+ </section>
+ </section>
+
+<section id="array.rationale">
+ <title>Design Rationale</title>
+
+ <para>There was an important design tradeoff regarding the
+ constructors: We could implement array as an "aggregate" (see
+ Section 8.5.1, [dcl.init.aggr], of the C++ Standard). This would
+ mean:
+ <itemizedlist>
+ <listitem><simpara>An array can be initialized with a
+ brace-enclosing, comma-separated list of initializers for the
+ elements of the container, written in increasing subscript
+ order:</simpara>
+
+ <programlisting xmlns:xi="http://www.w3.org/2001/XInclude"><computeroutput><link linkend="boost.array">boost::array</link></computeroutput><int,4> a = { { 1, 2, 3 } };</programlisting>
+
+ <simpara>Note that if there are fewer elements in the
+ initializer list, then each remaining element gets
+ default-initialized (thus, it has a defined value).</simpara>
+ </listitem></itemizedlist></para>
+
+ <para>However, this approach has its drawbacks: <emphasis role="bold"> passing no initializer list means that the elements
+ have an indetermined initial value</emphasis>, because the rule says
+ that aggregates may have:
+ <itemizedlist>
+ <listitem><simpara>No user-declared constructors.</simpara></listitem>
+ <listitem><simpara>No private or protected non-static data members.</simpara></listitem>
+ <listitem><simpara>No base classes.</simpara></listitem>
+ <listitem><simpara>No virtual functions.</simpara></listitem>
+ </itemizedlist>
+ </para>
+
+ <para>Nevertheless, The current implementation uses this approach.</para>
+
+ <para>Note that for standard conforming compilers it is possible to
+ use fewer braces (according to 8.5.1 (11) of the Standard). That is,
+ you can initialize an array as follows:</para>
+
+<programlisting xmlns:xi="http://www.w3.org/2001/XInclude">
+<computeroutput><link linkend="boost.array">boost::array</link></computeroutput><int,4> a = { 1, 2, 3 };
+</programlisting>
+
+ <para>I'd appreciate any constructive feedback. <emphasis role="bold">Please note: I don't have time to read all boost
+ mails. Thus, to make sure that feedback arrives to me, please send
+ me a copy of each mail regarding this class.</emphasis></para>
+
+ <para>The code is provided "as is" without expressed or implied
+ warranty.</para>
+
+</section>
+
+<section id="array.more.info">
+ <title>For more information...</title>
+ <para>To find more details about using ordinary arrays in C++ and
+ the framework of the STL, see e.g.
+
+ <literallayout>The C++ Standard Library - A Tutorial and Reference
+by Nicolai M. Josuttis
+Addison Wesley Longman, 1999
+ISBN 0-201-37926-0</literallayout>
+ </para>
+
+ <para><ulink url="http://www.josuttis.com/">Home Page of Nicolai
+ Josuttis</ulink></para>
+</section>
+
+<section id="array.ack">
+ <title>Acknowledgements</title>
+
+ <para>Doug Gregor ported the documentation to the BoostBook format.</para>
+</section>
+
+
+
+</chapter>
\ No newline at end of file
Added: trunk/tools/boostbook/test/more/tests/libs/array.xml
==============================================================================
--- (empty file)
+++ trunk/tools/boostbook/test/more/tests/libs/array.xml 2010-08-15 12:49:10 EDT (Sun, 15 Aug 2010)
@@ -0,0 +1,546 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!DOCTYPE library PUBLIC "-//Boost//DTD BoostBook XML V1.0//EN"
+ "http://www.boost.org/tools/boostbook/dtd/boostbook.dtd">
+<library name="Array" dirname="array" id="array" last-revision="$Date$">
+ <libraryinfo>
+ <author>
+ <firstname>Nicolai</firstname>
+ <surname>Josuttis</surname>
+ </author>
+
+ <copyright>
+ <year>2001</year>
+ <year>2002</year>
+ <year>2003</year>
+ <year>2004</year>
+ <holder>Nicolai M. Josuttis</holder>
+ </copyright>
+
+ <legalnotice>
+ <para>Distributed under the Boost Software License, Version 1.0.
+ (See accompanying file <filename>LICENSE_1_0.txt</filename> or copy at
+ <ulink
+ url="http://www.boost.org/LICENSE_1_0.txt">http://www.boost.org/LICENSE_1_0.txt>)
+ </para>
+ </legalnotice>
+
+ <librarypurpose>STL compliant container wrapper for arrays of constant size</librarypurpose>
+ <librarycategory name="category:containers"/>
+ </libraryinfo>
+
+ <title>Boost.Array</title>
+
+ <section id="array.intro">
+ <title>Introduction</title>
+
+ <using-namespace name="boost"/>
+ <using-class name="array"/>
+
+ <para>The C++ Standard Template Library STL as part of the C++
+ Standard Library provides a framework for processing algorithms on
+ different kind of containers. However, ordinary arrays don't
+ provide the interface of STL containers (although, they provide
+ the iterator interface of STL containers).</para>
+
+ <para>As replacement for ordinary arrays, the STL provides class
+ <code><classname>std::vector</classname></code>. However,
+ <code><classname>std::vector<></classname></code> provides
+ the semantics of dynamic arrays. Thus, it manages data to be able
+ to change the number of elements. This results in some overhead in
+ case only arrays with static size are needed.</para>
+
+ <para>In his book, <emphasis>Generic Programming and the
+ STL</emphasis>, Matthew H. Austern introduces a useful wrapper
+ class for ordinary arrays with static size, called
+ <code>block</code>. It is safer and has no worse performance than
+ ordinary arrays. In <emphasis>The C++ Programming
+ Language</emphasis>, 3rd edition, Bjarne Stroustrup introduces a
+ similar class, called <code>c_array</code>, which I (<ulink
+ url="http://www.josuttis.com">Nicolai Josuttis</ulink>) present
+ slightly modified in my book <emphasis>The C++ Standard Library -
+ A Tutorial and Reference</emphasis>, called
+ <code>carray</code>. This is the essence of these approaches
+ spiced with many feedback from <ulink
+ url="http://www.boost.org">boost</ulink>.</para>
+
+ <para>After considering different names, we decided to name this
+ class simply <code><classname>array</classname></code>.</para>
+
+ <para>Note that this class is suggested to be part of the next
+ Technical Report, which will extend the C++ Standard (see
+ <ulink url="http://std.dkuug.dk/jtc1/sc22/wg21/docs/papers/2003/n1548.htm">http://std.dkuug.dk/jtc1/sc22/wg21/docs/papers/2003/n1548.htm>).</para>
+
+ <para>Class <code><classname>array</classname></code> fulfills most
+ but not all of the requirements of "reversible containers" (see
+ Section 23.1, [lib.container.requirements] of the C++
+ Standard). The reasons array is not an reversible STL container is
+ because:
+ <itemizedlist spacing="compact">
+ <listitem><simpara>No constructors are provided.</simpara></listitem>
+ <listitem><simpara>Elements may have an undetermined initial value (see <xref linkend="array.rationale"/>).</simpara></listitem>
+ <listitem><simpara><functionname>swap</functionname>() has no constant complexity.</simpara></listitem>
+ <listitem><simpara><methodname>size</methodname>() is always constant, based on the second template argument of the type.</simpara></listitem>
+ <listitem><simpara>The container provides no allocator support.</simpara></listitem>
+ </itemizedlist>
+ </para>
+
+ <para>It doesn't fulfill the requirements of a "sequence" (see Section 23.1.1, [lib.sequence.reqmts] of the C++ Standard), except that:
+ <itemizedlist spacing="compact">
+ <listitem><simpara><methodname>front</methodname>() and <methodname>back</methodname>() are provided.</simpara></listitem>
+ <listitem><simpara><methodname>operator[]</methodname> and <methodname>at</methodname>() are provided.</simpara></listitem>
+ </itemizedlist>
+ </para>
+ </section>
+
+ <library-reference>
+ <header name="boost/array.hpp">
+ <namespace name="boost">
+ <class name="array">
+ <template>
+ <template-type-parameter name="T"/>
+ <template-nontype-parameter name="N">
+ <type>std::size_t</type>
+ </template-nontype-parameter>
+ </template>
+
+ <purpose><para>STL compliant container wrapper for arrays of constant size</para></purpose>
+ <typedef name="value_type">
+ <type>T</type>
+ </typedef>
+ <typedef name="iterator">
+ <type>T*</type>
+ </typedef>
+ <typedef name="const_iterator">
+ <type>const T*</type>
+ </typedef>
+ <typedef name="reverse_iterator">
+ <type><classname>std::reverse_iterator</classname><iterator></type>
+ </typedef>
+ <typedef name="const_reverse_iterator">
+ <type><classname>std::reverse_iterator</classname><const_iterator></type>
+ </typedef>
+ <typedef name="reference">
+ <type>T&</type>
+ </typedef>
+ <typedef name="const_reference">
+ <type>const T&</type>
+ </typedef>
+ <typedef name="size_type">
+ <type>std::size_t</type>
+ </typedef>
+ <typedef name="difference_type">
+ <type>std::ptrdiff_t</type>
+ </typedef>
+
+ <static-constant name="static_size">
+ <type>size_type</type>
+ <default>N</default>
+ </static-constant>
+
+ <copy-assignment>
+ <template>
+ <template-type-parameter name="U"/>
+ </template>
+ <parameter name="other">
+ <paramtype>const <classname>array</classname><U, N>&</paramtype>
+ </parameter>
+ <effects><simpara><code>std::copy(rhs.<methodname>begin</methodname>(),rhs.<methodname>end</methodname>(), <methodname>begin</methodname>())</code></simpara></effects>
+ </copy-assignment>
+
+ <method-group name="iterator support">
+ <overloaded-method name="begin">
+ <signature>
+ <type>iterator</type>
+ </signature>
+ <signature cv="const">
+ <type>const_iterator</type>
+ </signature>
+
+ <returns><simpara>iterator for the first element</simpara></returns>
+ <throws><simpara>will not throw</simpara></throws>
+ </overloaded-method>
+
+ <overloaded-method name="end">
+ <signature>
+ <type>iterator</type>
+ </signature>
+ <signature cv="const">
+ <type>const_iterator</type>
+ </signature>
+
+ <returns><simpara>iterator for position after the last element</simpara></returns>
+ <throws><simpara>will not throw</simpara></throws>
+ </overloaded-method>
+ </method-group>
+
+ <method-group name="reverse iterator support">
+ <overloaded-method name="rbegin">
+ <signature>
+ <type>reverse_iterator</type>
+ </signature>
+ <signature cv="const">
+ <type>const_reverse_iterator</type>
+ </signature>
+
+ <returns><simpara>reverse iterator for the first element of reverse iteration</simpara></returns>
+ </overloaded-method>
+
+ <overloaded-method name="rend">
+ <signature>
+ <type>reverse_iterator</type>
+ </signature>
+ <signature cv="const">
+ <type>const_reverse_iterator</type>
+ </signature>
+
+ <returns><simpara>reverse iterator for position after the last element in reverse iteration</simpara></returns>
+ </overloaded-method>
+ </method-group>
+
+ <method-group name="capacity">
+ <method name="size">
+ <type>size_type</type>
+ <returns><simpara><code>N</code></simpara></returns>
+ </method>
+ <method name="empty">
+ <type>bool</type>
+ <returns><simpara><code>N==0</code></simpara></returns>
+ <throws><simpara>will not throw</simpara></throws>
+ </method>
+ <method name="max_size">
+ <type>size_type</type>
+ <returns><simpara><code>N</code></simpara></returns>
+ <throws><simpara>will not throw</simpara></throws>
+ </method>
+ </method-group>
+
+ <method-group name="element access">
+ <overloaded-method name="operator[]">
+ <signature>
+ <type>reference</type>
+ <parameter name="i">
+ <paramtype>size_type</paramtype>
+ </parameter>
+ </signature>
+
+ <signature cv="const">
+ <type>const_reference</type>
+ <parameter name="i">
+ <paramtype>size_type</paramtype>
+ </parameter>
+ </signature>
+
+ <requires><simpara><code>i < N</code></simpara></requires>
+ <returns><simpara>element with index <code>i</code></simpara></returns>
+ <throws><simpara>will not throw.</simpara></throws>
+ </overloaded-method>
+
+ <overloaded-method name="at">
+ <signature>
+ <type>reference</type>
+ <parameter name="i">
+ <paramtype>size_type</paramtype>
+ </parameter>
+ </signature>
+
+ <signature cv="const">
+ <type>const_reference</type>
+ <parameter name="i">
+ <paramtype>size_type</paramtype>
+ </parameter>
+ </signature>
+
+ <returns><simpara>element with index <code>i</code></simpara></returns>
+ <throws><simpara><code><classname>std::range_error</classname></code> if <code>i >= N</code></simpara></throws>
+ </overloaded-method>
+
+ <overloaded-method name="front">
+ <signature>
+ <type>reference</type>
+ </signature>
+ <signature cv="const">
+ <type>const_reference</type>
+ </signature>
+ <requires><simpara><code>N > 0</code></simpara></requires>
+ <returns><simpara>the first element</simpara></returns>
+ <throws><simpara>will not throw</simpara></throws>
+ </overloaded-method>
+
+ <overloaded-method name="back">
+ <signature>
+ <type>reference</type>
+ </signature>
+ <signature cv="const">
+ <type>const_reference</type>
+ </signature>
+ <requires><simpara><code>N > 0</code></simpara></requires>
+ <returns><simpara>the last element</simpara></returns>
+ <throws><simpara>will not throw</simpara></throws>
+ </overloaded-method>
+
+ <method name="data" cv="const">
+ <type>const T*</type>
+ <returns><simpara><code>elems</code></simpara></returns>
+ <throws><simpara>will not throw</simpara></throws>
+ </method>
+
+ <method name="c_array">
+ <type>T*</type>
+ <returns><simpara><code>elems</code></simpara></returns>
+ <throws><simpara>will not throw</simpara></throws>
+ </method>
+ </method-group>
+
+ <method-group name="modifiers">
+ <method name="swap">
+ <type>void</type>
+ <parameter name="other">
+ <paramtype><classname>array</classname><T, N>&</paramtype>
+ </parameter>
+ <effects><simpara><code>std::swap_ranges(<methodname>begin</methodname>(), <methodname>end</methodname>(), other.<methodname>begin</methodname>())</code></simpara></effects>
+ <complexity><simpara>linear in <code>N</code></simpara></complexity>
+ </method>
+ <method name="assign">
+ <type>void</type>
+ <parameter name="value">
+ <paramtype>const T&</paramtype>
+ </parameter>
+ <effects><simpara><code>std::fill_n(<methodname>begin</methodname>(), N, value)</code></simpara></effects>
+ </method>
+ </method-group>
+
+ <data-member name="elems[N]"> <!-- HACK -->
+ <type>T</type>
+ </data-member>
+
+ <free-function-group name="specialized algorithms">
+ <function name="swap">
+ <template>
+ <template-type-parameter name="T"/>
+ <template-nontype-parameter name="N">
+ <type>std::size_t</type>
+ </template-nontype-parameter>
+ </template>
+
+ <type>void</type>
+
+ <parameter name="x">
+ <paramtype><classname>array</classname><T, N>&</paramtype>
+ </parameter>
+ <parameter name="y">
+ <paramtype><classname>array</classname><T, N>&</paramtype>
+ </parameter>
+
+ <effects><simpara><code>x.<methodname>swap</methodname>(y)</code></simpara></effects>
+ <throws><simpara>will not throw.</simpara></throws>
+ </function>
+ </free-function-group>
+
+ <free-function-group name="comparisons">
+ <function name="operator==">
+ <template>
+ <template-type-parameter name="T"/>
+ <template-nontype-parameter name="N">
+ <type>std::size_t</type>
+ </template-nontype-parameter>
+ </template>
+
+ <type>bool</type>
+
+ <parameter name="x">
+ <paramtype>const <classname>array</classname><T, N>&</paramtype>
+ </parameter>
+ <parameter name="y">
+ <paramtype>const <classname>array</classname><T, N>&</paramtype>
+ </parameter>
+
+ <returns><simpara><code>std::equal(x.<methodname>begin</methodname>(), x.<methodname>end</methodname>(), y.<methodname>begin</methodname>())</code></simpara>
+ </returns>
+ </function>
+
+ <function name="operator!=">
+ <template>
+ <template-type-parameter name="T"/>
+ <template-nontype-parameter name="N">
+ <type>std::size_t</type>
+ </template-nontype-parameter>
+ </template>
+
+ <type>bool</type>
+
+ <parameter name="x">
+ <paramtype>const <classname>array</classname><T, N>&</paramtype>
+ </parameter>
+ <parameter name="y">
+ <paramtype>const <classname>array</classname><T, N>&</paramtype>
+ </parameter>
+
+ <returns><simpara><code>!(x == y)</code></simpara>
+ </returns>
+ </function>
+
+ <function name="operator<">
+ <template>
+ <template-type-parameter name="T"/>
+ <template-nontype-parameter name="N">
+ <type>std::size_t</type>
+ </template-nontype-parameter>
+ </template>
+
+ <type>bool</type>
+
+ <parameter name="x">
+ <paramtype>const <classname>array</classname><T, N>&</paramtype>
+ </parameter>
+ <parameter name="y">
+ <paramtype>const <classname>array</classname><T, N>&</paramtype>
+ </parameter>
+
+ <returns><simpara><code>std::lexicographical_compare(x.<methodname>begin</methodname>(), x.<methodname>end</methodname>(), y.<methodname>begin</methodname>(), y.<methodname>end</methodname>())</code></simpara>
+ </returns>
+ </function>
+
+ <function name="operator>">
+ <template>
+ <template-type-parameter name="T"/>
+ <template-nontype-parameter name="N">
+ <type>std::size_t</type>
+ </template-nontype-parameter>
+ </template>
+
+ <type>bool</type>
+
+ <parameter name="x">
+ <paramtype>const <classname>array</classname><T, N>&</paramtype>
+ </parameter>
+ <parameter name="y">
+ <paramtype>const <classname>array</classname><T, N>&</paramtype>
+ </parameter>
+
+ <returns><simpara><code>y < x</code></simpara></returns>
+ </function>
+
+ <function name="operator<=">
+ <template>
+ <template-type-parameter name="T"/>
+ <template-nontype-parameter name="N">
+ <type>std::size_t</type>
+ </template-nontype-parameter>
+ </template>
+
+ <type>bool</type>
+
+ <parameter name="x">
+ <paramtype>const <classname>array</classname><T, N>&</paramtype>
+ </parameter>
+ <parameter name="y">
+ <paramtype>const <classname>array</classname><T, N>&</paramtype>
+ </parameter>
+
+ <returns><simpara><code>!(y < x)</code></simpara></returns>
+ </function>
+
+ <function name="operator>=">
+ <template>
+ <template-type-parameter name="T"/>
+ <template-nontype-parameter name="N">
+ <type>std::size_t</type>
+ </template-nontype-parameter>
+ </template>
+
+ <type>bool</type>
+
+ <parameter name="x">
+ <paramtype>const <classname>array</classname><T, N>&</paramtype>
+ </parameter>
+ <parameter name="y">
+ <paramtype>const <classname>array</classname><T, N>&</paramtype>
+ </parameter>
+
+ <returns><simpara><code>!(x < y)</code></simpara></returns>
+ </function>
+ </free-function-group>
+ </class>
+ </namespace>
+ </header>
+ </library-reference>
+
+<section id="array.rationale">
+ <title>Design Rationale</title>
+
+ <para>There was an important design tradeoff regarding the
+ constructors: We could implement array as an "aggregate" (see
+ Section 8.5.1, [dcl.init.aggr], of the C++ Standard). This would
+ mean:
+ <itemizedlist>
+ <listitem><simpara>An array can be initialized with a
+ brace-enclosing, comma-separated list of initializers for the
+ elements of the container, written in increasing subscript
+ order:</simpara>
+
+ <programlisting><classname>boost::array</classname><int,4> a = { { 1, 2, 3 } };</programlisting>
+
+ <simpara>Note that if there are fewer elements in the
+ initializer list, then each remaining element gets
+ default-initialized (thus, it has a defined value).</simpara>
+ </listitem></itemizedlist></para>
+
+ <para>However, this approach has its drawbacks: <emphasis
+ role="bold"> passing no initializer list means that the elements
+ have an indetermined initial value</emphasis>, because the rule says
+ that aggregates may have:
+ <itemizedlist>
+ <listitem><simpara>No user-declared constructors.</simpara></listitem>
+ <listitem><simpara>No private or protected non-static data members.</simpara></listitem>
+ <listitem><simpara>No base classes.</simpara></listitem>
+ <listitem><simpara>No virtual functions.</simpara></listitem>
+ </itemizedlist>
+ </para>
+
+ <para>Nevertheless, The current implementation uses this approach.</para>
+
+ <para>Note that for standard conforming compilers it is possible to
+ use fewer braces (according to 8.5.1 (11) of the Standard). That is,
+ you can initialize an array as follows:</para>
+
+<programlisting>
+<classname>boost::array</classname><int,4> a = { 1, 2, 3 };
+</programlisting>
+
+ <para>I'd appreciate any constructive feedback. <emphasis
+ role="bold">Please note: I don't have time to read all boost
+ mails. Thus, to make sure that feedback arrives to me, please send
+ me a copy of each mail regarding this class.</emphasis></para>
+
+ <para>The code is provided "as is" without expressed or implied
+ warranty.</para>
+
+</section>
+
+<section id="array.more.info">
+ <title>For more information...</title>
+ <para>To find more details about using ordinary arrays in C++ and
+ the framework of the STL, see e.g.
+
+ <literallayout>The C++ Standard Library - A Tutorial and Reference
+by Nicolai M. Josuttis
+Addison Wesley Longman, 1999
+ISBN 0-201-37926-0</literallayout>
+ </para>
+
+ <para><ulink url="http://www.josuttis.com/">Home Page of Nicolai
+ Josuttis</ulink></para>
+</section>
+
+<section id="array.ack">
+ <title>Acknowledgements</title>
+
+ <para>Doug Gregor ported the documentation to the BoostBook format.</para>
+</section>
+
+<!-- Notes:
+ empty() should return N != 0
+ size(), empty(), max_size() should be const
+ -->
+
+</library>
Added: trunk/tools/boostbook/test/more/tests/libs/hash-ref.gold
==============================================================================
--- (empty file)
+++ trunk/tools/boostbook/test/more/tests/libs/hash-ref.gold 2010-08-15 12:49:10 EDT (Sun, 15 Aug 2010)
@@ -0,0 +1,397 @@
+<!DOCTYPE section PUBLIC "-//OASIS//DTD DocBook XML V4.2//EN" "http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd">
+<section><title>Reference</title>
+ <section id="hash.reference.specification">
+ <para>For the full specification, see section 6.3 of the
+ <ulink url="http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2005/n1836.pdf">C++ Standard Library Technical Report</ulink>
+ and issue 6.18 of the
+ <ulink url="http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2005/n1837.pdf">Library Extension Technical Report Issues List</ulink> (page 63).
+ </para>
+ </section>
+ <section id="header.boost.functional.hash_hpp"><title>Header <<ulink url="../../boost/functional/hash.hpp">boost/functional/hash.hpp</ulink>></title><para>
+ Defines <computeroutput><link xmlns:xi="http://www.w3.org/2001/XInclude" linkend="boost.hash">boost::hash</link></computeroutput>,
+ and helper functions.
+ </para><synopsis xmlns:xi="http://www.w3.org/2001/XInclude"><phrase role="keyword">namespace</phrase> <phrase role="identifier">boost</phrase> <phrase role="special">{</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> T<phrase role="special">></phrase> <phrase role="keyword">struct</phrase> <link linkend="boost.hash">hash</link><phrase role="special">;</phrase>
+
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="special">></phrase> <phrase role="keyword">struct</phrase> <link linkend="boost.hash_bool_id1">hash</link><phrase role="special"><</phrase><phrase role="keyword">bool</phrase><phrase role="special">></phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="special">></phrase> <phrase role="keyword">struct</phrase> <link linkend="boost.hash_char_id1">hash</link><phrase role="special"><</phrase><phrase role="keyword">char</phrase><phrase role="special">></phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="special">></phrase> <phrase role="keyword">struct</phrase> <link linkend="boost.hash_signed_char_id1">hash</link><phrase role="special"><</phrase><phrase role="keyword">signed</phrase> <phrase role="keyword">char</phrase><phrase role="special">></phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="special">></phrase> <phrase role="keyword">struct</phrase> <link linkend="boost.hash_unsigned_char_id1">hash</link><phrase role="special"><</phrase><phrase role="keyword">unsigned</phrase> <phrase role="keyword">char</phrase><phrase role="special">></phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="special">></phrase> <phrase role="keyword">struct</phrase> <link linkend="boost.hash_wchar_t_id1">hash</link><phrase role="special"><</phrase><phrase role="keyword">wchar_t</phrase><phrase role="special">></phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="special">></phrase> <phrase role="keyword">struct</phrase> <link linkend="boost.hash_short_id1">hash</link><phrase role="special"><</phrase><phrase role="keyword">short</phrase><phrase role="special">></phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="special">></phrase> <phrase role="keyword">struct</phrase> <link linkend="boost.hash_unsigned_short_id1">hash</link><phrase role="special"><</phrase><phrase role="keyword">unsigned</phrase> <phrase role="keyword">short</phrase><phrase role="special">></phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="special">></phrase> <phrase role="keyword">struct</phrase> <link linkend="boost.hash_int_id1">hash</link><phrase role="special"><</phrase><phrase role="keyword">int</phrase><phrase role="special">></phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="special">></phrase> <phrase role="keyword">struct</phrase> <link linkend="boost.hash_unsigned_int_id1">hash</link><phrase role="special"><</phrase><phrase role="keyword">unsigned</phrase> <phrase role="keyword">int</phrase><phrase role="special">></phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="special">></phrase> <phrase role="keyword">struct</phrase> <link linkend="boost.hash_long_id1">hash</link><phrase role="special"><</phrase><phrase role="keyword">long</phrase><phrase role="special">></phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="special">></phrase> <phrase role="keyword">struct</phrase> <link linkend="boost.hash_unsigned_long_id1">hash</link><phrase role="special"><</phrase><phrase role="keyword">unsigned</phrase> <phrase role="keyword">long</phrase><phrase role="special">></phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="special">></phrase> <phrase role="keyword">struct</phrase> <link linkend="boost.hash_long_long_id1">hash</link><phrase role="special"><</phrase><phrase role="keyword">long</phrase> <phrase role="keyword">long</phrase><phrase role="special">></phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="special">></phrase> <phrase role="keyword">struct</phrase> <link linkend="boost.hash_unsigned_long_long_id1">hash</link><phrase role="special"><</phrase><phrase role="keyword">unsigned</phrase> <phrase role="keyword">long</phrase> <phrase role="keyword">long</phrase><phrase role="special">></phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="special">></phrase> <phrase role="keyword">struct</phrase> <link linkend="boost.hash_float_id1">hash</link><phrase role="special"><</phrase><phrase role="keyword">float</phrase><phrase role="special">></phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="special">></phrase> <phrase role="keyword">struct</phrase> <link linkend="boost.hash_double_id1">hash</link><phrase role="special"><</phrase><phrase role="keyword">double</phrase><phrase role="special">></phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="special">></phrase> <phrase role="keyword">struct</phrase> <link linkend="boost.hash_long_double_id1">hash</link><phrase role="special"><</phrase><phrase role="keyword">long</phrase> <phrase role="keyword">double</phrase><phrase role="special">></phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="special">></phrase> <phrase role="keyword">struct</phrase> <link linkend="boost.hash_std_string_id1">hash</link><phrase role="special"><</phrase><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">string</phrase><phrase role="special">></phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="special">></phrase> <phrase role="keyword">struct</phrase> <link linkend="boost.hash_std_wstring_id1">hash</link><phrase role="special"><</phrase><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">wstring</phrase><phrase role="special">></phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> T<phrase role="special">></phrase> <phrase role="keyword">struct</phrase> <link linkend="boost.hash_T_id1">hash</link><phrase role="special"><</phrase><phrase role="identifier">T</phrase><phrase role="special">*</phrase><phrase role="special">></phrase><phrase role="special">;</phrase>
+
+ <phrase role="comment">// <link linkend="id1-bb">Support functions (Boost extension).</link></phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> T<phrase role="special">></phrase> <phrase role="keyword">void</phrase> <link linkend="boost.hash_combine"><phrase role="identifier">hash_combine</phrase></link><phrase role="special">(</phrase><phrase role="identifier">size_t</phrase> <phrase role="special">&</phrase><phrase role="special">,</phrase> <phrase role="identifier">T</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> It<phrase role="special">></phrase> <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <link linkend="id2-bb"><phrase role="identifier">hash_range</phrase></link><phrase role="special">(</phrase><phrase role="identifier">It</phrase><phrase role="special">,</phrase> <phrase role="identifier">It</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> It<phrase role="special">></phrase> <phrase role="keyword">void</phrase> <link linkend="id3-bb"><phrase role="identifier">hash_range</phrase></link><phrase role="special">(</phrase><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase><phrase role="special">&</phrase><phrase role="special">,</phrase> <phrase role="identifier">It</phrase><phrase role="special">,</phrase> <phrase role="identifier">It</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+
+ <phrase role="comment">// <link linkend="id4-bb">Overloadable hash implementation (Boost extension).</link></phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <link linkend="id5-bb"><phrase role="identifier">hash_value</phrase></link><phrase role="special">(</phrase><phrase role="keyword">bool</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <link linkend="id6-bb"><phrase role="identifier">hash_value</phrase></link><phrase role="special">(</phrase><phrase role="keyword">char</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <link linkend="id7-bb"><phrase role="identifier">hash_value</phrase></link><phrase role="special">(</phrase><phrase role="keyword">signed</phrase> <phrase role="keyword">char</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <link linkend="id8-bb"><phrase role="identifier">hash_value</phrase></link><phrase role="special">(</phrase><phrase role="keyword">unsigned</phrase> <phrase role="keyword">char</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <link linkend="id9-bb"><phrase role="identifier">hash_value</phrase></link><phrase role="special">(</phrase><phrase role="keyword">wchar_t</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <link linkend="id10-bb"><phrase role="identifier">hash_value</phrase></link><phrase role="special">(</phrase><phrase role="keyword">short</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <link linkend="id11-bb"><phrase role="identifier">hash_value</phrase></link><phrase role="special">(</phrase><phrase role="keyword">unsigned</phrase> <phrase role="keyword">short</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <link linkend="id12-bb"><phrase role="identifier">hash_value</phrase></link><phrase role="special">(</phrase><phrase role="keyword">int</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <link linkend="id13-bb"><phrase role="identifier">hash_value</phrase></link><phrase role="special">(</phrase><phrase role="keyword">unsigned</phrase> <phrase role="keyword">int</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <link linkend="id14-bb"><phrase role="identifier">hash_value</phrase></link><phrase role="special">(</phrase><phrase role="keyword">long</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <link linkend="id15-bb"><phrase role="identifier">hash_value</phrase></link><phrase role="special">(</phrase><phrase role="keyword">unsigned</phrase> <phrase role="keyword">long</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <link linkend="id16-bb"><phrase role="identifier">hash_value</phrase></link><phrase role="special">(</phrase><phrase role="keyword">long</phrase> <phrase role="keyword">long</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <link linkend="id17-bb"><phrase role="identifier">hash_value</phrase></link><phrase role="special">(</phrase><phrase role="keyword">unsigned</phrase> <phrase role="keyword">long</phrase> <phrase role="keyword">long</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <link linkend="id18-bb"><phrase role="identifier">hash_value</phrase></link><phrase role="special">(</phrase><phrase role="keyword">float</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <link linkend="id19-bb"><phrase role="identifier">hash_value</phrase></link><phrase role="special">(</phrase><phrase role="keyword">double</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <link linkend="id20-bb"><phrase role="identifier">hash_value</phrase></link><phrase role="special">(</phrase><phrase role="keyword">long</phrase> <phrase role="keyword">double</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> T<phrase role="special">></phrase> <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <link linkend="id21-bb"><phrase role="identifier">hash_value</phrase></link><phrase role="special">(</phrase><phrase role="identifier">T</phrase><phrase role="special">*</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> T<phrase role="special">,</phrase> <phrase role="keyword">unsigned</phrase> N<phrase role="special">></phrase> <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <link linkend="id22-bb"><phrase role="identifier">hash_value</phrase></link><phrase role="special">(</phrase><phrase role="identifier">T</phrase> <phrase role="special">(</phrase><phrase role="special">&</phrase><phrase role="identifier">val</phrase><phrase role="special">)</phrase><phrase role="special">[</phrase><phrase role="identifier">N</phrase><phrase role="special">]</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> T<phrase role="special">,</phrase> <phrase role="keyword">unsigned</phrase> N<phrase role="special">></phrase> <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <link linkend="id23-bb"><phrase role="identifier">hash_value</phrase></link><phrase role="special">(</phrase><phrase role="keyword">const</phrase> <phrase role="identifier">T</phrase> <phrase role="special">(</phrase><phrase role="special">&</phrase><phrase role="identifier">val</phrase><phrase role="special">)</phrase><phrase role="special">[</phrase><phrase role="identifier">N</phrase><phrase role="special">]</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> Ch<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> A<phrase role="special">></phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <link linkend="id24-bb"><phrase role="identifier">hash_value</phrase></link><phrase role="special">(</phrase><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">basic_string</phrase><phrase role="special"><</phrase><phrase role="identifier">Ch</phrase><phrase role="special">,</phrase> <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">char_traits</phrase><phrase role="special"><</phrase><phrase role="identifier">Ch</phrase><phrase role="special">></phrase><phrase role="special">,</phrase> <phrase role="identifier">A</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> A<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> B<phrase role="special">></phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <link linkend="id25-bb"><phrase role="identifier">hash_value</phrase></link><phrase role="special">(</phrase><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">pair</phrase><phrase role="special"><</phrase><phrase role="identifier">A</phrase><phrase role="special">,</phrase> <phrase role="identifier">B</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> T<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> A<phrase role="special">></phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <link linkend="id26-bb"><phrase role="identifier">hash_value</phrase></link><phrase role="special">(</phrase><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">vector</phrase><phrase role="special"><</phrase><phrase role="identifier">T</phrase><phrase role="special">,</phrase> <phrase role="identifier">A</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> T<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> A<phrase role="special">></phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <link linkend="id27-bb"><phrase role="identifier">hash_value</phrase></link><phrase role="special">(</phrase><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">list</phrase><phrase role="special"><</phrase><phrase role="identifier">T</phrase><phrase role="special">,</phrase> <phrase role="identifier">A</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> T<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> A<phrase role="special">></phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <link linkend="id28-bb"><phrase role="identifier">hash_value</phrase></link><phrase role="special">(</phrase><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">deque</phrase><phrase role="special"><</phrase><phrase role="identifier">T</phrase><phrase role="special">,</phrase> <phrase role="identifier">A</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> K<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> C<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> A<phrase role="special">></phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <link linkend="id29-bb"><phrase role="identifier">hash_value</phrase></link><phrase role="special">(</phrase><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">set</phrase><phrase role="special"><</phrase><phrase role="identifier">K</phrase><phrase role="special">,</phrase> <phrase role="identifier">C</phrase><phrase role="special">,</phrase> <phrase role="identifier">A</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> K<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> C<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> A<phrase role="special">></phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <link linkend="id30-bb"><phrase role="identifier">hash_value</phrase></link><phrase role="special">(</phrase><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">multiset</phrase><phrase role="special"><</phrase><phrase role="identifier">K</phrase><phrase role="special">,</phrase> <phrase role="identifier">C</phrase><phrase role="special">,</phrase> <phrase role="identifier">A</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> K<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> T<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> C<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> A<phrase role="special">></phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <link linkend="id31-bb"><phrase role="identifier">hash_value</phrase></link><phrase role="special">(</phrase><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">map</phrase><phrase role="special"><</phrase><phrase role="identifier">K</phrase><phrase role="special">,</phrase> <phrase role="identifier">T</phrase><phrase role="special">,</phrase> <phrase role="identifier">C</phrase><phrase role="special">,</phrase> <phrase role="identifier">A</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> K<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> T<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> C<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> A<phrase role="special">></phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <link linkend="id32-bb"><phrase role="identifier">hash_value</phrase></link><phrase role="special">(</phrase><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">multimap</phrase><phrase role="special"><</phrase><phrase role="identifier">K</phrase><phrase role="special">,</phrase> <phrase role="identifier">T</phrase><phrase role="special">,</phrase> <phrase role="identifier">C</phrase><phrase role="special">,</phrase> <phrase role="identifier">A</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> T<phrase role="special">></phrase> <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <link linkend="id33-bb"><phrase role="identifier">hash_value</phrase></link><phrase role="special">(</phrase><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">complex</phrase><phrase role="special"><</phrase><phrase role="identifier">T</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="special">}</phrase></synopsis>
+
+
+ <refsect2 xmlns:xi="http://www.w3.org/2001/XInclude"><title><anchor id="id1-bb"/><computeroutput/> Support functions (Boost extension).</title><orderedlist><listitem><para><literallayout class="monospaced"><phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> T<phrase role="special">></phrase> <phrase role="keyword">void</phrase> <anchor id="boost.hash_combine"/><phrase role="identifier">hash_combine</phrase><phrase role="special">(</phrase><phrase role="identifier">size_t</phrase> <phrase role="special">&</phrase> seed<phrase role="special">,</phrase> <phrase role="identifier">T</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> v<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><simpara>
+ Called repeatedly to incrementally create a hash value from
+ several variables.
+ </simpara><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Effects:</term><listitem><programlisting><phrase role="identifier">seed</phrase> <phrase role="special">^=</phrase> <link linkend="boost.hash_value">hash_value</link><phrase role="special">(</phrase><phrase role="identifier">v</phrase><phrase role="special">)</phrase> <phrase role="special">+</phrase> <phrase role="number">0x9e3779b9</phrase> <phrase role="special">+</phrase> <phrase role="special">(</phrase><phrase role="identifier">seed</phrase> <phrase role="special"><<</phrase> <phrase role="number">6</phrase><phrase role="special">)</phrase> <phrase role="special">+</phrase> <phrase role="special">(</phrase><phrase role="identifier">seed</phrase> <phrase role="special">>></phrase> <phrase role="number">2</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase></programlisting></listitem></varlistentry><varlistentry><term>Notes:</term><listitem><para><link linkend="boost.hash_value">hash_value</link> is called without
+ qualification, so that overloads can be found via ADL.</para><para>This is an extension to TR1</para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem>
+ Only throws if <link linkend="boost.hash_value">hash_value</link>(T) throws.
+ Strong exception safety, as long as <link linkend="boost.hash_value">hash_value</link>(T)
+ also has strong exception safety.
+ </listitem></varlistentry></variablelist></listitem><listitem><para id="boost.hash_range"><literallayout class="monospaced"><phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> It<phrase role="special">></phrase> <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <anchor id="id2-bb"/><phrase role="identifier">hash_range</phrase><phrase role="special">(</phrase><phrase role="identifier">It</phrase> first<phrase role="special">,</phrase> <phrase role="identifier">It</phrase> last<phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> It<phrase role="special">></phrase> <phrase role="keyword">void</phrase> <anchor id="id3-bb"/><phrase role="identifier">hash_range</phrase><phrase role="special">(</phrase><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase><phrase role="special">&</phrase> seed<phrase role="special">,</phrase> <phrase role="identifier">It</phrase> first<phrase role="special">,</phrase> <phrase role="identifier">It</phrase> last<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><simpara>
+ Calculate the combined hash value of the elements of an iterator
+ range.
+ </simpara><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Effects:</term><listitem><para>For the two argument overload:
+<programlisting>
+<phrase role="identifier">size_t</phrase> <phrase role="identifier">seed</phrase> <phrase role="special">=</phrase> <phrase role="number">0</phrase><phrase role="special">;</phrase>
+
+<phrase role="keyword">for</phrase><phrase role="special">(</phrase><phrase role="special">;</phrase> <phrase role="identifier">first</phrase> <phrase role="special">!=</phrase> <phrase role="identifier">last</phrase><phrase role="special">;</phrase> <phrase role="special">++</phrase><phrase role="identifier">first</phrase><phrase role="special">)</phrase>
+<phrase role="special">{</phrase>
+ <link linkend="boost.hash_combine">hash_combine</link><phrase role="special">(</phrase><phrase role="identifier">seed</phrase><phrase role="special">,</phrase> <phrase role="special">*</phrase><phrase role="identifier">first</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="special">}</phrase>
+
+<phrase role="keyword">return</phrase> <phrase role="identifier">seed</phrase><phrase role="special">;</phrase>
+</programlisting>
+ </para>For the three arguments overload:
+<programlisting>
+<phrase role="keyword">for</phrase><phrase role="special">(</phrase><phrase role="special">;</phrase> <phrase role="identifier">first</phrase> <phrase role="special">!=</phrase> <phrase role="identifier">last</phrase><phrase role="special">;</phrase> <phrase role="special">++</phrase><phrase role="identifier">first</phrase><phrase role="special">)</phrase>
+<phrase role="special">{</phrase>
+ <link linkend="boost.hash_combine">hash_combine</link><phrase role="special">(</phrase><phrase role="identifier">seed</phrase><phrase role="special">,</phrase> <phrase role="special">*</phrase><phrase role="identifier">first</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="special">}</phrase>
+</programlisting><para>
+ </para></listitem></varlistentry><varlistentry><term>Notes:</term><listitem><para>
+ <computeroutput>hash_range</computeroutput> is sensitive to the order of the elements
+ so it wouldn't be appropriate to use this with an unordered
+ container.
+ </para><para>This is an extension to TR1</para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><para>
+ Only throws if <computeroutput><link linkend="boost.hash_value">hash_value</link>(std::iterator_traits<It>::value_type)</computeroutput>
+ throws. <computeroutput>hash_range(std::size_t&, It, It)</computeroutput> has basic exception safety as long as
+ <computeroutput><link linkend="boost.hash_value">hash_value</link>(std::iterator_traits<It>::value_type)</computeroutput>
+ has basic exception safety.
+ </para></listitem></varlistentry></variablelist></listitem></orderedlist></refsect2><refsect2 xmlns:xi="http://www.w3.org/2001/XInclude"><title><anchor id="id4-bb"/><computeroutput/> Overloadable hash implementation (Boost extension).</title><orderedlist><listitem><para id="boost.hash_value"><literallayout class="monospaced"><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <anchor id="id5-bb"/><phrase role="identifier">hash_value</phrase><phrase role="special">(</phrase><phrase role="keyword">bool</phrase> val<phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <anchor id="id6-bb"/><phrase role="identifier">hash_value</phrase><phrase role="special">(</phrase><phrase role="keyword">char</phrase> val<phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <anchor id="id7-bb"/><phrase role="identifier">hash_value</phrase><phrase role="special">(</phrase><phrase role="keyword">signed</phrase> <phrase role="keyword">char</phrase> val<phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <anchor id="id8-bb"/><phrase role="identifier">hash_value</phrase><phrase role="special">(</phrase><phrase role="keyword">unsigned</phrase> <phrase role="keyword">char</phrase> val<phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <anchor id="id9-bb"/><phrase role="identifier">hash_value</phrase><phrase role="special">(</phrase><phrase role="keyword">wchar_t</phrase> val<phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <anchor id="id10-bb"/><phrase role="identifier">hash_value</phrase><phrase role="special">(</phrase><phrase role="keyword">short</phrase> val<phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <anchor id="id11-bb"/><phrase role="identifier">hash_value</phrase><phrase role="special">(</phrase><phrase role="keyword">unsigned</phrase> <phrase role="keyword">short</phrase> val<phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <anchor id="id12-bb"/><phrase role="identifier">hash_value</phrase><phrase role="special">(</phrase><phrase role="keyword">int</phrase> val<phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <anchor id="id13-bb"/><phrase role="identifier">hash_value</phrase><phrase role="special">(</phrase><phrase role="keyword">unsigned</phrase> <phrase role="keyword">int</phrase> val<phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <anchor id="id14-bb"/><phrase role="identifier">hash_value</phrase><phrase role="special">(</phrase><phrase role="keyword">long</phrase> val<phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <anchor id="id15-bb"/><phrase role="identifier">hash_value</phrase><phrase role="special">(</phrase><phrase role="keyword">unsigned</phrase> <phrase role="keyword">long</phrase> val<phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <anchor id="id16-bb"/><phrase role="identifier">hash_value</phrase><phrase role="special">(</phrase><phrase role="keyword">long</phrase> <phrase role="keyword">long</phrase> val<phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <anchor id="id17-bb"/><phrase role="identifier">hash_value</phrase><phrase role="special">(</phrase><phrase role="keyword">unsigned</phrase> <phrase role="keyword">long</phrase> <phrase role="keyword">long</phrase> val<phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <anchor id="id18-bb"/><phrase role="identifier">hash_value</phrase><phrase role="special">(</phrase><phrase role="keyword">float</phrase> val<phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <anchor id="id19-bb"/><phrase role="identifier">hash_value</phrase><phrase role="special">(</phrase><phrase role="keyword">double</phrase> val<phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <anchor id="id20-bb"/><phrase role="identifier">hash_value</phrase><phrase role="special">(</phrase><phrase role="keyword">long</phrase> <phrase role="keyword">double</phrase> val<phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> T<phrase role="special">></phrase> <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <anchor id="id21-bb"/><phrase role="identifier">hash_value</phrase><phrase role="special">(</phrase><phrase role="identifier">T</phrase><phrase role="special">*</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> val<phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> T<phrase role="special">,</phrase> <phrase role="keyword">unsigned</phrase> N<phrase role="special">></phrase> <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <anchor id="id22-bb"/><phrase role="identifier">hash_value</phrase><phrase role="special">(</phrase><phrase role="identifier">T</phrase> <phrase role="special">(</phrase><phrase role="special">&</phrase><phrase role="identifier">val</phrase><phrase role="special">)</phrase><phrase role="special">[</phrase><phrase role="identifier">N</phrase><phrase role="special">]</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> T<phrase role="special">,</phrase> <phrase role="keyword">unsigned</phrase> N<phrase role="special">></phrase> <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <anchor id="id23-bb"/><phrase role="identifier">hash_value</phrase><phrase role="special">(</phrase><phrase role="keyword">const</phrase> <phrase role="identifier">T</phrase> <phrase role="special">(</phrase><phrase role="special">&</phrase><phrase role="identifier">val</phrase><phrase role="special">)</phrase><phrase role="special">[</phrase><phrase role="identifier">N</phrase><phrase role="special">]</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> Ch<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> A<phrase role="special">></phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <anchor id="id24-bb"/><phrase role="identifier">hash_value</phrase><phrase role="special">(</phrase><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">basic_string</phrase><phrase role="special"><</phrase><phrase role="identifier">Ch</phrase><phrase role="special">,</phrase> <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">char_traits</phrase><phrase role="special"><</phrase><phrase role="identifier">Ch</phrase><phrase role="special">></phrase><phrase role="special">,</phrase> <phrase role="identifier">A</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> val<phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> A<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> B<phrase role="special">></phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <anchor id="id25-bb"/><phrase role="identifier">hash_value</phrase><phrase role="special">(</phrase><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">pair</phrase><phrase role="special"><</phrase><phrase role="identifier">A</phrase><phrase role="special">,</phrase> <phrase role="identifier">B</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> val<phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> T<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> A<phrase role="special">></phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <anchor id="id26-bb"/><phrase role="identifier">hash_value</phrase><phrase role="special">(</phrase><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">vector</phrase><phrase role="special"><</phrase><phrase role="identifier">T</phrase><phrase role="special">,</phrase> <phrase role="identifier">A</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> val<phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> T<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> A<phrase role="special">></phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <anchor id="id27-bb"/><phrase role="identifier">hash_value</phrase><phrase role="special">(</phrase><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">list</phrase><phrase role="special"><</phrase><phrase role="identifier">T</phrase><phrase role="special">,</phrase> <phrase role="identifier">A</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> val<phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> T<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> A<phrase role="special">></phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <anchor id="id28-bb"/><phrase role="identifier">hash_value</phrase><phrase role="special">(</phrase><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">deque</phrase><phrase role="special"><</phrase><phrase role="identifier">T</phrase><phrase role="special">,</phrase> <phrase role="identifier">A</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> val<phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> K<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> C<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> A<phrase role="special">></phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <anchor id="id29-bb"/><phrase role="identifier">hash_value</phrase><phrase role="special">(</phrase><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">set</phrase><phrase role="special"><</phrase><phrase role="identifier">K</phrase><phrase role="special">,</phrase> <phrase role="identifier">C</phrase><phrase role="special">,</phrase> <phrase role="identifier">A</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> val<phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> K<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> C<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> A<phrase role="special">></phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <anchor id="id30-bb"/><phrase role="identifier">hash_value</phrase><phrase role="special">(</phrase><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">multiset</phrase><phrase role="special"><</phrase><phrase role="identifier">K</phrase><phrase role="special">,</phrase> <phrase role="identifier">C</phrase><phrase role="special">,</phrase> <phrase role="identifier">A</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> val<phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> K<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> T<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> C<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> A<phrase role="special">></phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <anchor id="id31-bb"/><phrase role="identifier">hash_value</phrase><phrase role="special">(</phrase><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">map</phrase><phrase role="special"><</phrase><phrase role="identifier">K</phrase><phrase role="special">,</phrase> <phrase role="identifier">T</phrase><phrase role="special">,</phrase> <phrase role="identifier">C</phrase><phrase role="special">,</phrase> <phrase role="identifier">A</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> val<phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> K<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> T<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> C<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> A<phrase role="special">></phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <anchor id="id32-bb"/><phrase role="identifier">hash_value</phrase><phrase role="special">(</phrase><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">multimap</phrase><phrase role="special"><</phrase><phrase role="identifier">K</phrase><phrase role="special">,</phrase> <phrase role="identifier">T</phrase><phrase role="special">,</phrase> <phrase role="identifier">C</phrase><phrase role="special">,</phrase> <phrase role="identifier">A</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> val<phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> T<phrase role="special">></phrase> <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <anchor id="id33-bb"/><phrase role="identifier">hash_value</phrase><phrase role="special">(</phrase><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">complex</phrase><phrase role="special"><</phrase><phrase role="identifier">T</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> val<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><simpara>
+ Implementation of the hash function.
+ </simpara><para>
+ Generally shouldn't be called directly by users, instead they should use
+ <computeroutput><link linkend="boost.hash">boost::hash</link></computeroutput>, <computeroutput><link linkend="boost.hash_range">boost::hash_range</link></computeroutput>
+ or <computeroutput><link linkend="boost.hash_combine">boost::hash_combine</link></computeroutput> which
+ call <computeroutput>hash_value</computeroutput> without namespace qualification so that overloads
+ for custom types are found via ADL.
+ </para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Notes:</term><listitem><para>This is an extension to TR1</para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem>
+ Only throws if a user supplied version of
+ <computeroutput><link linkend="boost.hash_value">hash_value</link></computeroutput>
+ throws for an element of a container, or
+ one of the types stored in a pair.
+ </listitem></varlistentry><varlistentry><term>Returns:</term><listitem><informaltable>
+ <tgroup cols="2">
+ <thead>
+ <row>
+ <entry>Types</entry>
+ <entry>Returns</entry>
+ </row>
+ </thead>
+ <tbody>
+ <row>
+ <entry><computeroutput>bool</computeroutput>,
+ <computeroutput>char</computeroutput>, <computeroutput>signed char</computeroutput>, <computeroutput>unsigned char</computeroutput>, <computeroutput>wchar_t</computeroutput>,
+ <computeroutput>short</computeroutput>, <computeroutput>unsigned short</computeroutput>,
+ <computeroutput>int</computeroutput>, <computeroutput>unsigned int</computeroutput>, <computeroutput>long</computeroutput>, <computeroutput>unsigned long</computeroutput>
+ </entry>
+ <entry><computeroutput>val</computeroutput></entry>
+ </row>
+ <row>
+ <entry><computeroutput>long long</computeroutput>, <computeroutput>unsigned long long</computeroutput></entry>
+ <entry><computeroutput>val</computeroutput> when <computeroutput>abs(val) <= std::numeric_limits<std::size_t>::max()</computeroutput>.</entry>
+ </row>
+ <row>
+ <entry><computeroutput>float</computeroutput>, <computeroutput>double</computeroutput>, <computeroutput>long double</computeroutput></entry>
+ <entry>An unspecified value, except that equal arguments shall yield the same result.</entry>
+ </row>
+ <row>
+ <entry><computeroutput>T*</computeroutput></entry>
+ <entry>An unspecified value, except that equal arguments shall yield the same result.</entry>
+ </row>
+ <row>
+ <entry>
+ <computeroutput>T val[N]</computeroutput>,
+ <computeroutput>const T val[N]</computeroutput>
+ </entry>
+ <entry><computeroutput>hash_range(val, val+N)</computeroutput></entry>
+ </row>
+ <row>
+ <entry>
+ <computeroutput>std:basic_string<Ch, std::char_traits<Ch>, A></computeroutput>,
+ <computeroutput>std::vector<T, A></computeroutput>,
+ <computeroutput>std::list<T, A></computeroutput>,
+ <computeroutput>std::deque<T, A></computeroutput>,
+ <computeroutput>std::set<K, C, A></computeroutput>,
+ <computeroutput>std::multiset<K, C, A></computeroutput>,
+ <computeroutput>std::map<K, T, C, A></computeroutput>,
+ <computeroutput>std::multimap<K, T, C, A></computeroutput>
+ </entry>
+ <entry><computeroutput>hash_range(val.begin(), val.end())</computeroutput></entry>
+ </row>
+ <row>
+ <entry><computeroutput>std::pair<A, B></computeroutput></entry>
+ <entry><programlisting><phrase role="identifier">size_t</phrase> <phrase role="identifier">seed</phrase> <phrase role="special">=</phrase> <phrase role="number">0</phrase><phrase role="special">;</phrase>
+<link linkend="boost.hash_combine">hash_combine</link><phrase role="special">(</phrase><phrase role="identifier">seed</phrase><phrase role="special">,</phrase> <phrase role="identifier">val</phrase><phrase role="special">.</phrase><phrase role="identifier">first</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+<link linkend="boost.hash_combine">hash_combine</link><phrase role="special">(</phrase><phrase role="identifier">seed</phrase><phrase role="special">,</phrase> <phrase role="identifier">val</phrase><phrase role="special">.</phrase><phrase role="identifier">second</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="keyword">return</phrase> <phrase role="identifier">seed</phrase><phrase role="special">;</phrase></programlisting></entry>
+ </row>
+ <row>
+ <entry>
+ <computeroutput>std::complex<T></computeroutput>
+ </entry>
+ <entry>When <computeroutput>T</computeroutput> is a built in type and <computeroutput>val.imag() == 0</computeroutput>, the result is equal to <computeroutput>hash_value(val.real())</computeroutput>. Otherwise an unspecified value, except that equal arguments shall yield the same result.</entry>
+ </row>
+ </tbody>
+ </tgroup>
+ </informaltable></listitem></varlistentry></variablelist></listitem></orderedlist></refsect2><refentry xmlns:xi="http://www.w3.org/2001/XInclude" id="boost.hash"><refmeta><refentrytitle>Struct template hash</refentrytitle><manvolnum>3</manvolnum></refmeta><refnamediv><refname>boost::hash</refname><refpurpose>A <ulink url="http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2005/n1836.pdf">TR1</ulink> compliant hash function object.</refpurpose></refnamediv><refsynopsisdiv><synopsis><phrase role="comment">// In header: <<link linkend="header.boost.functional.hash_hpp">boost/functional/hash.hpp</link>>
+
+</phrase><phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> T<phrase role="special">></phrase>
+<phrase role="keyword">struct</phrase> <link linkend="boost.hash">hash</link> <phrase role="special">:</phrase> <phrase role="keyword">public</phrase> std::unary_function<T, std::size_t> <phrase role="special">{</phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <link linkend="id34-bb"><phrase role="keyword">operator</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase></link><phrase role="special">(</phrase><phrase role="identifier">T</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+<phrase role="special">}</phrase><phrase role="special">;</phrase></synopsis></refsynopsisdiv><refsect1><title>Description</title><para><literallayout class="monospaced"><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <anchor id="id34-bb"/><phrase role="keyword">operator</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">(</phrase><phrase role="identifier">T</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> val<phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>
+ <programlisting><link linkend="boost.hash_value">hash_value</link><phrase role="special">(</phrase><phrase role="identifier">val</phrase><phrase role="special">)</phrase></programlisting>
+ </para></listitem></varlistentry><varlistentry><term>Notes:</term><listitem><para>
+ The call to <computeroutput><link linkend="boost.hash_value">hash_value</link></computeroutput>
+ is unqualified, so that custom overloads can be
+ found via argument dependent lookup.
+ </para><para>
+ This is not defined when the macro <computeroutput>BOOST_HASH_NO_EXTENSIONS</computeroutput>
+ is defined. The specializations are still defined, so only the specializations
+ required by TR1 are defined.
+ </para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><para>
+ Only throws if
+ <computeroutput><link linkend="boost.hash_value">hash_value</link>(T)</computeroutput> throws.
+ </para></listitem></varlistentry></variablelist></refsect1></refentry><refentry xmlns:xi="http://www.w3.org/2001/XInclude" id="boost.hash_bool_id1"><refmeta><refentrytitle>Struct hash<bool></refentrytitle><manvolnum>3</manvolnum></refmeta><refnamediv><refname>boost::hash<bool></refname><refpurpose/></refnamediv><refsynopsisdiv><synopsis><phrase role="comment">// In header: <<link linkend="header.boost.functional.hash_hpp">boost/functional/hash.hpp</link>>
+
+</phrase>
+<phrase role="keyword">struct</phrase> <link linkend="boost.hash_bool_id1">hash</link><phrase role="special"><</phrase><phrase role="keyword">bool</phrase><phrase role="special">></phrase> <phrase role="special">{</phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <link linkend="id35-bb"><phrase role="keyword">operator</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase></link><phrase role="special">(</phrase><phrase role="keyword">bool</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+<phrase role="special">}</phrase><phrase role="special">;</phrase></synopsis></refsynopsisdiv><refsect1><title>Description</title><para><literallayout class="monospaced"><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <anchor id="id35-bb"/><phrase role="keyword">operator</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">(</phrase><phrase role="keyword">bool</phrase> val<phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>Unspecified in TR1, except that equal arguments yield the same result.</para><para><link linkend="boost.hash_value">hash_value</link>(val) in Boost.</para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><para>Doesn't throw</para></listitem></varlistentry></variablelist></refsect1></refentry><refentry xmlns:xi="http://www.w3.org/2001/XInclude" id="boost.hash_char_id1"><refmeta><refentrytitle>Struct hash<char></refentrytitle><manvolnum>3</manvolnum></refmeta><refnamediv><refname>boost::hash<char></refname><refpurpose/></refnamediv><refsynopsisdiv><synopsis><phrase role="comment">// In header: <<link linkend="header.boost.functional.hash_hpp">boost/functional/hash.hpp</link>>
+
+</phrase>
+<phrase role="keyword">struct</phrase> <link linkend="boost.hash_char_id1">hash</link><phrase role="special"><</phrase><phrase role="keyword">char</phrase><phrase role="special">></phrase> <phrase role="special">{</phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <link linkend="id36-bb"><phrase role="keyword">operator</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase></link><phrase role="special">(</phrase><phrase role="keyword">char</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+<phrase role="special">}</phrase><phrase role="special">;</phrase></synopsis></refsynopsisdiv><refsect1><title>Description</title><para><literallayout class="monospaced"><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <anchor id="id36-bb"/><phrase role="keyword">operator</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">(</phrase><phrase role="keyword">char</phrase> val<phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>Unspecified in TR1, except that equal arguments yield the same result.</para><para><link linkend="boost.hash_value">hash_value</link>(val) in Boost.</para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><para>Doesn't throw</para></listitem></varlistentry></variablelist></refsect1></refentry><refentry xmlns:xi="http://www.w3.org/2001/XInclude" id="boost.hash_signed_char_id1"><refmeta><refentrytitle>Struct hash<signed char></refentrytitle><manvolnum>3</manvolnum></refmeta><refnamediv><refname>boost::hash<signed char></refname><refpurpose/></refnamediv><refsynopsisdiv><synopsis><phrase role="comment">// In header: <<link linkend="header.boost.functional.hash_hpp">boost/functional/hash.hpp</link>>
+
+</phrase>
+<phrase role="keyword">struct</phrase> <link linkend="boost.hash_signed_char_id1">hash</link><phrase role="special"><</phrase><phrase role="keyword">signed</phrase> <phrase role="keyword">char</phrase><phrase role="special">></phrase> <phrase role="special">{</phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <link linkend="id37-bb"><phrase role="keyword">operator</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase></link><phrase role="special">(</phrase><phrase role="keyword">signed</phrase> <phrase role="keyword">char</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+<phrase role="special">}</phrase><phrase role="special">;</phrase></synopsis></refsynopsisdiv><refsect1><title>Description</title><para><literallayout class="monospaced"><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <anchor id="id37-bb"/><phrase role="keyword">operator</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">(</phrase><phrase role="keyword">signed</phrase> <phrase role="keyword">char</phrase> val<phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>Unspecified in TR1, except that equal arguments yield the same result.</para><para><link linkend="boost.hash_value">hash_value</link>(val) in Boost.</para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><para>Doesn't throw</para></listitem></varlistentry></variablelist></refsect1></refentry><refentry xmlns:xi="http://www.w3.org/2001/XInclude" id="boost.hash_unsigned_char_id1"><refmeta><refentrytitle>Struct hash<unsigned char></refentrytitle><manvolnum>3</manvolnum></refmeta><refnamediv><refname>boost::hash<unsigned char></refname><refpurpose/></refnamediv><refsynopsisdiv><synopsis><phrase role="comment">// In header: <<link linkend="header.boost.functional.hash_hpp">boost/functional/hash.hpp</link>>
+
+</phrase>
+<phrase role="keyword">struct</phrase> <link linkend="boost.hash_unsigned_char_id1">hash</link><phrase role="special"><</phrase><phrase role="keyword">unsigned</phrase> <phrase role="keyword">char</phrase><phrase role="special">></phrase> <phrase role="special">{</phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <link linkend="id38-bb"><phrase role="keyword">operator</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase></link><phrase role="special">(</phrase><phrase role="keyword">unsigned</phrase> <phrase role="keyword">char</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+<phrase role="special">}</phrase><phrase role="special">;</phrase></synopsis></refsynopsisdiv><refsect1><title>Description</title><para><literallayout class="monospaced"><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <anchor id="id38-bb"/><phrase role="keyword">operator</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">(</phrase><phrase role="keyword">unsigned</phrase> <phrase role="keyword">char</phrase> val<phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>Unspecified in TR1, except that equal arguments yield the same result.</para><para><link linkend="boost.hash_value">hash_value</link>(val) in Boost.</para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><para>Doesn't throw</para></listitem></varlistentry></variablelist></refsect1></refentry><refentry xmlns:xi="http://www.w3.org/2001/XInclude" id="boost.hash_wchar_t_id1"><refmeta><refentrytitle>Struct hash<wchar_t></refentrytitle><manvolnum>3</manvolnum></refmeta><refnamediv><refname>boost::hash<wchar_t></refname><refpurpose/></refnamediv><refsynopsisdiv><synopsis><phrase role="comment">// In header: <<link linkend="header.boost.functional.hash_hpp">boost/functional/hash.hpp</link>>
+
+</phrase>
+<phrase role="keyword">struct</phrase> <link linkend="boost.hash_wchar_t_id1">hash</link><phrase role="special"><</phrase><phrase role="keyword">wchar_t</phrase><phrase role="special">></phrase> <phrase role="special">{</phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <link linkend="id39-bb"><phrase role="keyword">operator</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase></link><phrase role="special">(</phrase><phrase role="keyword">wchar_t</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+<phrase role="special">}</phrase><phrase role="special">;</phrase></synopsis></refsynopsisdiv><refsect1><title>Description</title><para><literallayout class="monospaced"><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <anchor id="id39-bb"/><phrase role="keyword">operator</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">(</phrase><phrase role="keyword">wchar_t</phrase> val<phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>Unspecified in TR1, except that equal arguments yield the same result.</para><para><link linkend="boost.hash_value">hash_value</link>(val) in Boost.</para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><para>Doesn't throw</para></listitem></varlistentry></variablelist></refsect1></refentry><refentry xmlns:xi="http://www.w3.org/2001/XInclude" id="boost.hash_short_id1"><refmeta><refentrytitle>Struct hash<short></refentrytitle><manvolnum>3</manvolnum></refmeta><refnamediv><refname>boost::hash<short></refname><refpurpose/></refnamediv><refsynopsisdiv><synopsis><phrase role="comment">// In header: <<link linkend="header.boost.functional.hash_hpp">boost/functional/hash.hpp</link>>
+
+</phrase>
+<phrase role="keyword">struct</phrase> <link linkend="boost.hash_short_id1">hash</link><phrase role="special"><</phrase><phrase role="keyword">short</phrase><phrase role="special">></phrase> <phrase role="special">{</phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <link linkend="id40-bb"><phrase role="keyword">operator</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase></link><phrase role="special">(</phrase><phrase role="keyword">short</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+<phrase role="special">}</phrase><phrase role="special">;</phrase></synopsis></refsynopsisdiv><refsect1><title>Description</title><para><literallayout class="monospaced"><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <anchor id="id40-bb"/><phrase role="keyword">operator</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">(</phrase><phrase role="keyword">short</phrase> val<phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>Unspecified in TR1, except that equal arguments yield the same result.</para><para><link linkend="boost.hash_value">hash_value</link>(val) in Boost.</para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><para>Doesn't throw</para></listitem></varlistentry></variablelist></refsect1></refentry><refentry xmlns:xi="http://www.w3.org/2001/XInclude" id="boost.hash_unsigned_short_id1"><refmeta><refentrytitle>Struct hash<unsigned short></refentrytitle><manvolnum>3</manvolnum></refmeta><refnamediv><refname>boost::hash<unsigned short></refname><refpurpose/></refnamediv><refsynopsisdiv><synopsis><phrase role="comment">// In header: <<link linkend="header.boost.functional.hash_hpp">boost/functional/hash.hpp</link>>
+
+</phrase>
+<phrase role="keyword">struct</phrase> <link linkend="boost.hash_unsigned_short_id1">hash</link><phrase role="special"><</phrase><phrase role="keyword">unsigned</phrase> <phrase role="keyword">short</phrase><phrase role="special">></phrase> <phrase role="special">{</phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <link linkend="id41-bb"><phrase role="keyword">operator</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase></link><phrase role="special">(</phrase><phrase role="keyword">unsigned</phrase> <phrase role="keyword">short</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+<phrase role="special">}</phrase><phrase role="special">;</phrase></synopsis></refsynopsisdiv><refsect1><title>Description</title><para><literallayout class="monospaced"><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <anchor id="id41-bb"/><phrase role="keyword">operator</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">(</phrase><phrase role="keyword">unsigned</phrase> <phrase role="keyword">short</phrase> val<phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>Unspecified in TR1, except that equal arguments yield the same result.</para><para><link linkend="boost.hash_value">hash_value</link>(val) in Boost.</para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><para>Doesn't throw</para></listitem></varlistentry></variablelist></refsect1></refentry><refentry xmlns:xi="http://www.w3.org/2001/XInclude" id="boost.hash_int_id1"><refmeta><refentrytitle>Struct hash<int></refentrytitle><manvolnum>3</manvolnum></refmeta><refnamediv><refname>boost::hash<int></refname><refpurpose/></refnamediv><refsynopsisdiv><synopsis><phrase role="comment">// In header: <<link linkend="header.boost.functional.hash_hpp">boost/functional/hash.hpp</link>>
+
+</phrase>
+<phrase role="keyword">struct</phrase> <link linkend="boost.hash_int_id1">hash</link><phrase role="special"><</phrase><phrase role="keyword">int</phrase><phrase role="special">></phrase> <phrase role="special">{</phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <link linkend="id42-bb"><phrase role="keyword">operator</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase></link><phrase role="special">(</phrase><phrase role="keyword">int</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+<phrase role="special">}</phrase><phrase role="special">;</phrase></synopsis></refsynopsisdiv><refsect1><title>Description</title><para><literallayout class="monospaced"><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <anchor id="id42-bb"/><phrase role="keyword">operator</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">(</phrase><phrase role="keyword">int</phrase> val<phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>Unspecified in TR1, except that equal arguments yield the same result.</para><para><link linkend="boost.hash_value">hash_value</link>(val) in Boost.</para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><para>Doesn't throw</para></listitem></varlistentry></variablelist></refsect1></refentry><refentry xmlns:xi="http://www.w3.org/2001/XInclude" id="boost.hash_unsigned_int_id1"><refmeta><refentrytitle>Struct hash<unsigned int></refentrytitle><manvolnum>3</manvolnum></refmeta><refnamediv><refname>boost::hash<unsigned int></refname><refpurpose/></refnamediv><refsynopsisdiv><synopsis><phrase role="comment">// In header: <<link linkend="header.boost.functional.hash_hpp">boost/functional/hash.hpp</link>>
+
+</phrase>
+<phrase role="keyword">struct</phrase> <link linkend="boost.hash_unsigned_int_id1">hash</link><phrase role="special"><</phrase><phrase role="keyword">unsigned</phrase> <phrase role="keyword">int</phrase><phrase role="special">></phrase> <phrase role="special">{</phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <link linkend="id43-bb"><phrase role="keyword">operator</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase></link><phrase role="special">(</phrase><phrase role="keyword">unsigned</phrase> <phrase role="keyword">int</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+<phrase role="special">}</phrase><phrase role="special">;</phrase></synopsis></refsynopsisdiv><refsect1><title>Description</title><para><literallayout class="monospaced"><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <anchor id="id43-bb"/><phrase role="keyword">operator</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">(</phrase><phrase role="keyword">unsigned</phrase> <phrase role="keyword">int</phrase> val<phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>Unspecified in TR1, except that equal arguments yield the same result.</para><para><link linkend="boost.hash_value">hash_value</link>(val) in Boost.</para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><para>Doesn't throw</para></listitem></varlistentry></variablelist></refsect1></refentry><refentry xmlns:xi="http://www.w3.org/2001/XInclude" id="boost.hash_long_id1"><refmeta><refentrytitle>Struct hash<long></refentrytitle><manvolnum>3</manvolnum></refmeta><refnamediv><refname>boost::hash<long></refname><refpurpose/></refnamediv><refsynopsisdiv><synopsis><phrase role="comment">// In header: <<link linkend="header.boost.functional.hash_hpp">boost/functional/hash.hpp</link>>
+
+</phrase>
+<phrase role="keyword">struct</phrase> <link linkend="boost.hash_long_id1">hash</link><phrase role="special"><</phrase><phrase role="keyword">long</phrase><phrase role="special">></phrase> <phrase role="special">{</phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <link linkend="id44-bb"><phrase role="keyword">operator</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase></link><phrase role="special">(</phrase><phrase role="keyword">long</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+<phrase role="special">}</phrase><phrase role="special">;</phrase></synopsis></refsynopsisdiv><refsect1><title>Description</title><para><literallayout class="monospaced"><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <anchor id="id44-bb"/><phrase role="keyword">operator</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">(</phrase><phrase role="keyword">long</phrase> val<phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>Unspecified in TR1, except that equal arguments yield the same result.</para><para><link linkend="boost.hash_value">hash_value</link>(val) in Boost.</para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><para>Doesn't throw</para></listitem></varlistentry></variablelist></refsect1></refentry><refentry xmlns:xi="http://www.w3.org/2001/XInclude" id="boost.hash_unsigned_long_id1"><refmeta><refentrytitle>Struct hash<unsigned long></refentrytitle><manvolnum>3</manvolnum></refmeta><refnamediv><refname>boost::hash<unsigned long></refname><refpurpose/></refnamediv><refsynopsisdiv><synopsis><phrase role="comment">// In header: <<link linkend="header.boost.functional.hash_hpp">boost/functional/hash.hpp</link>>
+
+</phrase>
+<phrase role="keyword">struct</phrase> <link linkend="boost.hash_unsigned_long_id1">hash</link><phrase role="special"><</phrase><phrase role="keyword">unsigned</phrase> <phrase role="keyword">long</phrase><phrase role="special">></phrase> <phrase role="special">{</phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <link linkend="id45-bb"><phrase role="keyword">operator</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase></link><phrase role="special">(</phrase><phrase role="keyword">unsigned</phrase> <phrase role="keyword">long</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+<phrase role="special">}</phrase><phrase role="special">;</phrase></synopsis></refsynopsisdiv><refsect1><title>Description</title><para><literallayout class="monospaced"><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <anchor id="id45-bb"/><phrase role="keyword">operator</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">(</phrase><phrase role="keyword">unsigned</phrase> <phrase role="keyword">long</phrase> val<phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>Unspecified in TR1, except that equal arguments yield the same result.</para><para><link linkend="boost.hash_value">hash_value</link>(val) in Boost.</para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><para>Doesn't throw</para></listitem></varlistentry></variablelist></refsect1></refentry><refentry xmlns:xi="http://www.w3.org/2001/XInclude" id="boost.hash_long_long_id1"><refmeta><refentrytitle>Struct hash<long long></refentrytitle><manvolnum>3</manvolnum></refmeta><refnamediv><refname>boost::hash<long long></refname><refpurpose/></refnamediv><refsynopsisdiv><synopsis><phrase role="comment">// In header: <<link linkend="header.boost.functional.hash_hpp">boost/functional/hash.hpp</link>>
+
+</phrase>
+<phrase role="keyword">struct</phrase> <link linkend="boost.hash_long_long_id1">hash</link><phrase role="special"><</phrase><phrase role="keyword">long</phrase> <phrase role="keyword">long</phrase><phrase role="special">></phrase> <phrase role="special">{</phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <link linkend="id46-bb"><phrase role="keyword">operator</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase></link><phrase role="special">(</phrase><phrase role="keyword">long</phrase> <phrase role="keyword">long</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+<phrase role="special">}</phrase><phrase role="special">;</phrase></synopsis></refsynopsisdiv><refsect1><title>Description</title><para><literallayout class="monospaced"><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <anchor id="id46-bb"/><phrase role="keyword">operator</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">(</phrase><phrase role="keyword">long</phrase> <phrase role="keyword">long</phrase> val<phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>Unspecified in TR1, except that equal arguments yield the same result.</para><para><link linkend="boost.hash_value">hash_value</link>(val) in Boost.</para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><para>Doesn't throw</para></listitem></varlistentry></variablelist></refsect1></refentry><refentry xmlns:xi="http://www.w3.org/2001/XInclude" id="boost.hash_unsigned_long_long_id1"><refmeta><refentrytitle>Struct hash<unsigned long long></refentrytitle><manvolnum>3</manvolnum></refmeta><refnamediv><refname>boost::hash<unsigned long long></refname><refpurpose/></refnamediv><refsynopsisdiv><synopsis><phrase role="comment">// In header: <<link linkend="header.boost.functional.hash_hpp">boost/functional/hash.hpp</link>>
+
+</phrase>
+<phrase role="keyword">struct</phrase> <link linkend="boost.hash_unsigned_long_long_id1">hash</link><phrase role="special"><</phrase><phrase role="keyword">unsigned</phrase> <phrase role="keyword">long</phrase> <phrase role="keyword">long</phrase><phrase role="special">></phrase> <phrase role="special">{</phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <link linkend="id47-bb"><phrase role="keyword">operator</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase></link><phrase role="special">(</phrase><phrase role="keyword">unsigned</phrase> <phrase role="keyword">long</phrase> <phrase role="keyword">long</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+<phrase role="special">}</phrase><phrase role="special">;</phrase></synopsis></refsynopsisdiv><refsect1><title>Description</title><para><literallayout class="monospaced"><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <anchor id="id47-bb"/><phrase role="keyword">operator</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">(</phrase><phrase role="keyword">unsigned</phrase> <phrase role="keyword">long</phrase> <phrase role="keyword">long</phrase> val<phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>Unspecified in TR1, except that equal arguments yield the same result.</para><para><link linkend="boost.hash_value">hash_value</link>(val) in Boost.</para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><para>Doesn't throw</para></listitem></varlistentry></variablelist></refsect1></refentry><refentry xmlns:xi="http://www.w3.org/2001/XInclude" id="boost.hash_float_id1"><refmeta><refentrytitle>Struct hash<float></refentrytitle><manvolnum>3</manvolnum></refmeta><refnamediv><refname>boost::hash<float></refname><refpurpose/></refnamediv><refsynopsisdiv><synopsis><phrase role="comment">// In header: <<link linkend="header.boost.functional.hash_hpp">boost/functional/hash.hpp</link>>
+
+</phrase>
+<phrase role="keyword">struct</phrase> <link linkend="boost.hash_float_id1">hash</link><phrase role="special"><</phrase><phrase role="keyword">float</phrase><phrase role="special">></phrase> <phrase role="special">{</phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <link linkend="id48-bb"><phrase role="keyword">operator</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase></link><phrase role="special">(</phrase><phrase role="keyword">float</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+<phrase role="special">}</phrase><phrase role="special">;</phrase></synopsis></refsynopsisdiv><refsect1><title>Description</title><para><literallayout class="monospaced"><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <anchor id="id48-bb"/><phrase role="keyword">operator</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">(</phrase><phrase role="keyword">float</phrase> val<phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>Unspecified in TR1, except that equal arguments yield the same result.</para><para><link linkend="boost.hash_value">hash_value</link>(val) in Boost.</para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><para>Doesn't throw</para></listitem></varlistentry></variablelist></refsect1></refentry><refentry xmlns:xi="http://www.w3.org/2001/XInclude" id="boost.hash_double_id1"><refmeta><refentrytitle>Struct hash<double></refentrytitle><manvolnum>3</manvolnum></refmeta><refnamediv><refname>boost::hash<double></refname><refpurpose/></refnamediv><refsynopsisdiv><synopsis><phrase role="comment">// In header: <<link linkend="header.boost.functional.hash_hpp">boost/functional/hash.hpp</link>>
+
+</phrase>
+<phrase role="keyword">struct</phrase> <link linkend="boost.hash_double_id1">hash</link><phrase role="special"><</phrase><phrase role="keyword">double</phrase><phrase role="special">></phrase> <phrase role="special">{</phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <link linkend="id49-bb"><phrase role="keyword">operator</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase></link><phrase role="special">(</phrase><phrase role="keyword">double</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+<phrase role="special">}</phrase><phrase role="special">;</phrase></synopsis></refsynopsisdiv><refsect1><title>Description</title><para><literallayout class="monospaced"><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <anchor id="id49-bb"/><phrase role="keyword">operator</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">(</phrase><phrase role="keyword">double</phrase> val<phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>Unspecified in TR1, except that equal arguments yield the same result.</para><para><link linkend="boost.hash_value">hash_value</link>(val) in Boost.</para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><para>Doesn't throw</para></listitem></varlistentry></variablelist></refsect1></refentry><refentry xmlns:xi="http://www.w3.org/2001/XInclude" id="boost.hash_long_double_id1"><refmeta><refentrytitle>Struct hash<long double></refentrytitle><manvolnum>3</manvolnum></refmeta><refnamediv><refname>boost::hash<long double></refname><refpurpose/></refnamediv><refsynopsisdiv><synopsis><phrase role="comment">// In header: <<link linkend="header.boost.functional.hash_hpp">boost/functional/hash.hpp</link>>
+
+</phrase>
+<phrase role="keyword">struct</phrase> <link linkend="boost.hash_long_double_id1">hash</link><phrase role="special"><</phrase><phrase role="keyword">long</phrase> <phrase role="keyword">double</phrase><phrase role="special">></phrase> <phrase role="special">{</phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <link linkend="id50-bb"><phrase role="keyword">operator</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase></link><phrase role="special">(</phrase><phrase role="keyword">long</phrase> <phrase role="keyword">double</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+<phrase role="special">}</phrase><phrase role="special">;</phrase></synopsis></refsynopsisdiv><refsect1><title>Description</title><para><literallayout class="monospaced"><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <anchor id="id50-bb"/><phrase role="keyword">operator</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">(</phrase><phrase role="keyword">long</phrase> <phrase role="keyword">double</phrase> val<phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>Unspecified in TR1, except that equal arguments yield the same result.</para><para><link linkend="boost.hash_value">hash_value</link>(val) in Boost.</para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><para>Doesn't throw</para></listitem></varlistentry></variablelist></refsect1></refentry><refentry xmlns:xi="http://www.w3.org/2001/XInclude" id="boost.hash_std_string_id1"><refmeta><refentrytitle>Struct hash<std::string></refentrytitle><manvolnum>3</manvolnum></refmeta><refnamediv><refname>boost::hash<std::string></refname><refpurpose/></refnamediv><refsynopsisdiv><synopsis><phrase role="comment">// In header: <<link linkend="header.boost.functional.hash_hpp">boost/functional/hash.hpp</link>>
+
+</phrase>
+<phrase role="keyword">struct</phrase> <link linkend="boost.hash_std_string_id1">hash</link><phrase role="special"><</phrase><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">string</phrase><phrase role="special">></phrase> <phrase role="special">{</phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <link linkend="id51-bb"><phrase role="keyword">operator</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase></link><phrase role="special">(</phrase><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">string</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+<phrase role="special">}</phrase><phrase role="special">;</phrase></synopsis></refsynopsisdiv><refsect1><title>Description</title><para><literallayout class="monospaced"><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <anchor id="id51-bb"/><phrase role="keyword">operator</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">(</phrase><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">string</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> val<phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>Unspecified in TR1, except that equal arguments yield the same result.</para><para><link linkend="boost.hash_value">hash_value</link>(val) in Boost.</para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><para>Doesn't throw</para></listitem></varlistentry></variablelist></refsect1></refentry><refentry xmlns:xi="http://www.w3.org/2001/XInclude" id="boost.hash_std_wstring_id1"><refmeta><refentrytitle>Struct hash<std::wstring></refentrytitle><manvolnum>3</manvolnum></refmeta><refnamediv><refname>boost::hash<std::wstring></refname><refpurpose/></refnamediv><refsynopsisdiv><synopsis><phrase role="comment">// In header: <<link linkend="header.boost.functional.hash_hpp">boost/functional/hash.hpp</link>>
+
+</phrase>
+<phrase role="keyword">struct</phrase> <link linkend="boost.hash_std_wstring_id1">hash</link><phrase role="special"><</phrase><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">wstring</phrase><phrase role="special">></phrase> <phrase role="special">{</phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <link linkend="id52-bb"><phrase role="keyword">operator</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase></link><phrase role="special">(</phrase><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">wstring</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+<phrase role="special">}</phrase><phrase role="special">;</phrase></synopsis></refsynopsisdiv><refsect1><title>Description</title><para><literallayout class="monospaced"><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <anchor id="id52-bb"/><phrase role="keyword">operator</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">(</phrase><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">wstring</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> val<phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>Unspecified in TR1, except that equal arguments yield the same result.</para><para><link linkend="boost.hash_value">hash_value</link>(val) in Boost.</para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><para>Doesn't throw</para></listitem></varlistentry></variablelist></refsect1></refentry><refentry xmlns:xi="http://www.w3.org/2001/XInclude" id="boost.hash_T_id1"><refmeta><refentrytitle>Struct template hash<T*></refentrytitle><manvolnum>3</manvolnum></refmeta><refnamediv><refname>boost::hash<T*></refname><refpurpose/></refnamediv><refsynopsisdiv><synopsis><phrase role="comment">// In header: <<link linkend="header.boost.functional.hash_hpp">boost/functional/hash.hpp</link>>
+
+</phrase><phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> T<phrase role="special">></phrase>
+<phrase role="keyword">struct</phrase> <link linkend="boost.hash_T_id1">hash</link><phrase role="special"><</phrase><phrase role="identifier">T</phrase><phrase role="special">*</phrase><phrase role="special">></phrase> <phrase role="special">{</phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <link linkend="id53-bb"><phrase role="keyword">operator</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase></link><phrase role="special">(</phrase><phrase role="identifier">T</phrase><phrase role="special">*</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+<phrase role="special">}</phrase><phrase role="special">;</phrase></synopsis></refsynopsisdiv><refsect1><title>Description</title><para><literallayout class="monospaced"><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">size_t</phrase> <anchor id="id53-bb"/><phrase role="keyword">operator</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">(</phrase><phrase role="identifier">T</phrase><phrase role="special">*</phrase> val<phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>Unspecified in TR1, except that equal arguments yield the same result.</para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><para>Doesn't throw</para></listitem></varlistentry></variablelist></refsect1></refentry>
+ </section>
+</section>
\ No newline at end of file
Added: trunk/tools/boostbook/test/more/tests/libs/hash-ref.xml
==============================================================================
--- (empty file)
+++ trunk/tools/boostbook/test/more/tests/libs/hash-ref.xml 2010-08-15 12:49:10 EDT (Sun, 15 Aug 2010)
@@ -0,0 +1,810 @@
+
+<!--
+Copyright Daniel James 2005-2009
+Distributed under the Boost Software License, Version 1.0. (See accompanying
+file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
+-->
+
+<library-reference>
+ <section id="hash.reference.specification">
+ <para>For the full specification, see section 6.3 of the
+ <ulink url="http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2005/n1836.pdf">C++ Standard Library Technical Report</ulink>
+ and issue 6.18 of the
+ <ulink url="http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2005/n1837.pdf">Library Extension Technical Report Issues List</ulink> (page 63).
+ </para>
+ </section>
+ <header name="boost/functional/hash.hpp">
+ <para>
+ Defines <code><classname>boost::hash</classname></code>,
+ and helper functions.
+ </para>
+
+ <namespace name="boost">
+
+ <!--
+ boost::hash
+ -->
+
+ <struct name="hash">
+ <template>
+ <template-type-parameter name="T"/>
+ </template>
+
+ <inherit access="public">
+ <classname>std::unary_function<T, std::size_t></classname>
+ </inherit>
+
+ <purpose><simpara>A <ulink url="http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2005/n1836.pdf">TR1</ulink> compliant hash function object.</simpara></purpose>
+
+ <method name="operator()" cv="const">
+ <type>std::size_t</type>
+ <parameter name="val">
+ <paramtype>T const&</paramtype>
+ </parameter>
+ <returns><para>
+ <programlisting><functionname>hash_value</functionname>(val)</programlisting>
+ </para></returns>
+ <notes>
+ <para>
+ The call to <code><functionname>hash_value</functionname></code>
+ is unqualified, so that custom overloads can be
+ found via argument dependent lookup.
+ </para>
+ <para>
+ This is not defined when the macro <code>BOOST_HASH_NO_EXTENSIONS</code>
+ is defined. The specializations are still defined, so only the specializations
+ required by TR1 are defined.
+ </para>
+ </notes>
+ <throws><para>
+ Only throws if
+ <code><functionname>hash_value</functionname>(T)</code> throws.
+ </para></throws>
+ </method>
+ </struct>
+
+ <struct-specialization name="hash">
+ <template></template>
+ <specialization>
+ <template-arg>bool</template-arg>
+ </specialization>
+ <method name="operator()" cv="const">
+ <type>std::size_t</type>
+ <parameter name="val">
+ <paramtype>bool</paramtype>
+ </parameter>
+ <returns>
+ <para>Unspecified in TR1, except that equal arguments yield the same result.</para>
+ <para><functionname>hash_value</functionname>(val) in Boost.</para>
+ </returns>
+ <throws><para>Doesn't throw</para></throws>
+ </method>
+ </struct-specialization>
+
+ <struct-specialization name="hash">
+ <template></template>
+ <specialization>
+ <template-arg>char</template-arg>
+ </specialization>
+ <method name="operator()" cv="const">
+ <type>std::size_t</type>
+ <parameter name="val">
+ <paramtype>char</paramtype>
+ </parameter>
+ <returns>
+ <para>Unspecified in TR1, except that equal arguments yield the same result.</para>
+ <para><functionname>hash_value</functionname>(val) in Boost.</para>
+ </returns>
+ <throws><para>Doesn't throw</para></throws>
+ </method>
+ </struct-specialization>
+
+ <struct-specialization name="hash">
+ <template></template>
+ <specialization>
+ <template-arg>signed char</template-arg>
+ </specialization>
+ <method name="operator()" cv="const">
+ <type>std::size_t</type>
+ <parameter name="val">
+ <paramtype>signed char</paramtype>
+ </parameter>
+ <returns>
+ <para>Unspecified in TR1, except that equal arguments yield the same result.</para>
+ <para><functionname>hash_value</functionname>(val) in Boost.</para>
+ </returns>
+ <throws><para>Doesn't throw</para></throws>
+ </method>
+ </struct-specialization>
+
+ <struct-specialization name="hash">
+ <template></template>
+ <specialization>
+ <template-arg>unsigned char</template-arg>
+ </specialization>
+ <method name="operator()" cv="const">
+ <type>std::size_t</type>
+ <parameter name="val">
+ <paramtype>unsigned char</paramtype>
+ </parameter>
+ <returns>
+ <para>Unspecified in TR1, except that equal arguments yield the same result.</para>
+ <para><functionname>hash_value</functionname>(val) in Boost.</para>
+ </returns>
+ <throws><para>Doesn't throw</para></throws>
+ </method>
+ </struct-specialization>
+
+ <struct-specialization name="hash">
+ <template></template>
+ <specialization>
+ <template-arg>wchar_t</template-arg>
+ </specialization>
+ <method name="operator()" cv="const">
+ <type>std::size_t</type>
+ <parameter name="val">
+ <paramtype>wchar_t</paramtype>
+ </parameter>
+ <returns>
+ <para>Unspecified in TR1, except that equal arguments yield the same result.</para>
+ <para><functionname>hash_value</functionname>(val) in Boost.</para>
+ </returns>
+ <throws><para>Doesn't throw</para></throws>
+ </method>
+ </struct-specialization>
+
+ <struct-specialization name="hash">
+ <template></template>
+ <specialization>
+ <template-arg>short</template-arg>
+ </specialization>
+ <method name="operator()" cv="const">
+ <type>std::size_t</type>
+ <parameter name="val">
+ <paramtype>short</paramtype>
+ </parameter>
+ <returns>
+ <para>Unspecified in TR1, except that equal arguments yield the same result.</para>
+ <para><functionname>hash_value</functionname>(val) in Boost.</para>
+ </returns>
+ <throws><para>Doesn't throw</para></throws>
+ </method>
+ </struct-specialization>
+
+ <struct-specialization name="hash">
+ <template></template>
+ <specialization>
+ <template-arg>unsigned short</template-arg>
+ </specialization>
+ <method name="operator()" cv="const">
+ <type>std::size_t</type>
+ <parameter name="val">
+ <paramtype>unsigned short</paramtype>
+ </parameter>
+ <returns>
+ <para>Unspecified in TR1, except that equal arguments yield the same result.</para>
+ <para><functionname>hash_value</functionname>(val) in Boost.</para>
+ </returns>
+ <throws><para>Doesn't throw</para></throws>
+ </method>
+ </struct-specialization>
+
+ <struct-specialization name="hash">
+ <template></template>
+ <specialization>
+ <template-arg>int</template-arg>
+ </specialization>
+ <method name="operator()" cv="const">
+ <type>std::size_t</type>
+ <parameter name="val">
+ <paramtype>int</paramtype>
+ </parameter>
+ <returns>
+ <para>Unspecified in TR1, except that equal arguments yield the same result.</para>
+ <para><functionname>hash_value</functionname>(val) in Boost.</para>
+ </returns>
+ <throws><para>Doesn't throw</para></throws>
+ </method>
+ </struct-specialization>
+
+ <struct-specialization name="hash">
+ <template></template>
+ <specialization>
+ <template-arg>unsigned int</template-arg>
+ </specialization>
+ <method name="operator()" cv="const">
+ <type>std::size_t</type>
+ <parameter name="val">
+ <paramtype>unsigned int</paramtype>
+ </parameter>
+ <returns>
+ <para>Unspecified in TR1, except that equal arguments yield the same result.</para>
+ <para><functionname>hash_value</functionname>(val) in Boost.</para>
+ </returns>
+ <throws><para>Doesn't throw</para></throws>
+ </method>
+ </struct-specialization>
+
+ <struct-specialization name="hash">
+ <template></template>
+ <specialization>
+ <template-arg>long</template-arg>
+ </specialization>
+ <method name="operator()" cv="const">
+ <type>std::size_t</type>
+ <parameter name="val">
+ <paramtype>long</paramtype>
+ </parameter>
+ <returns>
+ <para>Unspecified in TR1, except that equal arguments yield the same result.</para>
+ <para><functionname>hash_value</functionname>(val) in Boost.</para>
+ </returns>
+ <throws><para>Doesn't throw</para></throws>
+ </method>
+ </struct-specialization>
+
+ <struct-specialization name="hash">
+ <template></template>
+ <specialization>
+ <template-arg>unsigned long</template-arg>
+ </specialization>
+ <method name="operator()" cv="const">
+ <type>std::size_t</type>
+ <parameter name="val">
+ <paramtype>unsigned long</paramtype>
+ </parameter>
+ <returns>
+ <para>Unspecified in TR1, except that equal arguments yield the same result.</para>
+ <para><functionname>hash_value</functionname>(val) in Boost.</para>
+ </returns>
+ <throws><para>Doesn't throw</para></throws>
+ </method>
+ </struct-specialization>
+
+ <struct-specialization name="hash">
+ <template></template>
+ <specialization>
+ <template-arg>long long</template-arg>
+ </specialization>
+ <method name="operator()" cv="const">
+ <type>std::size_t</type>
+ <parameter name="val">
+ <paramtype>long long</paramtype>
+ </parameter>
+ <returns>
+ <para>Unspecified in TR1, except that equal arguments yield the same result.</para>
+ <para><functionname>hash_value</functionname>(val) in Boost.</para>
+ </returns>
+ <throws><para>Doesn't throw</para></throws>
+ </method>
+ </struct-specialization>
+
+ <struct-specialization name="hash">
+ <template></template>
+ <specialization>
+ <template-arg>unsigned long long</template-arg>
+ </specialization>
+ <method name="operator()" cv="const">
+ <type>std::size_t</type>
+ <parameter name="val">
+ <paramtype>unsigned long long</paramtype>
+ </parameter>
+ <returns>
+ <para>Unspecified in TR1, except that equal arguments yield the same result.</para>
+ <para><functionname>hash_value</functionname>(val) in Boost.</para>
+ </returns>
+ <throws><para>Doesn't throw</para></throws>
+ </method>
+ </struct-specialization>
+
+ <struct-specialization name="hash">
+ <template></template>
+ <specialization>
+ <template-arg>float</template-arg>
+ </specialization>
+ <method name="operator()" cv="const">
+ <type>std::size_t</type>
+ <parameter name="val">
+ <paramtype>float</paramtype>
+ </parameter>
+ <returns>
+ <para>Unspecified in TR1, except that equal arguments yield the same result.</para>
+ <para><functionname>hash_value</functionname>(val) in Boost.</para>
+ </returns>
+ <throws><para>Doesn't throw</para></throws>
+ </method>
+ </struct-specialization>
+
+ <struct-specialization name="hash">
+ <template></template>
+ <specialization>
+ <template-arg>double</template-arg>
+ </specialization>
+ <method name="operator()" cv="const">
+ <type>std::size_t</type>
+ <parameter name="val">
+ <paramtype>double</paramtype>
+ </parameter>
+ <returns>
+ <para>Unspecified in TR1, except that equal arguments yield the same result.</para>
+ <para><functionname>hash_value</functionname>(val) in Boost.</para>
+ </returns>
+ <throws><para>Doesn't throw</para></throws>
+ </method>
+ </struct-specialization>
+
+ <struct-specialization name="hash">
+ <template></template>
+ <specialization>
+ <template-arg>long double</template-arg>
+ </specialization>
+ <method name="operator()" cv="const">
+ <type>std::size_t</type>
+ <parameter name="val">
+ <paramtype>long double</paramtype>
+ </parameter>
+ <returns>
+ <para>Unspecified in TR1, except that equal arguments yield the same result.</para>
+ <para><functionname>hash_value</functionname>(val) in Boost.</para>
+ </returns>
+ <throws><para>Doesn't throw</para></throws>
+ </method>
+ </struct-specialization>
+
+ <struct-specialization name="hash">
+ <template></template>
+ <specialization>
+ <template-arg>std::string</template-arg>
+ </specialization>
+ <method name="operator()" cv="const">
+ <type>std::size_t</type>
+ <parameter name="val">
+ <paramtype>std::string const&</paramtype>
+ </parameter>
+ <returns>
+ <para>Unspecified in TR1, except that equal arguments yield the same result.</para>
+ <para><functionname>hash_value</functionname>(val) in Boost.</para>
+ </returns>
+ <throws><para>Doesn't throw</para></throws>
+ </method>
+ </struct-specialization>
+
+ <struct-specialization name="hash">
+ <template></template>
+ <specialization>
+ <template-arg>std::wstring</template-arg>
+ </specialization>
+ <method name="operator()" cv="const">
+ <type>std::size_t</type>
+ <parameter name="val">
+ <paramtype>std::wstring const&</paramtype>
+ </parameter>
+ <returns>
+ <para>Unspecified in TR1, except that equal arguments yield the same result.</para>
+ <para><functionname>hash_value</functionname>(val) in Boost.</para>
+ </returns>
+ <throws><para>Doesn't throw</para></throws>
+ </method>
+ </struct-specialization>
+
+ <struct-specialization name="hash">
+ <template>
+ <template-type-parameter name="T"/>
+ </template>
+ <specialization>
+ <template-arg>T*</template-arg>
+ </specialization>
+ <method name="operator()" cv="const">
+ <type>std::size_t</type>
+ <parameter name="val">
+ <paramtype>T*</paramtype>
+ </parameter>
+ <returns>
+ <para>Unspecified in TR1, except that equal arguments yield the same result.</para>
+ </returns>
+ <throws><para>Doesn't throw</para></throws>
+ </method>
+ </struct-specialization>
+
+ <free-function-group name="Support functions (Boost extension).">
+
+ <!--
+ boost::hash_combine
+ -->
+
+ <function name="hash_combine">
+ <template>
+ <template-type-parameter name="T"/>
+ </template>
+ <type>void</type>
+ <parameter name="seed"><paramtype>size_t &</paramtype></parameter>
+ <parameter name="v"><paramtype>T const&</paramtype></parameter>
+ <purpose><simpara>
+ Called repeatedly to incrementally create a hash value from
+ several variables.
+ </simpara></purpose>
+ <effects><programlisting>seed ^= <functionname>hash_value</functionname>(v) + 0x9e3779b9 + (seed << 6) + (seed >> 2);</programlisting></effects>
+ <notes>
+ <para><functionname>hash_value</functionname> is called without
+ qualification, so that overloads can be found via ADL.</para>
+ <para>This is an extension to TR1</para>
+ </notes>
+ <throws>
+ Only throws if <functionname>hash_value</functionname>(T) throws.
+ Strong exception safety, as long as <functionname>hash_value</functionname>(T)
+ also has strong exception safety.
+ </throws>
+ </function>
+
+ <!--
+ boost::hash_range
+ -->
+
+ <overloaded-function name="hash_range">
+ <signature>
+ <template>
+ <template-type-parameter name="It"/>
+ </template>
+ <type>std::size_t</type>
+ <parameter name="first"><paramtype>It</paramtype></parameter>
+ <parameter name="last"><paramtype>It</paramtype></parameter>
+ </signature>
+
+ <signature>
+ <template>
+ <template-type-parameter name="It"/>
+ </template>
+ <type>void</type>
+ <parameter name="seed"><paramtype>std::size_t&</paramtype></parameter>
+ <parameter name="first"><paramtype>It</paramtype></parameter>
+ <parameter name="last"><paramtype>It</paramtype></parameter>
+ </signature>
+
+ <purpose><simpara>
+ Calculate the combined hash value of the elements of an iterator
+ range.
+ </simpara></purpose>
+ <effects>
+ <para>For the two argument overload:
+<programlisting>
+size_t seed = 0;
+
+for(; first != last; ++first)
+{
+ <functionname>hash_combine</functionname>(seed, *first);
+}
+
+return seed;
+</programlisting>
+ </para>For the three arguments overload:
+<programlisting>
+for(; first != last; ++first)
+{
+ <functionname>hash_combine</functionname>(seed, *first);
+}
+</programlisting>
+ <para>
+ </para>
+ </effects>
+ <notes>
+ <para>
+ <code>hash_range</code> is sensitive to the order of the elements
+ so it wouldn't be appropriate to use this with an unordered
+ container.
+ </para>
+ <para>This is an extension to TR1</para>
+ </notes>
+ <throws><para>
+ Only throws if <code><functionname>hash_value</functionname>(std::iterator_traits<It>::value_type)</code>
+ throws. <code>hash_range(std::size_t&, It, It)</code> has basic exception safety as long as
+ <code><functionname>hash_value</functionname>(std::iterator_traits<It>::value_type)</code>
+ has basic exception safety.
+ </para></throws>
+ </overloaded-function>
+
+ </free-function-group>
+
+ <free-function-group name="Overloadable hash implementation (Boost extension).">
+
+ <!--
+ boost::hash_value - integers
+ -->
+
+ <overloaded-function name="hash_value">
+ <purpose><simpara>
+ Implementation of the hash function.
+ </simpara></purpose>
+
+ <signature>
+ <type>std::size_t</type>
+ <parameter name="val"><paramtype>bool</paramtype></parameter>
+ </signature>
+
+ <signature>
+ <type>std::size_t</type>
+ <parameter name="val"><paramtype>char</paramtype></parameter>
+ </signature>
+
+ <signature>
+ <type>std::size_t</type>
+ <parameter name="val"><paramtype>signed char</paramtype></parameter>
+ </signature>
+
+ <signature>
+ <type>std::size_t</type>
+ <parameter name="val"><paramtype>unsigned char</paramtype></parameter>
+ </signature>
+
+ <signature>
+ <type>std::size_t</type>
+ <parameter name="val"><paramtype>wchar_t</paramtype></parameter>
+ </signature>
+
+ <signature>
+ <type>std::size_t</type>
+ <parameter name="val"><paramtype>short</paramtype></parameter>
+ </signature>
+
+ <signature>
+ <type>std::size_t</type>
+ <parameter name="val"><paramtype>unsigned short</paramtype></parameter>
+ </signature>
+
+ <signature>
+ <type>std::size_t</type>
+ <parameter name="val"><paramtype>int</paramtype></parameter>
+ </signature>
+
+ <signature>
+ <type>std::size_t</type>
+ <parameter name="val"><paramtype>unsigned int</paramtype></parameter>
+ </signature>
+
+ <signature>
+ <type>std::size_t</type>
+ <parameter name="val"><paramtype>long</paramtype></parameter>
+ </signature>
+
+ <signature>
+ <type>std::size_t</type>
+ <parameter name="val"><paramtype>unsigned long</paramtype></parameter>
+ </signature>
+
+ <signature>
+ <type>std::size_t</type>
+ <parameter name="val"><paramtype>long long</paramtype></parameter>
+ </signature>
+
+ <signature>
+ <type>std::size_t</type>
+ <parameter name="val"><paramtype>unsigned long long</paramtype></parameter>
+ </signature>
+
+ <signature>
+ <type>std::size_t</type>
+ <parameter name="val"><paramtype>float</paramtype></parameter>
+ </signature>
+
+ <signature>
+ <type>std::size_t</type>
+ <parameter name="val"><paramtype>double</paramtype></parameter>
+ </signature>
+
+ <signature>
+ <type>std::size_t</type>
+ <parameter name="val"><paramtype>long double</paramtype></parameter>
+ </signature>
+
+ <signature>
+ <template><template-type-parameter name="T"/></template>
+ <type>std::size_t</type>
+ <parameter name="val"><paramtype>T* const&</paramtype></parameter>
+ </signature>
+
+ <signature>
+ <template>
+ <template-type-parameter name="T"/>
+ <template-nontype-parameter name="N"><type>unsigned</type></template-nontype-parameter>
+ </template>
+ <type>std::size_t</type>
+ <parameter><paramtype>T (&val)[N]</paramtype></parameter>
+ </signature>
+
+ <signature>
+ <template>
+ <template-type-parameter name="T"/>
+ <template-nontype-parameter name="N"><type>unsigned</type></template-nontype-parameter>
+ </template>
+ <type>std::size_t</type>
+ <parameter><paramtype>const T (&val)[N]</paramtype></parameter>
+ </signature>
+
+ <signature>
+ <template>
+ <template-type-parameter name="Ch"/>
+ <template-type-parameter name="A"/>
+ </template>
+ <type>std::size_t</type>
+ <parameter name="val">
+ <paramtype>std::basic_string<Ch, std::char_traits<Ch>, A> const&</paramtype>
+ </parameter>
+ </signature>
+
+ <signature>
+ <template>
+ <template-type-parameter name="A"/>
+ <template-type-parameter name="B"/>
+ </template>
+ <type>std::size_t</type>
+ <parameter name="val"><paramtype>std::pair<A, B> const&</paramtype></parameter>
+ </signature>
+
+ <signature>
+ <template>
+ <template-type-parameter name="T"/>
+ <template-type-parameter name="A"/>
+ </template>
+ <type>std::size_t</type>
+ <parameter name="val"><paramtype>std::vector<T, A> const&</paramtype></parameter>
+ </signature>
+
+ <signature>
+ <template>
+ <template-type-parameter name="T"/>
+ <template-type-parameter name="A"/>
+ </template>
+ <type>std::size_t</type>
+ <parameter name="val"><paramtype>std::list<T, A> const&</paramtype></parameter>
+ </signature>
+
+ <signature>
+ <template>
+ <template-type-parameter name="T"/>
+ <template-type-parameter name="A"/>
+ </template>
+ <type>std::size_t</type>
+ <parameter name="val"><paramtype>std::deque<T, A> const&</paramtype></parameter>
+ </signature>
+
+ <signature>
+ <template>
+ <template-type-parameter name="K"/>
+ <template-type-parameter name="C"/>
+ <template-type-parameter name="A"/>
+ </template>
+ <type>std::size_t</type>
+ <parameter name="val"><paramtype>std::set<K, C, A> const&</paramtype></parameter>
+ </signature>
+
+ <signature>
+ <template>
+ <template-type-parameter name="K"/>
+ <template-type-parameter name="C"/>
+ <template-type-parameter name="A"/>
+ </template>
+ <type>std::size_t</type>
+ <parameter name="val"><paramtype>std::multiset<K, C, A> const&</paramtype></parameter>
+ </signature>
+
+ <signature>
+ <template>
+ <template-type-parameter name="K"/>
+ <template-type-parameter name="T"/>
+ <template-type-parameter name="C"/>
+ <template-type-parameter name="A"/>
+ </template>
+ <type>std::size_t</type>
+ <parameter name="val"><paramtype>std::map<K, T, C, A> const&</paramtype></parameter>
+ </signature>
+
+ <signature>
+ <template>
+ <template-type-parameter name="K"/>
+ <template-type-parameter name="T"/>
+ <template-type-parameter name="C"/>
+ <template-type-parameter name="A"/>
+ </template>
+ <type>std::size_t</type>
+ <parameter name="val"><paramtype>std::multimap<K, T, C, A> const&</paramtype></parameter>
+ </signature>
+
+ <signature>
+ <template>
+ <template-type-parameter name="T"/>
+ </template>
+ <type>std::size_t</type>
+ <parameter name="val"><paramtype>std::complex<T> const&</paramtype></parameter>
+ </signature>
+
+ <description><para>
+ Generally shouldn't be called directly by users, instead they should use
+ <classname>boost::hash</classname>, <functionname>boost::hash_range</functionname>
+ or <functionname>boost::hash_combine</functionname> which
+ call <code>hash_value</code> without namespace qualification so that overloads
+ for custom types are found via ADL.
+ </para></description>
+
+ <notes>
+ <para>This is an extension to TR1</para>
+ </notes>
+
+ <throws>
+ Only throws if a user supplied version of
+ <code><functionname>hash_value</functionname></code>
+ throws for an element of a container, or
+ one of the types stored in a pair.
+ </throws>
+
+ <returns>
+ <informaltable>
+ <tgroup cols="2">
+ <thead>
+ <row>
+ <entry>Types</entry>
+ <entry>Returns</entry>
+ </row>
+ </thead>
+ <tbody>
+ <row>
+ <entry><code>bool</code>,
+ <code>char</code>, <code>signed char</code>, <code>unsigned char</code>, <code>wchar_t</code>,
+ <code>short</code>, <code>unsigned short</code>,
+ <code>int</code>, <code>unsigned int</code>, <code>long</code>, <code>unsigned long</code>
+ </entry>
+ <entry><code>val</code></entry>
+ </row>
+ <row>
+ <entry><code>long long</code>, <code>unsigned long long</code></entry>
+ <entry><code>val</code> when <code>abs(val) <= std::numeric_limits<std::size_t>::max()</code>.</entry>
+ </row>
+ <row>
+ <entry><code>float</code>, <code>double</code>, <code>long double</code></entry>
+ <entry>An unspecified value, except that equal arguments shall yield the same result.</entry>
+ </row>
+ <row>
+ <entry><code>T*</code></entry>
+ <entry>An unspecified value, except that equal arguments shall yield the same result.</entry>
+ </row>
+ <row>
+ <entry>
+ <code>T val[N]</code>,
+ <code>const T val[N]</code>
+ </entry>
+ <entry><code>hash_range(val, val+N)</code></entry>
+ </row>
+ <row>
+ <entry>
+ <code>std:basic_string<Ch, std::char_traits<Ch>, A></code>,
+ <code>std::vector<T, A></code>,
+ <code>std::list<T, A></code>,
+ <code>std::deque<T, A></code>,
+ <code>std::set<K, C, A></code>,
+ <code>std::multiset<K, C, A></code>,
+ <code>std::map<K, T, C, A></code>,
+ <code>std::multimap<K, T, C, A></code>
+ </entry>
+ <entry><code>hash_range(val.begin(), val.end())</code></entry>
+ </row>
+ <row>
+ <entry><code>std::pair<A, B></code></entry>
+ <entry><programlisting>size_t seed = 0;
+<functionname>hash_combine</functionname>(seed, val.first);
+<functionname>hash_combine</functionname>(seed, val.second);
+return seed;</programlisting></entry>
+ </row>
+ <row>
+ <entry>
+ <code>std::complex<T></code>
+ </entry>
+ <entry>When <code>T</code> is a built in type and <code>val.imag() == 0</code>, the result is equal to <code>hash_value(val.real())</code>. Otherwise an unspecified value, except that equal arguments shall yield the same result.</entry>
+ </row>
+ </tbody>
+ </tgroup>
+ </informaltable>
+ </returns>
+ </overloaded-function>
+ </free-function-group>
+ </namespace>
+ </header>
+</library-reference>
+
Added: trunk/tools/boostbook/test/more/tests/libs/unordered-ref.gold
==============================================================================
--- (empty file)
+++ trunk/tools/boostbook/test/more/tests/libs/unordered-ref.gold 2010-08-15 12:49:10 EDT (Sun, 15 Aug 2010)
@@ -0,0 +1,1508 @@
+<!DOCTYPE section PUBLIC "-//OASIS//DTD DocBook XML V4.2//EN" "http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd">
+<section><title>Reference</title>
+ <section id="header.boost.unordered_set_hpp"><title>Header <<ulink url="../../boost/unordered_set.hpp">boost/unordered_set.hpp</ulink>></title><synopsis xmlns:xi="http://www.w3.org/2001/XInclude"><phrase role="keyword">namespace</phrase> <phrase role="identifier">boost</phrase> <phrase role="special">{</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> Value<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Hash <phrase role="special">=</phrase> <phrase role="identifier">boost</phrase><phrase role="special">::</phrase><phrase role="identifier">hash</phrase><phrase role="special"><</phrase><phrase role="identifier">Value</phrase><phrase role="special">></phrase><phrase role="special">,</phrase>
+ <phrase role="keyword">typename</phrase> Pred <phrase role="special">=</phrase> <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">equal_to</phrase><phrase role="special"><</phrase><phrase role="identifier">Value</phrase><phrase role="special">></phrase><phrase role="special">,</phrase>
+ <phrase role="keyword">typename</phrase> Alloc <phrase role="special">=</phrase> <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">allocator</phrase><phrase role="special"><</phrase><phrase role="identifier">Value</phrase><phrase role="special">></phrase> <phrase role="special">></phrase>
+ <phrase role="keyword">class</phrase> <link linkend="boost.unordered_set">unordered_set</link><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> Value<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Hash<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Pred<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Alloc<phrase role="special">></phrase>
+ <phrase role="keyword">bool</phrase> <link linkend="boost.unordered_set.operator==_id1"><phrase role="keyword">operator</phrase><phrase role="special">==</phrase></link><phrase role="special">(</phrase><phrase role="identifier">unordered_set</phrase><phrase role="special"><</phrase><phrase role="identifier">Value</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">unordered_set</phrase><phrase role="special"><</phrase><phrase role="identifier">Value</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> Value<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Hash<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Pred<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Alloc<phrase role="special">></phrase>
+ <phrase role="keyword">bool</phrase> <link linkend="boost.unordered_set.operator!=_id1"><phrase role="keyword">operator</phrase><phrase role="special">!=</phrase></link><phrase role="special">(</phrase><phrase role="identifier">unordered_set</phrase><phrase role="special"><</phrase><phrase role="identifier">Value</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">unordered_set</phrase><phrase role="special"><</phrase><phrase role="identifier">Value</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> Value<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Hash<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Pred<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Alloc<phrase role="special">></phrase>
+ <phrase role="keyword">void</phrase> <link linkend="boost.unordered_set.swap_id1"><phrase role="identifier">swap</phrase></link><phrase role="special">(</phrase><phrase role="identifier">unordered_set</phrase><phrase role="special"><</phrase><phrase role="identifier">Value</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase><phrase role="special">&</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">unordered_set</phrase><phrase role="special"><</phrase><phrase role="identifier">Value</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> Value<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Hash <phrase role="special">=</phrase> <phrase role="identifier">boost</phrase><phrase role="special">::</phrase><phrase role="identifier">hash</phrase><phrase role="special"><</phrase><phrase role="identifier">Value</phrase><phrase role="special">></phrase><phrase role="special">,</phrase>
+ <phrase role="keyword">typename</phrase> Pred <phrase role="special">=</phrase> <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">equal_to</phrase><phrase role="special"><</phrase><phrase role="identifier">Value</phrase><phrase role="special">></phrase><phrase role="special">,</phrase>
+ <phrase role="keyword">typename</phrase> Alloc <phrase role="special">=</phrase> <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">allocator</phrase><phrase role="special"><</phrase><phrase role="identifier">Value</phrase><phrase role="special">></phrase> <phrase role="special">></phrase>
+ <phrase role="keyword">class</phrase> <link linkend="boost.unordered_multiset">unordered_multiset</link><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> Value<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Hash<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Pred<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Alloc<phrase role="special">></phrase>
+ <phrase role="keyword">bool</phrase> <link linkend="boost.unordered_multiset.operator==_id1"><phrase role="keyword">operator</phrase><phrase role="special">==</phrase></link><phrase role="special">(</phrase><phrase role="identifier">unordered_multiset</phrase><phrase role="special"><</phrase><phrase role="identifier">Value</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">unordered_multiset</phrase><phrase role="special"><</phrase><phrase role="identifier">Value</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> Value<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Hash<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Pred<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Alloc<phrase role="special">></phrase>
+ <phrase role="keyword">bool</phrase> <link linkend="boost.unordered_multiset.operator!=_id1"><phrase role="keyword">operator</phrase><phrase role="special">!=</phrase></link><phrase role="special">(</phrase><phrase role="identifier">unordered_multiset</phrase><phrase role="special"><</phrase><phrase role="identifier">Value</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">unordered_multiset</phrase><phrase role="special"><</phrase><phrase role="identifier">Value</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> Value<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Hash<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Pred<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Alloc<phrase role="special">></phrase>
+ <phrase role="keyword">void</phrase> <link linkend="boost.unordered_multiset.swap_id1"><phrase role="identifier">swap</phrase></link><phrase role="special">(</phrase><phrase role="identifier">unordered_multiset</phrase><phrase role="special"><</phrase><phrase role="identifier">Value</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase><phrase role="special">&</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">unordered_multiset</phrase><phrase role="special"><</phrase><phrase role="identifier">Value</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="special">}</phrase></synopsis>
+ <refentry xmlns:xi="http://www.w3.org/2001/XInclude" id="boost.unordered_set"><refmeta><refentrytitle>Class template unordered_set</refentrytitle><manvolnum>3</manvolnum></refmeta><refnamediv><refname>boost::unordered_set</refname><refpurpose>
+ An unordered associative container that stores unique values.
+ </refpurpose></refnamediv><refsynopsisdiv><synopsis><phrase role="comment">// In header: <<link linkend="header.boost.unordered_set_hpp">boost/unordered_set.hpp</link>>
+
+</phrase><phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> Value<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Hash <phrase role="special">=</phrase> <phrase role="identifier">boost</phrase><phrase role="special">::</phrase><phrase role="identifier">hash</phrase><phrase role="special"><</phrase><phrase role="identifier">Value</phrase><phrase role="special">></phrase><phrase role="special">,</phrase>
+ <phrase role="keyword">typename</phrase> Pred <phrase role="special">=</phrase> <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">equal_to</phrase><phrase role="special"><</phrase><phrase role="identifier">Value</phrase><phrase role="special">></phrase><phrase role="special">,</phrase>
+ <phrase role="keyword">typename</phrase> Alloc <phrase role="special">=</phrase> <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">allocator</phrase><phrase role="special"><</phrase><phrase role="identifier">Value</phrase><phrase role="special">></phrase> <phrase role="special">></phrase>
+<phrase role="keyword">class</phrase> <link linkend="boost.unordered_set">unordered_set</link> <phrase role="special">{</phrase>
+<phrase role="keyword">public</phrase><phrase role="special">:</phrase>
+ <phrase role="comment">// <link linkend="boost.unordered_settypes">types</link></phrase>
+ <phrase role="keyword">typedef</phrase> <phrase role="identifier">Value</phrase> <anchor id="boost.unordered_set.key_type"/><phrase role="identifier">key_type</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">typedef</phrase> <phrase role="identifier">Value</phrase> <anchor id="boost.unordered_set.value_type"/><phrase role="identifier">value_type</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">typedef</phrase> <phrase role="identifier">Hash</phrase> <anchor id="boost.unordered_set.hasher"/><phrase role="identifier">hasher</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">typedef</phrase> <phrase role="identifier">Pred</phrase> <anchor id="boost.unordered_set.key_equal"/><phrase role="identifier">key_equal</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">typedef</phrase> <phrase role="identifier">Alloc</phrase> <anchor id="boost.unordered_set.allocator_type"/><phrase role="identifier">allocator_type</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">typedef</phrase> <phrase role="keyword">typename</phrase> <phrase role="identifier">allocator_type</phrase><phrase role="special">::</phrase><phrase role="identifier">pointer</phrase> <anchor id="boost.unordered_set.pointer"/><phrase role="identifier">pointer</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">typedef</phrase> <phrase role="keyword">typename</phrase> <phrase role="identifier">allocator_type</phrase><phrase role="special">::</phrase><phrase role="identifier">const_pointer</phrase> <anchor id="boost.unordered_set.const_pointer"/><phrase role="identifier">const_pointer</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">typedef</phrase> <phrase role="keyword">typename</phrase> <phrase role="identifier">allocator_type</phrase><phrase role="special">::</phrase><phrase role="identifier">reference</phrase> <anchor id="boost.unordered_set.reference"/><phrase role="identifier">reference</phrase><phrase role="special">;</phrase> <phrase role="comment">// lvalue of value_type.</phrase>
+ <phrase role="keyword">typedef</phrase> <phrase role="keyword">typename</phrase> <phrase role="identifier">allocator_type</phrase><phrase role="special">::</phrase><phrase role="identifier">const_reference</phrase> <anchor id="boost.unordered_set.const_reference"/><phrase role="identifier">const_reference</phrase><phrase role="special">;</phrase> <phrase role="comment">// const lvalue of value_type.</phrase>
+ <phrase role="keyword">typedef</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis> <link linkend="boost.unordered_set.size_type"><phrase role="identifier">size_type</phrase></link><phrase role="special">;</phrase>
+ <phrase role="keyword">typedef</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis> <link linkend="boost.unordered_set.difference_type"><phrase role="identifier">difference_type</phrase></link><phrase role="special">;</phrase>
+ <phrase role="keyword">typedef</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis> <link linkend="boost.unordered_set.iterator"><phrase role="identifier">iterator</phrase></link><phrase role="special">;</phrase>
+ <phrase role="keyword">typedef</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis> <link linkend="boost.unordered_set.const_iterator"><phrase role="identifier">const_iterator</phrase></link><phrase role="special">;</phrase>
+ <phrase role="keyword">typedef</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis> <link linkend="boost.unordered_set.local_iterator"><phrase role="identifier">local_iterator</phrase></link><phrase role="special">;</phrase>
+ <phrase role="keyword">typedef</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis> <link linkend="boost.unordered_set.const_local_iterator"><phrase role="identifier">const_local_iterator</phrase></link><phrase role="special">;</phrase>
+
+ <phrase role="comment">// <link linkend="boost.unordered_setconstruct-copy-destruct">construct/copy/destruct</link></phrase>
+ <phrase role="keyword">explicit</phrase> <link linkend="id1-bb"><phrase role="identifier">unordered_set</phrase></link><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase> <phrase role="special">=</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis><phrase role="special">,</phrase>
+ <phrase role="identifier">hasher</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> <phrase role="special">=</phrase> <phrase role="identifier">hasher</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">key_equal</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> <phrase role="special">=</phrase> <phrase role="identifier">key_equal</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">allocator_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> <phrase role="special">=</phrase> <phrase role="identifier">allocator_type</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> InputIterator<phrase role="special">></phrase>
+ <link linkend="id2-bb"><phrase role="identifier">unordered_set</phrase></link><phrase role="special">(</phrase><phrase role="identifier">InputIterator</phrase><phrase role="special">,</phrase> <phrase role="identifier">InputIterator</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">size_type</phrase> <phrase role="special">=</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis><phrase role="special">,</phrase>
+ <phrase role="identifier">hasher</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> <phrase role="special">=</phrase> <phrase role="identifier">hasher</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">,</phrase> <phrase role="identifier">key_equal</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> <phrase role="special">=</phrase> <phrase role="identifier">key_equal</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">allocator_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> <phrase role="special">=</phrase> <phrase role="identifier">allocator_type</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <link linkend="id3-bb"><phrase role="identifier">unordered_set</phrase></link><phrase role="special">(</phrase><phrase role="identifier">unordered_set</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <link linkend="id4-bb"><phrase role="identifier">unordered_set</phrase></link><phrase role="special">(</phrase><phrase role="identifier">unordered_set</phrase> <phrase role="special">&&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">explicit</phrase> <link linkend="id5-bb"><phrase role="identifier">unordered_set</phrase></link><phrase role="special">(</phrase><phrase role="identifier">Allocator</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <link linkend="id6-bb"><phrase role="identifier">unordered_set</phrase></link><phrase role="special">(</phrase><phrase role="identifier">unordered_set</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">,</phrase> <phrase role="identifier">Allocator</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <link linkend="id7-bb"><phrase role="special">~</phrase><phrase role="identifier">unordered_set</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">unordered_set</phrase><phrase role="special">&</phrase> <link linkend="id8-bb"><phrase role="keyword">operator</phrase><phrase role="special">=</phrase></link><phrase role="special">(</phrase><phrase role="identifier">unordered_set</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">unordered_set</phrase><phrase role="special">&</phrase> <link linkend="id9-bb"><phrase role="keyword">operator</phrase><phrase role="special">=</phrase></link><phrase role="special">(</phrase><phrase role="identifier">unordered_set</phrase> <phrase role="special">&&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">allocator_type</phrase> <link linkend="id10-bb"><phrase role="identifier">get_allocator</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+
+ <phrase role="comment">// <link linkend="id11-bb">size and capacity</link></phrase>
+ <phrase role="keyword">bool</phrase> <link linkend="id12-bb"><phrase role="identifier">empty</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">size_type</phrase> <link linkend="id13-bb"><phrase role="identifier">size</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">size_type</phrase> <link linkend="id14-bb"><phrase role="identifier">max_size</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+
+ <phrase role="comment">// <link linkend="id15-bb">iterators</link></phrase>
+ <phrase role="identifier">iterator</phrase> <link linkend="id17-bb"><phrase role="identifier">begin</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">const_iterator</phrase> <link linkend="id18-bb"><phrase role="identifier">begin</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">iterator</phrase> <link linkend="id20-bb"><phrase role="identifier">end</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">const_iterator</phrase> <link linkend="id21-bb"><phrase role="identifier">end</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">const_iterator</phrase> <link linkend="id22-bb"><phrase role="identifier">cbegin</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">const_iterator</phrase> <link linkend="id23-bb"><phrase role="identifier">cend</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+
+ <phrase role="comment">// <link linkend="id24-bb">modifiers</link></phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase><phrase role="special">...</phrase> Args<phrase role="special">></phrase> <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">pair</phrase><phrase role="special"><</phrase><phrase role="identifier">iterator</phrase><phrase role="special">,</phrase> <phrase role="keyword">bool</phrase><phrase role="special">></phrase> <link linkend="id25-bb"><phrase role="identifier">emplace</phrase></link><phrase role="special">(</phrase><phrase role="identifier">Args</phrase><phrase role="special">&&</phrase><phrase role="special">...</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase><phrase role="special">...</phrase> Args<phrase role="special">></phrase> <phrase role="identifier">iterator</phrase> <link linkend="id26-bb"><phrase role="identifier">emplace_hint</phrase></link><phrase role="special">(</phrase><phrase role="identifier">const_iterator</phrase><phrase role="special">,</phrase> <phrase role="identifier">Args</phrase><phrase role="special">&&</phrase><phrase role="special">...</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">pair</phrase><phrase role="special"><</phrase><phrase role="identifier">iterator</phrase><phrase role="special">,</phrase> <phrase role="keyword">bool</phrase><phrase role="special">></phrase> <link linkend="id27-bb"><phrase role="identifier">insert</phrase></link><phrase role="special">(</phrase><phrase role="identifier">value_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">iterator</phrase> <link linkend="id28-bb"><phrase role="identifier">insert</phrase></link><phrase role="special">(</phrase><phrase role="identifier">const_iterator</phrase><phrase role="special">,</phrase> <phrase role="identifier">value_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> InputIterator<phrase role="special">></phrase> <phrase role="keyword">void</phrase> <link linkend="id29-bb"><phrase role="identifier">insert</phrase></link><phrase role="special">(</phrase><phrase role="identifier">InputIterator</phrase><phrase role="special">,</phrase> <phrase role="identifier">InputIterator</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">iterator</phrase> <link linkend="id30-bb"><phrase role="identifier">erase</phrase></link><phrase role="special">(</phrase><phrase role="identifier">const_iterator</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">size_type</phrase> <link linkend="id31-bb"><phrase role="identifier">erase</phrase></link><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">iterator</phrase> <link linkend="id32-bb"><phrase role="identifier">erase</phrase></link><phrase role="special">(</phrase><phrase role="identifier">const_iterator</phrase><phrase role="special">,</phrase> <phrase role="identifier">const_iterator</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">void</phrase> <link linkend="id33-bb"><phrase role="identifier">quick_erase</phrase></link><phrase role="special">(</phrase><phrase role="identifier">const_iterator</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">void</phrase> <link linkend="id34-bb"><phrase role="identifier">erase_return_void</phrase></link><phrase role="special">(</phrase><phrase role="identifier">const_iterator</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">void</phrase> <link linkend="id35-bb"><phrase role="identifier">clear</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">void</phrase> <link linkend="id36-bb"><phrase role="identifier">swap</phrase></link><phrase role="special">(</phrase><phrase role="identifier">unordered_set</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+
+ <phrase role="comment">// <link linkend="id37-bb">observers</link></phrase>
+ <phrase role="identifier">hasher</phrase> <link linkend="id38-bb"><phrase role="identifier">hash_function</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">key_equal</phrase> <link linkend="id39-bb"><phrase role="identifier">key_eq</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+
+ <phrase role="comment">// <link linkend="id40-bb">lookup</link></phrase>
+ <phrase role="identifier">iterator</phrase> <link linkend="id42-bb"><phrase role="identifier">find</phrase></link><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">const_iterator</phrase> <link linkend="id43-bb"><phrase role="identifier">find</phrase></link><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> CompatibleKey<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> CompatibleHash<phrase role="special">,</phrase>
+ <phrase role="keyword">typename</phrase> CompatiblePredicate<phrase role="special">></phrase>
+ <phrase role="identifier">iterator</phrase> <link linkend="id44-bb"><phrase role="identifier">find</phrase></link><phrase role="special">(</phrase><phrase role="identifier">CompatibleKey</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">,</phrase> <phrase role="identifier">CompatibleHash</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">CompatiblePredicate</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> CompatibleKey<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> CompatibleHash<phrase role="special">,</phrase>
+ <phrase role="keyword">typename</phrase> CompatiblePredicate<phrase role="special">></phrase>
+ <phrase role="identifier">const_iterator</phrase>
+ <link linkend="id45-bb"><phrase role="identifier">find</phrase></link><phrase role="special">(</phrase><phrase role="identifier">CompatibleKey</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">,</phrase> <phrase role="identifier">CompatibleHash</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">CompatiblePredicate</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">size_type</phrase> <link linkend="id46-bb"><phrase role="identifier">count</phrase></link><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">pair</phrase><phrase role="special"><</phrase><phrase role="identifier">iterator</phrase><phrase role="special">,</phrase> <phrase role="identifier">iterator</phrase><phrase role="special">></phrase> <link linkend="id48-bb"><phrase role="identifier">equal_range</phrase></link><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">pair</phrase><phrase role="special"><</phrase><phrase role="identifier">const_iterator</phrase><phrase role="special">,</phrase> <phrase role="identifier">const_iterator</phrase><phrase role="special">></phrase> <link linkend="id49-bb"><phrase role="identifier">equal_range</phrase></link><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+
+ <phrase role="comment">// <link linkend="id50-bb">bucket interface</link></phrase>
+ <phrase role="identifier">size_type</phrase> <link linkend="id51-bb"><phrase role="identifier">bucket_count</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">size_type</phrase> <link linkend="id52-bb"><phrase role="identifier">max_bucket_count</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">size_type</phrase> <link linkend="id53-bb"><phrase role="identifier">bucket_size</phrase></link><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">size_type</phrase> <link linkend="id54-bb"><phrase role="identifier">bucket</phrase></link><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">local_iterator</phrase> <link linkend="id56-bb"><phrase role="identifier">begin</phrase></link><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">const_local_iterator</phrase> <link linkend="id57-bb"><phrase role="identifier">begin</phrase></link><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">local_iterator</phrase> <link linkend="id59-bb"><phrase role="identifier">end</phrase></link><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">const_local_iterator</phrase> <link linkend="id60-bb"><phrase role="identifier">end</phrase></link><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">const_local_iterator</phrase> <link linkend="id61-bb"><phrase role="identifier">cbegin</phrase></link><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">const_local_iterator</phrase> <link linkend="id62-bb"><phrase role="identifier">cend</phrase></link><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+
+ <phrase role="comment">// <link linkend="id63-bb">hash policy</link></phrase>
+ <phrase role="keyword">float</phrase> <link linkend="id64-bb"><phrase role="identifier">load_factor</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">float</phrase> <link linkend="id65-bb"><phrase role="identifier">max_load_factor</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">void</phrase> <link linkend="id66-bb"><phrase role="identifier">max_load_factor</phrase></link><phrase role="special">(</phrase><phrase role="keyword">float</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">void</phrase> <link linkend="id67-bb"><phrase role="identifier">rehash</phrase></link><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="special">}</phrase><phrase role="special">;</phrase>
+
+<phrase role="comment">// <link linkend="id68-bb">Equality Comparisons</link></phrase>
+<phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> Value<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Hash<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Pred<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Alloc<phrase role="special">></phrase>
+ <phrase role="keyword">bool</phrase> <link linkend="boost.unordered_set.operator==_id1"><phrase role="keyword">operator</phrase><phrase role="special">==</phrase></link><phrase role="special">(</phrase><phrase role="identifier">unordered_set</phrase><phrase role="special"><</phrase><phrase role="identifier">Value</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">unordered_set</phrase><phrase role="special"><</phrase><phrase role="identifier">Value</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> Value<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Hash<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Pred<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Alloc<phrase role="special">></phrase>
+ <phrase role="keyword">bool</phrase> <link linkend="boost.unordered_set.operator!=_id1"><phrase role="keyword">operator</phrase><phrase role="special">!=</phrase></link><phrase role="special">(</phrase><phrase role="identifier">unordered_set</phrase><phrase role="special"><</phrase><phrase role="identifier">Value</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">unordered_set</phrase><phrase role="special"><</phrase><phrase role="identifier">Value</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+
+<phrase role="comment">// <link linkend="id69-bb">swap</link></phrase>
+<phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> Value<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Hash<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Pred<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Alloc<phrase role="special">></phrase>
+ <phrase role="keyword">void</phrase> <link linkend="boost.unordered_set.swap_id1"><phrase role="identifier">swap</phrase></link><phrase role="special">(</phrase><phrase role="identifier">unordered_set</phrase><phrase role="special"><</phrase><phrase role="identifier">Value</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase><phrase role="special">&</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">unordered_set</phrase><phrase role="special"><</phrase><phrase role="identifier">Value</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase></synopsis></refsynopsisdiv><refsect1><title>Description</title>
+ <para>Based on chapter 23 of
+ <ulink url="http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2009/n2960.pdf">the working draft of the C++ standard [n2960]</ulink>.
+ But without the updated rules for allocators.
+ </para>
+ <para><emphasis role="bold">Template Parameters</emphasis>
+ <informaltable>
+ <tgroup cols="2">
+ <tbody>
+ <row>
+ <entry><emphasis>Value</emphasis></entry>
+ <entry>Value must be Assignable and CopyConstructible</entry></row>
+ <row>
+ <entry><emphasis>Hash</emphasis></entry>
+ <entry>A unary function object type that acts a hash function for a <computeroutput>Value</computeroutput>. It takes a single argument of type <computeroutput>Value</computeroutput> and returns a value of type std::size_t.</entry></row>
+ <row>
+ <entry><emphasis>Pred</emphasis></entry>
+ <entry>A binary function object that implements an equivalence relation on values of type <computeroutput>Value</computeroutput>.
+ A binary function object that induces an equivalence relation on values of type Key.
+ It takes two arguments of type Key and returns a value of type bool.</entry></row>
+ <row>
+ <entry><emphasis>Alloc</emphasis></entry>
+ <entry>An allocator whose value type is the same as the container's value type.</entry></row></tbody></tgroup></informaltable></para>
+ <para>The elements are organized into buckets. Keys with the same hash code are stored in the same bucket.</para>
+ <para>The number of buckets can be automatically increased by a call to insert, or as the result of calling rehash.</para>
+ <refsect2><title><anchor id="boost.unordered_settypes"/><computeroutput>unordered_set</computeroutput>
+ public
+ types</title><orderedlist><listitem><para>
+<phrase role="keyword">typedef</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis> <anchor id="boost.unordered_set.size_type"/><phrase role="identifier">size_type</phrase><phrase role="special">;</phrase></para>
+ <para>An unsigned integral type.</para>
+ <para>size_type can represent any non-negative value of difference_type.</para>
+ </listitem><listitem><para>
+<phrase role="keyword">typedef</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis> <anchor id="boost.unordered_set.difference_type"/><phrase role="identifier">difference_type</phrase><phrase role="special">;</phrase></para>
+ <para>A signed integral type.</para>
+ <para>Is identical to the difference type of iterator and const_iterator.</para>
+ </listitem><listitem><para>
+<phrase role="keyword">typedef</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis> <anchor id="boost.unordered_set.iterator"/><phrase role="identifier">iterator</phrase><phrase role="special">;</phrase></para>
+ <para>A constant iterator whose value type is value_type. </para>
+ <para>The iterator category is at least a forward iterator.</para>
+ <para>Convertible to const_iterator.</para>
+ </listitem><listitem><para>
+<phrase role="keyword">typedef</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis> <anchor id="boost.unordered_set.const_iterator"/><phrase role="identifier">const_iterator</phrase><phrase role="special">;</phrase></para>
+ <para>A constant iterator whose value type is value_type. </para>
+ <para>The iterator category is at least a forward iterator.</para>
+ </listitem><listitem><para>
+<phrase role="keyword">typedef</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis> <anchor id="boost.unordered_set.local_iterator"/><phrase role="identifier">local_iterator</phrase><phrase role="special">;</phrase></para>
+ <para>An iterator with the same value type, difference type and pointer and reference type as iterator.</para>
+ <para>A local_iterator object can be used to iterate through a single bucket.</para>
+ </listitem><listitem><para>
+<phrase role="keyword">typedef</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis> <anchor id="boost.unordered_set.const_local_iterator"/><phrase role="identifier">const_local_iterator</phrase><phrase role="special">;</phrase></para>
+ <para>A constant iterator with the same value type, difference type and pointer and reference type as const_iterator.</para>
+ <para>A const_local_iterator object can be used to iterate through a single bucket.</para>
+ </listitem></orderedlist></refsect2><refsect2><title><anchor id="boost.unordered_setconstruct-copy-destruct"/><computeroutput>unordered_set</computeroutput>
+ public
+ construct/copy/destruct</title><orderedlist><listitem><para><literallayout class="monospaced"><phrase role="keyword">explicit</phrase> <anchor id="id1-bb"/><phrase role="identifier">unordered_set</phrase><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase> n <phrase role="special">=</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis><phrase role="special">,</phrase>
+ <phrase role="identifier">hasher</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> hf <phrase role="special">=</phrase> <phrase role="identifier">hasher</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">key_equal</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> eq <phrase role="special">=</phrase> <phrase role="identifier">key_equal</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">allocator_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> a <phrase role="special">=</phrase> <phrase role="identifier">allocator_type</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Constructs an empty container with at least n buckets, using hf as the hash function, eq as the key equality predicate, a as the allocator and a maximum load factor of 1.0.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Postconditions:</term><listitem><computeroutput><link linkend="id13-bb">size</link>() == 0</computeroutput></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> InputIterator<phrase role="special">></phrase>
+ <anchor id="id2-bb"/><phrase role="identifier">unordered_set</phrase><phrase role="special">(</phrase><phrase role="identifier">InputIterator</phrase> f<phrase role="special">,</phrase> <phrase role="identifier">InputIterator</phrase> l<phrase role="special">,</phrase>
+ <phrase role="identifier">size_type</phrase> n <phrase role="special">=</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis><phrase role="special">,</phrase>
+ <phrase role="identifier">hasher</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> hf <phrase role="special">=</phrase> <phrase role="identifier">hasher</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">key_equal</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> eq <phrase role="special">=</phrase> <phrase role="identifier">key_equal</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">allocator_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> a <phrase role="special">=</phrase> <phrase role="identifier">allocator_type</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Constructs an empty container with at least n buckets, using hf as the hash function, eq as the key equality predicate, a as the allocator and a maximum load factor of 1.0 and inserts the elements from [f, l) into it.</para></listitem><listitem><para><literallayout class="monospaced"><anchor id="id3-bb"/><phrase role="identifier">unordered_set</phrase><phrase role="special">(</phrase><phrase role="identifier">unordered_set</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>The copy constructor. Copies t
he contained elements, hash function, predicate, maximum load factor and allocator.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Requires:</term><listitem><para><computeroutput>value_type</computeroutput> is copy constructible</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><anchor id="id4-bb"/><phrase role="identifier">unordered_set</phrase><phrase role="special">(</phrase><phrase role="identifier">unordered_set</phrase> <phrase role="special">&&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>The move constructor.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Notes:</term><listitem><para>This is emulated on compilers without rvalue references.</para></listitem></varlistentry><varlistentry><term>Requires:</term><listitem><para>
+ <computeroutput>value_type</computeroutput> is move constructible.
+ (TODO: This is not actually required in this implementation).
+ </para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="keyword">explicit</phrase> <anchor id="id5-bb"/><phrase role="identifier">unordered_set</phrase><phrase role="special">(</phrase><phrase role="identifier">Allocator</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> a<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Constructs an empty container, using allocator <computeroutput>a</computeroutput>.</para></listitem><listitem><para><literallayout class="monospaced"><anchor id="id6-bb"/><phrase role="identifier">unordered_set</phrase><phrase role="special">(</phrase><phrase role="identifier">unordered_set</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> x<phrase role="special">,</phrase> <phrase role="identifier">Allocator</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> a<phrase
role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Constructs an container, copying <computeroutput>x</computeroutput>'s contained elements, hash function, predicate, maximum load factor, but using allocator <computeroutput>a</computeroutput>.</para></listitem><listitem><para><literallayout class="monospaced"><anchor id="id7-bb"/><phrase role="special">~</phrase><phrase role="identifier">unordered_set</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Notes:</term><listitem><para>The destructor is applied to every element, and all memory is deallocated</para></listitem></varlistentry></variablelist></listitem></orderedlist></refsect2><para><literallayout class="monospaced"><phrase role="identifier">unordered_set</phrase><phrase role="special">&</phrase> <anchor id="id8-bb"/><phrase role="keyword">operator</phrase><phrase role="special">=</phrase><phrase role="special">(</phrase><phrase role="identifier">unordered_set</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>The assignment operator. Copies the contained elements, hash function, predicate and maximum load factor but not the allocator.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Notes:</term><listitem><para>
+ On compilers without rvalue references, there is a single assignment
+ operator with the signature <computeroutput>operator=(unordered_set)</computeroutput>
+ in order to emulate move semantics.
+ </para></listitem></varlistentry><varlistentry><term>Requires:</term><listitem><para><computeroutput>value_type</computeroutput> is copy constructible</para></listitem></varlistentry></variablelist><para><literallayout class="monospaced"><phrase role="identifier">unordered_set</phrase><phrase role="special">&</phrase> <anchor id="id9-bb"/><phrase role="keyword">operator</phrase><phrase role="special">=</phrase><phrase role="special">(</phrase><phrase role="identifier">unordered_set</phrase> <phrase role="special">&&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>The move assignment operator.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Notes:</term><listitem><para>
+ On compilers without rvalue references, there is a single assignment
+ operator with the signature <computeroutput>operator=(unordered_set)</computeroutput>
+ in order to emulate move semantics.
+ </para></listitem></varlistentry><varlistentry><term>Requires:</term><listitem><para>
+ <computeroutput>value_type</computeroutput> is move constructible.
+ (TODO: This is not actually required in this implementation).
+ </para></listitem></varlistentry></variablelist><para><literallayout class="monospaced"><phrase role="identifier">allocator_type</phrase> <anchor id="id10-bb"/><phrase role="identifier">get_allocator</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><refsect2><title><anchor id="id11-bb"/><computeroutput>unordered_set</computeroutput> size and capacity</title><orderedlist><listitem><para><literallayout class="monospaced"><phrase role="keyword">bool</phrase> <anchor id="id12-bb"/><phrase role="identifier">empty</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><computeroutput><link linkend="id13-bb">size</link>() == 0</computeroutput></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">size_type</phrase> <anchor id="id13-bb"/><phrase role="identifier">size</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><computeroutput>std::distance(<link linkend="id16-bb">begin</link>(), <link linkend="id19-bb">end</link>())</computeroutput></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">size_type</phrase> <anchor id="id14-bb"/><phrase role="identifier">max_size</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><computeroutput><link linkend="id13-bb">size</link>()</computeroutput> of the largest possible container.
+ </listitem></varlistentry></variablelist></listitem></orderedlist></refsect2><refsect2><title><anchor id="id15-bb"/><computeroutput>unordered_set</computeroutput> iterators</title><orderedlist><listitem><para><literallayout class="monospaced"><anchor id="id16-bb"/><phrase role="identifier">iterator</phrase> <anchor id="id17-bb"/><phrase role="identifier">begin</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="identifier">const_iterator</phrase> <anchor id="id18-bb"/><phrase role="identifier">begin</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem>An iterator referring to the first element of the container, or if the container is empty the past-the-end value for the container.
+ </listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><anchor id="id19-bb"/><phrase role="identifier">iterator</phrase> <anchor id="id20-bb"/><phrase role="identifier">end</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="identifier">const_iterator</phrase> <anchor id="id21-bb"/><phrase role="identifier">end</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem>An iterator which refers to the past-the-end value for the container.
+ </listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">const_iterator</phrase> <anchor id="id22-bb"/><phrase role="identifier">cbegin</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem>A constant iterator referring to the first element of the container, or if the container is empty the past-the-end value for the container.
+ </listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">const_iterator</phrase> <anchor id="id23-bb"/><phrase role="identifier">cend</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem>A constant iterator which refers to the past-the-end value for the container.
+ </listitem></varlistentry></variablelist></listitem></orderedlist></refsect2><refsect2><title><anchor id="id24-bb"/><computeroutput>unordered_set</computeroutput> modifiers</title><orderedlist><listitem><para><literallayout class="monospaced"><phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase><phrase role="special">...</phrase> Args<phrase role="special">></phrase> <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">pair</phrase><phrase role="special"><</phrase><phrase role="identifier">iterator</phrase><phrase role="special">,</phrase> <phrase role="keyword">bool</phrase><phrase role="special">></phrase> <anchor id="id25-bb"/><phrase role="identifier">emplace</phrase><phrase role="special">(</phrase><phrase role="identifier">Args</phrase><phrase role="special">&&</phrase><phrase role="special">...</phrase> args<phrase role="special">)</phrase><phrase role="special">;
</phrase></literallayout></para><para>Inserts an object, constructed with the arguments <computeroutput>args</computeroutput>, in the container if and only if there is no element in the container with an equivalent value.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>The bool component of the return type is true if an insert took place.</para><para>If an insert took place, then the iterator points to the newly inserted element. Otherwise, it points to the element with equivalent value.</para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><para>If an exception is thrown by an operation other than a call to <computeroutput>hasher</computeroutput> the function has no effect.</para></listitem></varlistentry><varlistentry><term>Notes:</term><listitem><para>Can invalidate iterators, but only if the insert causes the load factor to be greater to or equal to the maximum load factor.</para><para>Pointers and references to elements are never invalidated.</para><para>If the compiler doesn't support variadic template arguments or rvalue
+ references, this is emulated for up to 10 arguments, with no support
+ for rvalue references or move semantics.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase><phrase role="special">...</phrase> Args<phrase role="special">></phrase>
+ <phrase role="identifier">iterator</phrase> <anchor id="id26-bb"/><phrase role="identifier">emplace_hint</phrase><phrase role="special">(</phrase><phrase role="identifier">const_iterator</phrase> hint<phrase role="special">,</phrase> <phrase role="identifier">Args</phrase><phrase role="special">&&</phrase><phrase role="special">...</phrase> args<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Inserts an object, constructed with the arguments <computeroutput>args</computeroutput>, in the container if and only if there is no element in the container with an equivalent value.</para><para>hint is a suggestion to where the element should be inserted.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>If an insert took place, then the iterator points to the newly inserted element. Otherwise, it points to the element with equivalent value.</para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><para>If an exception is thrown by an operation other than a call to <computeroutput>hasher</computeroutput> the function has no effect.</para></listitem></varlistentry><varlistentry><term>Notes:</term><listitem><para>The standard is fairly vague on the meaning of the hint. But the only practical way to use it, and the only way that Boost.Unordered supports is to point to an existing element with the same value. </para><para>Can invalidate iterators, but only if the insert causes the load factor to be greater to or equal to the maximum load factor.</para><para>Pointers and references to elements are never invalidated.</para><para>If the compiler doesn't support variadic template arguments or rvalue
+ references, this is emulated for up to 10 arguments, with no support
+ for rvalue references or move semantics.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">pair</phrase><phrase role="special"><</phrase><phrase role="identifier">iterator</phrase><phrase role="special">,</phrase> <phrase role="keyword">bool</phrase><phrase role="special">></phrase> <anchor id="id27-bb"/><phrase role="identifier">insert</phrase><phrase role="special">(</phrase><phrase role="identifier">value_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> obj<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Inserts obj in the container if and only if there is no element in the container with an equivalent value.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>The bool component of the return type is true if an insert took place.</para><para>If an insert took place, then the iterator points to the newly inserted element. Otherwise, it points to the element with equivalent value.</para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><para>If an exception is thrown by an operation other than a call to <computeroutput>hasher</computeroutput> the function has no effect.</para></listitem></varlistentry><varlistentry><term>Notes:</term><listitem><para>Can invalidate iterators, but only if the insert causes the load factor to be greater to or equal to the maximum load factor.</para><para>Pointers and references to elements are never invalidated.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">iterator</phrase> <anchor id="id28-bb"/><phrase role="identifier">insert</phrase><phrase role="special">(</phrase
><phrase role="identifier">const_iterator</phrase> hint<phrase role="special">,</phrase> <phrase role="identifier">value_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> obj<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Inserts obj in the container if and only if there is no element in the container with an equivalent value.</para><para>hint is a suggestion to where the element should be inserted.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>If an insert took place, then the iterator points to the newly inserted element. Otherwise, it points to the element with equivalent value.</para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><para>If an exception is thrown by an operation other than a call to <computeroutput>hasher</computeroutput> the function has no effect.</para></listitem></varlistentry><varlistentry><term>Notes:</term><listitem><para>The standard is fairly vague on the meaning of the hint. But the only practical way to use it, and the only way that Boost.Unordered supports is to point to an existing element with the same value. </para><para>Can invalidate iterators, but only if the insert causes the load factor to be greater to or equal to the maximum load factor.</para><para>Pointers and references to elements are never invalidated.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase rol
e="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> InputIterator<phrase role="special">></phrase>
+ <phrase role="keyword">void</phrase> <anchor id="id29-bb"/><phrase role="identifier">insert</phrase><phrase role="special">(</phrase><phrase role="identifier">InputIterator</phrase> first<phrase role="special">,</phrase> <phrase role="identifier">InputIterator</phrase> last<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Inserts a range of elements into the container. Elements are inserted if and only if there is no element in the container with an equivalent value.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Throws:</term><listitem><para>When inserting a single element, if an exception is thrown by an operation other than a call to <computeroutput>hasher</computeroutput> the function has no effect.</para></listitem></varlistentry><varlistentry><term>Notes:</term><listitem><para>Can invalidate iterators, but only if the insert causes the load factor to be greater to or equal to the maximum load factor.</para><para>Pointers and references to elements are never invalidated.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">iterator</phrase> <anchor id="id30-bb"/><phrase role="identifier">erase</phrase><phrase role="special">(</phrase><phrase role="identifier">const_iterator</phrase> position<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Erase the element pointed to by <computeroutput>position</computeroutput>.</para><variablelist spacing="compact"><?dbhtm
l
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>The iterator following <computeroutput>position</computeroutput> before the erasure.</para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><para>Only throws an exception if it is thrown by <computeroutput>hasher</computeroutput> or <computeroutput>key_equal</computeroutput>.</para><para>In this implementation, this overload doesn't call either function object's methods so it is no throw, but this might not be true in other implementations.</para></listitem></varlistentry><varlistentry><term>Notes:</term><listitem><para>
+ When the number of elements is a lot smaller than the number of buckets
+ this function can be very inefficient as it has to search through empty
+ buckets for the next element, in order to return the iterator.
+ The method <link linkend="id33-bb">quick_erase</link> is faster, but has yet
+ to be standardized.
+ </para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">size_type</phrase> <anchor id="id31-bb"/><phrase role="identifier">erase</phrase><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> k<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Erase all elements with key equivalent to <computeroutput>k</computeroutput>.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>The number of elements erased.</para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><para>Only throws an exception if it is thrown by <computeroutput>hasher</computeroutput> or <computeroutput>key_equal</computeroutput>.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">iterator</phrase> <anchor id="id32-bb"/><phrase role="identifier">erase</phrase><phrase role="special">(</phrase><phrase role="identifier">const_iterator</phrase> first<phrase role="special">,</phrase> <phrase role="identifier">const_iterator</phrase> last<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Erases the elements in the range from <computeroutput>first</computeroutput> to <computeroutput>last</computeroutput>.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>The iterator following the erased elements - i.e. <computeroutput>last</computeroutput>.</para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><para>Only throws an exception if it is thrown by <computeroutput>hasher</computeroutput> or <computeroutput>key_equal</computeroutput>.</para><para>In this implementation, this overload doesn't call either function object's methods so it is no throw, but this might not be true in other implementations.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="keyword">void</phrase> <anchor id="id33-bb"/><phrase role="identifier">quick_erase</phrase><phrase role="special">(</phrase><phrase role="identifier">const_iterator</phrase> position<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Erase the element pointed to by <computeroutput>position</computeroutput>.</para><variableli
st spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Throws:</term><listitem><para>Only throws an exception if it is thrown by <computeroutput>hasher</computeroutput> or <computeroutput>key_equal</computeroutput>.</para><para>In this implementation, this overload doesn't call either function object's methods so it is no throw, but this might not be true in other implementations.</para></listitem></varlistentry><varlistentry><term>Notes:</term><listitem><para>
+ This method is faster than <link linkend="id30-bb">erase</link> as
+ it doesn't have to find the next element in the container -
+ a potentially costly operation.
+ </para><para>
+ As it hasn't been standardized, it's likely that this may
+ change in the future.
+ </para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="keyword">void</phrase> <anchor id="id34-bb"/><phrase role="identifier">erase_return_void</phrase><phrase role="special">(</phrase><phrase role="identifier">const_iterator</phrase> position<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Erase the element pointed to by <computeroutput>position</computeroutput>.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Throws:</term><listitem><para>Only throws an exception if it is thrown by <computeroutput>hasher</computeroutput> or <computeroutput>key_equal</computeroutput>.</para><para>In this implementation, this overload doesn't call either function object's methods so it is no throw, but this might not be true in other implementations.</para></listitem></varlistentry><varlistentry><term>Notes:</term><listitem><para>
+ This method is now deprecated, use
+ quick_return instead. Although be
+ warned that as that isn't standardized yet, it could also
+ change.
+ </para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="keyword">void</phrase> <anchor id="id35-bb"/><phrase role="identifier">clear</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Erases all elements in the container.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Postconditions:</term><listitem><para><computeroutput><link linkend="id13-bb">size</link>() == 0</computeroutput></para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><para>Never throws an exception.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="keyword">void</phrase> <anchor id="id36-bb"/><phrase role="identifier">swap</phrase><phrase role="special">(</phrase><phrase role="identifier">unordered_set</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Throws:</term><listitem><para>If the allocators are equal, doesn't throw an exception unless it is thrown by the copy constructor or copy assignment operator of <computeroutput>key_equal</computeroutput> or <computeroutput>hasher</computeroutput>.</para></listitem></varlistentry><varlistentry><term>Notes:</term><listitem><para>For a discussion of the behavior when allocators aren't equal see
+ <link linkend="unordered.rationale.swapping_containers_with_unequal_allocators">the implementation details</link>.</para></listitem></varlistentry></variablelist></listitem></orderedlist></refsect2><refsect2><title><anchor id="id37-bb"/><computeroutput>unordered_set</computeroutput> observers</title><orderedlist><listitem><para><literallayout class="monospaced"><phrase role="identifier">hasher</phrase> <anchor id="id38-bb"/><phrase role="identifier">hash_function</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem>The container's hash function.
+ </listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">key_equal</phrase> <anchor id="id39-bb"/><phrase role="identifier">key_eq</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem>The container's key equality predicate.
+ </listitem></varlistentry></variablelist></listitem></orderedlist></refsect2><refsect2><title><anchor id="id40-bb"/><computeroutput>unordered_set</computeroutput> lookup</title><orderedlist><listitem><para><literallayout class="monospaced"><anchor id="id41-bb"/><phrase role="identifier">iterator</phrase> <anchor id="id42-bb"/><phrase role="identifier">find</phrase><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> k<phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="identifier">const_iterator</phrase> <anchor id="id43-bb"/><phrase role="identifier">find</phrase><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> k<phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+<phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> CompatibleKey<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> CompatibleHash<phrase role="special">,</phrase>
+ <phrase role="keyword">typename</phrase> CompatiblePredicate<phrase role="special">></phrase>
+ <phrase role="identifier">iterator</phrase> <anchor id="id44-bb"/><phrase role="identifier">find</phrase><phrase role="special">(</phrase><phrase role="identifier">CompatibleKey</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> k<phrase role="special">,</phrase> <phrase role="identifier">CompatibleHash</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> hash<phrase role="special">,</phrase>
+ <phrase role="identifier">CompatiblePredicate</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> eq<phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> CompatibleKey<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> CompatibleHash<phrase role="special">,</phrase>
+ <phrase role="keyword">typename</phrase> CompatiblePredicate<phrase role="special">></phrase>
+ <phrase role="identifier">const_iterator</phrase>
+ <anchor id="id45-bb"/><phrase role="identifier">find</phrase><phrase role="special">(</phrase><phrase role="identifier">CompatibleKey</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> k<phrase role="special">,</phrase> <phrase role="identifier">CompatibleHash</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> hash<phrase role="special">,</phrase>
+ <phrase role="identifier">CompatiblePredicate</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> eq<phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>An iterator pointing to an element with key equivalent to <computeroutput>k</computeroutput>, or <computeroutput>b.end()</computeroutput> if no such element exists.</para></listitem></varlistentry><varlistentry><term>Notes:</term><listitem><para>
+ The templated overloads are a non-standard extensions which
+ allows you to use a compatible hash function and equality
+ predicate for a key of a different type in order to avoid
+ an expensive type cast. In general, its use is not encouraged.
+ </para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">size_type</phrase> <anchor id="id46-bb"/><phrase role="identifier">count</phrase><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> k<phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>The number of elements with key equivalent to <computeroutput>k</computeroutput>.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><anchor id="id47-bb"/><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">pair</phrase><phrase role="special"><</phrase><phrase role="identifier">iterator</phrase><phrase role="special">,</phrase> <phrase role="identifier">iterator</phrase><phrase role="special">></phrase> <anchor id="id48-bb"/><phrase role="identifier">equal_range</phrase><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> k<phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">pair</phrase><phrase role="special"><</phrase><phrase role="identifier">const_iterator</phrase><phrase role="special">,</phrase> <phrase role="identifier">const_iterator</phrase><phrase role="special">></phrase> <anchor id="id49-bb"/><phrase role="identifier">equal_range</phrase><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> k<phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>A range containing all elements with key equivalent to <computeroutput>k</computeroutput>.
+ If the container doesn't container any such elements, returns
+ <computeroutput>std::make_pair(b.end(),b.end())</computeroutput>.
+ </para></listitem></varlistentry></variablelist></listitem></orderedlist></refsect2><refsect2><title><anchor id="id50-bb"/><computeroutput>unordered_set</computeroutput> bucket interface</title><orderedlist><listitem><para><literallayout class="monospaced"><phrase role="identifier">size_type</phrase> <anchor id="id51-bb"/><phrase role="identifier">bucket_count</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>The number of buckets.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">size_type</phrase> <anchor id="id52-bb"/><phrase role="identifier">max_bucket_count</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>An upper bound on the number of buckets.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">size_type</phrase> <anchor id="id53-bb"/><phrase role="identifier">bucket_size</phrase><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase> n<phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Requires:</term><listitem><para><computeroutput>n < <link linkend="id51-bb">bucket_count</link>()</computeroutput></para></listitem></varlistentry><varlistentry><term>Returns:</term><listitem><para>The number of elements in bucket <computeroutput>n</computeroutput>.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">size_type</phrase> <anchor id="id54-bb"/><phrase role="identifier">bucket</phrase><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> k<phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>The index of the bucket which would contain an element with key <computeroutput>k</computeroutput>.</para></listitem></varlistentry><varlistentry><term>Postconditions:</term><listitem><para>The return value is less than <computeroutput>bucket_count()</computeroutput></para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><anchor id="id55-bb"/><phrase role="identifier">local_iterator</phrase> <anchor id="id56-bb"/><phrase role="identifier">begin</phrase><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase> n<phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="identifier">const_local_iterator</phrase> <anchor id="id57-bb"/><phrase role="identifier">begin</phrase><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase> n<phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Requires:</term><listitem><para><computeroutput>n</computeroutput> shall be in the range <computeroutput>[0, bucket_count())</computeroutput>.</para></listitem></varlistentry><varlistentry><term>Returns:</term><listitem><para>A local iterator pointing the first element in the bucket with index <computeroutput>n</computeroutput>.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><anchor id="id58-bb"/><phrase role="identifier">local_iterator</phrase> <anchor id="id59-bb"/><phrase role="identifier">end</phrase><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase> n<phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="identifier">const_local_iterator</phrase> <anchor id="id60-bb"/><phrase role="identifier">end</phrase><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase> n<phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Requires:</term><listitem><para><computeroutput>n</computeroutput> shall be in the range <computeroutput>[0, bucket_count())</computeroutput>.</para></listitem></varlistentry><varlistentry><term>Returns:</term><listitem><para>A local iterator pointing the 'one past the end' element in the bucket with index <computeroutput>n</computeroutput>.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">const_local_iterator</phrase> <anchor id="id61-bb"/><phrase role="identifier">cbegin</phrase><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase> n<phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Requires:</term><listitem><para><computeroutput>n</computeroutput> shall be in the range <computeroutput>[0, bucket_count())</computeroutput>.</para></listitem></varlistentry><varlistentry><term>Returns:</term><listitem><para>A constant local iterator pointing the first element in the bucket with index <computeroutput>n</computeroutput>.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">const_local_iterator</phrase> <anchor id="id62-bb"/><phrase role="identifier">cend</phrase><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase> n<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Requires:</term><listitem><para><computeroutput>n</computeroutput> shall be in the range <computeroutput>[0, bucket_count())</computeroutput>.</para></listitem></varlistentry><varlistentry><term>Returns:</term><listitem><para>A constant local iterator pointing the 'one past the end' element in the bucket with index <computeroutput>n</computeroutput>.</para></listitem></varlistentry></variablelist></listitem></orderedlist></refsect2><refsect2><title><anchor id="id63-bb"/><computeroutput>unordered_set</computeroutput> hash policy</title><orderedlist><listitem><para><literallayout class="monospaced"><phrase role="keyword">float</phrase> <anchor id="id64-bb"/><phrase role="identifier">load_factor</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>The average number of elements per bucket.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="keyword">float</phrase> <anchor id="id65-bb"/><phrase role="identifier">max_load_factor</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>Returns the current maximum load factor.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="keyword">void</phrase> <anchor id="id66-bb"/><phrase role="identifier">max_load_factor</phrase><phrase role="special">(</phrase><phrase role="keyword">float</phrase> z<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Effects:</term><listitem><para>Changes the container's maximum load factor, using <computeroutput>z</computeroutput> as a hint.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="keyword">void</phrase> <anchor id="id67-bb"/><phrase role="identifier">rehash</phrase><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase> n<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Changes the number of buckets so that there at least <computeroutput>n</computeroutput> buckets, and so that the load factor is less than the maximum load factor.</para><para>Invalidates iterators, and changes the order of elements. Pointers and references to elements are not invalidated.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Throws:</term><listitem><para>The function has no effect if an exception is thrown, unless it is thrown by the container's hash function or comparison function.</para></listitem></varlistentry></variablelist></listitem></orderedlist></refsect2><refsect2><title><anchor id="id68-bb"/><computeroutput>unordered_set</computeroutput> Equality Comparisons</title><orderedlist><listitem><para><literallayout class="monospaced"><phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> Value<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Hash<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Pred<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Alloc<phrase role="special">></phrase>
+ <phrase role="keyword">bool</phrase> <anchor id="boost.unordered_set.operator==_id1"/><phrase role="keyword">operator</phrase><phrase role="special">==</phrase><phrase role="special">(</phrase><phrase role="identifier">unordered_set</phrase><phrase role="special"><</phrase><phrase role="identifier">Value</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> x<phrase role="special">,</phrase>
+ <phrase role="identifier">unordered_set</phrase><phrase role="special"><</phrase><phrase role="identifier">Value</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> y<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Notes:</term><listitem><para>This is a boost extension.</para><para>Behavior is undefined if the two containers don't have
+ equivalent equality predicates.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> Value<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Hash<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Pred<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Alloc<phrase role="special">></phrase>
+ <phrase role="keyword">bool</phrase> <anchor id="boost.unordered_set.operator!=_id1"/><phrase role="keyword">operator</phrase><phrase role="special">!=</phrase><phrase role="special">(</phrase><phrase role="identifier">unordered_set</phrase><phrase role="special"><</phrase><phrase role="identifier">Value</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> x<phrase role="special">,</phrase>
+ <phrase role="identifier">unordered_set</phrase><phrase role="special"><</phrase><phrase role="identifier">Value</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> y<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Notes:</term><listitem><para>This is a boost extension.</para><para>Behavior is undefined if the two containers don't have
+ equivalent equality predicates.</para></listitem></varlistentry></variablelist></listitem></orderedlist></refsect2><refsect2><title><anchor id="id69-bb"/><computeroutput>unordered_set</computeroutput> swap</title><orderedlist><listitem><para><literallayout class="monospaced"><phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> Value<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Hash<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Pred<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Alloc<phrase role="special">></phrase>
+ <phrase role="keyword">void</phrase> <anchor id="boost.unordered_set.swap_id1"/><phrase role="identifier">swap</phrase><phrase role="special">(</phrase><phrase role="identifier">unordered_set</phrase><phrase role="special"><</phrase><phrase role="identifier">Value</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase><phrase role="special">&</phrase> x<phrase role="special">,</phrase>
+ <phrase role="identifier">unordered_set</phrase><phrase role="special"><</phrase><phrase role="identifier">Value</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase><phrase role="special">&</phrase> y<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Effects:</term><listitem><para><computeroutput>x.swap(y)</computeroutput></para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><para>If the allocators are equal, doesn't throw an exception unless it is thrown by the copy constructor or copy assignment operator of <computeroutput>Hash</computeroutput> or <computeroutput>Pred</computeroutput>.</para></listitem></varlistentry><varlistentry><term>Notes:</term><listitem><para>For a discussion of the behavior when allocators aren't equal see
+ <link linkend="unordered.rationale.swapping_containers_with_unequal_allocators">the implementation details</link>.</para></listitem></varlistentry></variablelist></listitem></orderedlist></refsect2></refsect1></refentry><refentry xmlns:xi="http://www.w3.org/2001/XInclude" id="boost.unordered_multiset"><refmeta><refentrytitle>Class template unordered_multiset</refentrytitle><manvolnum>3</manvolnum></refmeta><refnamediv><refname>boost::unordered_multiset</refname><refpurpose>
+ An unordered associative container that stores values. The same key can be stored multiple times.
+ </refpurpose></refnamediv><refsynopsisdiv><synopsis><phrase role="comment">// In header: <<link linkend="header.boost.unordered_set_hpp">boost/unordered_set.hpp</link>>
+
+</phrase><phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> Value<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Hash <phrase role="special">=</phrase> <phrase role="identifier">boost</phrase><phrase role="special">::</phrase><phrase role="identifier">hash</phrase><phrase role="special"><</phrase><phrase role="identifier">Value</phrase><phrase role="special">></phrase><phrase role="special">,</phrase>
+ <phrase role="keyword">typename</phrase> Pred <phrase role="special">=</phrase> <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">equal_to</phrase><phrase role="special"><</phrase><phrase role="identifier">Value</phrase><phrase role="special">></phrase><phrase role="special">,</phrase>
+ <phrase role="keyword">typename</phrase> Alloc <phrase role="special">=</phrase> <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">allocator</phrase><phrase role="special"><</phrase><phrase role="identifier">Value</phrase><phrase role="special">></phrase> <phrase role="special">></phrase>
+<phrase role="keyword">class</phrase> <link linkend="boost.unordered_multiset">unordered_multiset</link> <phrase role="special">{</phrase>
+<phrase role="keyword">public</phrase><phrase role="special">:</phrase>
+ <phrase role="comment">// <link linkend="boost.unordered_multisettypes">types</link></phrase>
+ <phrase role="keyword">typedef</phrase> <phrase role="identifier">Value</phrase> <anchor id="boost.unordered_multiset.key_type"/><phrase role="identifier">key_type</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">typedef</phrase> <phrase role="identifier">Value</phrase> <anchor id="boost.unordered_multiset.value_type"/><phrase role="identifier">value_type</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">typedef</phrase> <phrase role="identifier">Hash</phrase> <anchor id="boost.unordered_multiset.hasher"/><phrase role="identifier">hasher</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">typedef</phrase> <phrase role="identifier">Pred</phrase> <anchor id="boost.unordered_multiset.key_equal"/><phrase role="identifier">key_equal</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">typedef</phrase> <phrase role="identifier">Alloc</phrase> <anchor id="boost.unordered_multiset.allocator_type"/><phrase role="identifier">allocator_type</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">typedef</phrase> <phrase role="keyword">typename</phrase> <phrase role="identifier">allocator_type</phrase><phrase role="special">::</phrase><phrase role="identifier">pointer</phrase> <anchor id="boost.unordered_multiset.pointer"/><phrase role="identifier">pointer</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">typedef</phrase> <phrase role="keyword">typename</phrase> <phrase role="identifier">allocator_type</phrase><phrase role="special">::</phrase><phrase role="identifier">const_pointer</phrase> <anchor id="boost.unordered_multiset.const_pointer"/><phrase role="identifier">const_pointer</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">typedef</phrase> <phrase role="keyword">typename</phrase> <phrase role="identifier">allocator_type</phrase><phrase role="special">::</phrase><phrase role="identifier">reference</phrase> <anchor id="boost.unordered_multiset.reference"/><phrase role="identifier">reference</phrase><phrase role="special">;</phrase> <phrase role="comment">// lvalue of value_type.</phrase>
+ <phrase role="keyword">typedef</phrase> <phrase role="keyword">typename</phrase> <phrase role="identifier">allocator_type</phrase><phrase role="special">::</phrase><phrase role="identifier">const_reference</phrase> <anchor id="boost.unordered_multiset.const_reference"/><phrase role="identifier">const_reference</phrase><phrase role="special">;</phrase> <phrase role="comment">// const lvalue of value_type.</phrase>
+ <phrase role="keyword">typedef</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis> <link linkend="boost.unordered_multiset.size_type"><phrase role="identifier">size_type</phrase></link><phrase role="special">;</phrase>
+ <phrase role="keyword">typedef</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis> <link linkend="boost.unordered_multiset.difference_type"><phrase role="identifier">difference_type</phrase></link><phrase role="special">;</phrase>
+ <phrase role="keyword">typedef</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis> <link linkend="boost.unordered_multiset.iterator"><phrase role="identifier">iterator</phrase></link><phrase role="special">;</phrase>
+ <phrase role="keyword">typedef</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis> <link linkend="boost.unordered_multiset.const_iterator"><phrase role="identifier">const_iterator</phrase></link><phrase role="special">;</phrase>
+ <phrase role="keyword">typedef</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis> <link linkend="boost.unordered_multiset.local_iterator"><phrase role="identifier">local_iterator</phrase></link><phrase role="special">;</phrase>
+ <phrase role="keyword">typedef</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis> <link linkend="boost.unordered_multiset.const_local_iterator"><phrase role="identifier">const_local_iterator</phrase></link><phrase role="special">;</phrase>
+
+ <phrase role="comment">// <link linkend="boost.unordered_multisetconstruct-copy-destruct">construct/copy/destruct</link></phrase>
+ <phrase role="keyword">explicit</phrase> <link linkend="id70-bb"><phrase role="identifier">unordered_multiset</phrase></link><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase> <phrase role="special">=</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis><phrase role="special">,</phrase>
+ <phrase role="identifier">hasher</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> <phrase role="special">=</phrase> <phrase role="identifier">hasher</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">key_equal</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> <phrase role="special">=</phrase> <phrase role="identifier">key_equal</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">allocator_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> <phrase role="special">=</phrase> <phrase role="identifier">allocator_type</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> InputIterator<phrase role="special">></phrase>
+ <link linkend="id71-bb"><phrase role="identifier">unordered_multiset</phrase></link><phrase role="special">(</phrase><phrase role="identifier">InputIterator</phrase><phrase role="special">,</phrase> <phrase role="identifier">InputIterator</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">size_type</phrase> <phrase role="special">=</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis><phrase role="special">,</phrase>
+ <phrase role="identifier">hasher</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> <phrase role="special">=</phrase> <phrase role="identifier">hasher</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">key_equal</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> <phrase role="special">=</phrase> <phrase role="identifier">key_equal</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">allocator_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> <phrase role="special">=</phrase> <phrase role="identifier">allocator_type</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <link linkend="id72-bb"><phrase role="identifier">unordered_multiset</phrase></link><phrase role="special">(</phrase><phrase role="identifier">unordered_multiset</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <link linkend="id73-bb"><phrase role="identifier">unordered_multiset</phrase></link><phrase role="special">(</phrase><phrase role="identifier">unordered_multiset</phrase> <phrase role="special">&&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">explicit</phrase> <link linkend="id74-bb"><phrase role="identifier">unordered_multiset</phrase></link><phrase role="special">(</phrase><phrase role="identifier">Allocator</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <link linkend="id75-bb"><phrase role="identifier">unordered_multiset</phrase></link><phrase role="special">(</phrase><phrase role="identifier">unordered_multiset</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">,</phrase> <phrase role="identifier">Allocator</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <link linkend="id76-bb"><phrase role="special">~</phrase><phrase role="identifier">unordered_multiset</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">unordered_multiset</phrase><phrase role="special">&</phrase> <link linkend="id77-bb"><phrase role="keyword">operator</phrase><phrase role="special">=</phrase></link><phrase role="special">(</phrase><phrase role="identifier">unordered_multiset</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">unordered_multiset</phrase><phrase role="special">&</phrase> <link linkend="id78-bb"><phrase role="keyword">operator</phrase><phrase role="special">=</phrase></link><phrase role="special">(</phrase><phrase role="identifier">unordered_multiset</phrase> <phrase role="special">&&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">allocator_type</phrase> <link linkend="id79-bb"><phrase role="identifier">get_allocator</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+
+ <phrase role="comment">// <link linkend="id80-bb">size and capacity</link></phrase>
+ <phrase role="keyword">bool</phrase> <link linkend="id81-bb"><phrase role="identifier">empty</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">size_type</phrase> <link linkend="id82-bb"><phrase role="identifier">size</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">size_type</phrase> <link linkend="id83-bb"><phrase role="identifier">max_size</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+
+ <phrase role="comment">// <link linkend="id84-bb">iterators</link></phrase>
+ <phrase role="identifier">iterator</phrase> <link linkend="id86-bb"><phrase role="identifier">begin</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">const_iterator</phrase> <link linkend="id87-bb"><phrase role="identifier">begin</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">iterator</phrase> <link linkend="id89-bb"><phrase role="identifier">end</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">const_iterator</phrase> <link linkend="id90-bb"><phrase role="identifier">end</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">const_iterator</phrase> <link linkend="id91-bb"><phrase role="identifier">cbegin</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">const_iterator</phrase> <link linkend="id92-bb"><phrase role="identifier">cend</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+
+ <phrase role="comment">// <link linkend="id93-bb">modifiers</link></phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase><phrase role="special">...</phrase> Args<phrase role="special">></phrase> <phrase role="identifier">iterator</phrase> <link linkend="id94-bb"><phrase role="identifier">emplace</phrase></link><phrase role="special">(</phrase><phrase role="identifier">Args</phrase><phrase role="special">&&</phrase><phrase role="special">...</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase><phrase role="special">...</phrase> Args<phrase role="special">></phrase> <phrase role="identifier">iterator</phrase> <link linkend="id95-bb"><phrase role="identifier">emplace_hint</phrase></link><phrase role="special">(</phrase><phrase role="identifier">const_iterator</phrase><phrase role="special">,</phrase> <phrase role="identifier">Args</phrase><phrase role="special">&&</phrase><phrase role="special">...</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">iterator</phrase> <link linkend="id96-bb"><phrase role="identifier">insert</phrase></link><phrase role="special">(</phrase><phrase role="identifier">value_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">iterator</phrase> <link linkend="id97-bb"><phrase role="identifier">insert</phrase></link><phrase role="special">(</phrase><phrase role="identifier">const_iterator</phrase><phrase role="special">,</phrase> <phrase role="identifier">value_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> InputIterator<phrase role="special">></phrase> <phrase role="keyword">void</phrase> <link linkend="id98-bb"><phrase role="identifier">insert</phrase></link><phrase role="special">(</phrase><phrase role="identifier">InputIterator</phrase><phrase role="special">,</phrase> <phrase role="identifier">InputIterator</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">iterator</phrase> <link linkend="id99-bb"><phrase role="identifier">erase</phrase></link><phrase role="special">(</phrase><phrase role="identifier">const_iterator</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">size_type</phrase> <link linkend="id100-bb"><phrase role="identifier">erase</phrase></link><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">iterator</phrase> <link linkend="id101-bb"><phrase role="identifier">erase</phrase></link><phrase role="special">(</phrase><phrase role="identifier">const_iterator</phrase><phrase role="special">,</phrase> <phrase role="identifier">const_iterator</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">void</phrase> <link linkend="id102-bb"><phrase role="identifier">quick_erase</phrase></link><phrase role="special">(</phrase><phrase role="identifier">const_iterator</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">void</phrase> <link linkend="id103-bb"><phrase role="identifier">erase_return_void</phrase></link><phrase role="special">(</phrase><phrase role="identifier">const_iterator</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">void</phrase> <link linkend="id104-bb"><phrase role="identifier">clear</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">void</phrase> <link linkend="id105-bb"><phrase role="identifier">swap</phrase></link><phrase role="special">(</phrase><phrase role="identifier">unordered_multiset</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+
+ <phrase role="comment">// <link linkend="id106-bb">observers</link></phrase>
+ <phrase role="identifier">hasher</phrase> <link linkend="id107-bb"><phrase role="identifier">hash_function</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">key_equal</phrase> <link linkend="id108-bb"><phrase role="identifier">key_eq</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+
+ <phrase role="comment">// <link linkend="id109-bb">lookup</link></phrase>
+ <phrase role="identifier">iterator</phrase> <link linkend="id111-bb"><phrase role="identifier">find</phrase></link><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">const_iterator</phrase> <link linkend="id112-bb"><phrase role="identifier">find</phrase></link><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> CompatibleKey<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> CompatibleHash<phrase role="special">,</phrase>
+ <phrase role="keyword">typename</phrase> CompatiblePredicate<phrase role="special">></phrase>
+ <phrase role="identifier">iterator</phrase> <link linkend="id113-bb"><phrase role="identifier">find</phrase></link><phrase role="special">(</phrase><phrase role="identifier">CompatibleKey</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">,</phrase> <phrase role="identifier">CompatibleHash</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">CompatiblePredicate</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> CompatibleKey<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> CompatibleHash<phrase role="special">,</phrase>
+ <phrase role="keyword">typename</phrase> CompatiblePredicate<phrase role="special">></phrase>
+ <phrase role="identifier">const_iterator</phrase>
+ <link linkend="id114-bb"><phrase role="identifier">find</phrase></link><phrase role="special">(</phrase><phrase role="identifier">CompatibleKey</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">,</phrase> <phrase role="identifier">CompatibleHash</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">CompatiblePredicate</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">size_type</phrase> <link linkend="id115-bb"><phrase role="identifier">count</phrase></link><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">pair</phrase><phrase role="special"><</phrase><phrase role="identifier">iterator</phrase><phrase role="special">,</phrase> <phrase role="identifier">iterator</phrase><phrase role="special">></phrase> <link linkend="id117-bb"><phrase role="identifier">equal_range</phrase></link><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">pair</phrase><phrase role="special"><</phrase><phrase role="identifier">const_iterator</phrase><phrase role="special">,</phrase> <phrase role="identifier">const_iterator</phrase><phrase role="special">></phrase> <link linkend="id118-bb"><phrase role="identifier">equal_range</phrase></link><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+
+ <phrase role="comment">// <link linkend="id119-bb">bucket interface</link></phrase>
+ <phrase role="identifier">size_type</phrase> <link linkend="id120-bb"><phrase role="identifier">bucket_count</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">size_type</phrase> <link linkend="id121-bb"><phrase role="identifier">max_bucket_count</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">size_type</phrase> <link linkend="id122-bb"><phrase role="identifier">bucket_size</phrase></link><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">size_type</phrase> <link linkend="id123-bb"><phrase role="identifier">bucket</phrase></link><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">local_iterator</phrase> <link linkend="id125-bb"><phrase role="identifier">begin</phrase></link><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">const_local_iterator</phrase> <link linkend="id126-bb"><phrase role="identifier">begin</phrase></link><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">local_iterator</phrase> <link linkend="id128-bb"><phrase role="identifier">end</phrase></link><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">const_local_iterator</phrase> <link linkend="id129-bb"><phrase role="identifier">end</phrase></link><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">const_local_iterator</phrase> <link linkend="id130-bb"><phrase role="identifier">cbegin</phrase></link><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">const_local_iterator</phrase> <link linkend="id131-bb"><phrase role="identifier">cend</phrase></link><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+
+ <phrase role="comment">// <link linkend="id132-bb">hash policy</link></phrase>
+ <phrase role="keyword">float</phrase> <link linkend="id133-bb"><phrase role="identifier">load_factor</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">float</phrase> <link linkend="id134-bb"><phrase role="identifier">max_load_factor</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">void</phrase> <link linkend="id135-bb"><phrase role="identifier">max_load_factor</phrase></link><phrase role="special">(</phrase><phrase role="keyword">float</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">void</phrase> <link linkend="id136-bb"><phrase role="identifier">rehash</phrase></link><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="special">}</phrase><phrase role="special">;</phrase>
+
+<phrase role="comment">// <link linkend="id137-bb">Equality Comparisons</link></phrase>
+<phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> Value<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Hash<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Pred<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Alloc<phrase role="special">></phrase>
+ <phrase role="keyword">bool</phrase> <link linkend="boost.unordered_multiset.operator==_id1"><phrase role="keyword">operator</phrase><phrase role="special">==</phrase></link><phrase role="special">(</phrase><phrase role="identifier">unordered_multiset</phrase><phrase role="special"><</phrase><phrase role="identifier">Value</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">unordered_multiset</phrase><phrase role="special"><</phrase><phrase role="identifier">Value</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> Value<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Hash<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Pred<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Alloc<phrase role="special">></phrase>
+ <phrase role="keyword">bool</phrase> <link linkend="boost.unordered_multiset.operator!=_id1"><phrase role="keyword">operator</phrase><phrase role="special">!=</phrase></link><phrase role="special">(</phrase><phrase role="identifier">unordered_multiset</phrase><phrase role="special"><</phrase><phrase role="identifier">Value</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">unordered_multiset</phrase><phrase role="special"><</phrase><phrase role="identifier">Value</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+
+<phrase role="comment">// <link linkend="id138-bb">swap</link></phrase>
+<phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> Value<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Hash<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Pred<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Alloc<phrase role="special">></phrase>
+ <phrase role="keyword">void</phrase> <link linkend="boost.unordered_multiset.swap_id1"><phrase role="identifier">swap</phrase></link><phrase role="special">(</phrase><phrase role="identifier">unordered_multiset</phrase><phrase role="special"><</phrase><phrase role="identifier">Value</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase><phrase role="special">&</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">unordered_multiset</phrase><phrase role="special"><</phrase><phrase role="identifier">Value</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase></synopsis></refsynopsisdiv><refsect1><title>Description</title>
+ <para>Based on chapter 23 of
+ <ulink url="http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2009/n2960.pdf">the working draft of the C++ standard [n2960]</ulink>.
+ But without the updated rules for allocators.
+ </para>
+ <para><emphasis role="bold">Template Parameters</emphasis>
+ <informaltable>
+ <tgroup cols="2">
+ <tbody>
+ <row>
+ <entry><emphasis>Value</emphasis></entry>
+ <entry>Value must be Assignable and CopyConstructible</entry></row>
+ <row>
+ <entry><emphasis>Hash</emphasis></entry>
+ <entry>A unary function object type that acts a hash function for a <computeroutput>Value</computeroutput>. It takes a single argument of type <computeroutput>Value</computeroutput> and returns a value of type std::size_t.</entry></row>
+ <row>
+ <entry><emphasis>Pred</emphasis></entry>
+ <entry>A binary function object that implements an equivalence relation on values of type <computeroutput>Value</computeroutput>.
+ A binary function object that induces an equivalence relation on values of type Key.
+ It takes two arguments of type Key and returns a value of type bool.</entry></row>
+ <row>
+ <entry><emphasis>Alloc</emphasis></entry>
+ <entry>An allocator whose value type is the same as the container's value type.</entry></row></tbody></tgroup></informaltable></para>
+ <para>The elements are organized into buckets. Keys with the same hash code are stored in the same bucket and elements with equivalent keys are stored next to each other.</para>
+ <para>The number of buckets can be automatically increased by a call to insert, or as the result of calling rehash.</para>
+ <refsect2><title><anchor id="boost.unordered_multisettypes"/><computeroutput>unordered_multiset</computeroutput>
+ public
+ types</title><orderedlist><listitem><para>
+<phrase role="keyword">typedef</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis> <anchor id="boost.unordered_multiset.size_type"/><phrase role="identifier">size_type</phrase><phrase role="special">;</phrase></para>
+ <para>An unsigned integral type.</para>
+ <para>size_type can represent any non-negative value of difference_type.</para>
+ </listitem><listitem><para>
+<phrase role="keyword">typedef</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis> <anchor id="boost.unordered_multiset.difference_type"/><phrase role="identifier">difference_type</phrase><phrase role="special">;</phrase></para>
+ <para>A signed integral type.</para>
+ <para>Is identical to the difference type of iterator and const_iterator.</para>
+ </listitem><listitem><para>
+<phrase role="keyword">typedef</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis> <anchor id="boost.unordered_multiset.iterator"/><phrase role="identifier">iterator</phrase><phrase role="special">;</phrase></para>
+ <para>A constant iterator whose value type is value_type. </para>
+ <para>The iterator category is at least a forward iterator.</para>
+ <para>Convertible to const_iterator.</para>
+ </listitem><listitem><para>
+<phrase role="keyword">typedef</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis> <anchor id="boost.unordered_multiset.const_iterator"/><phrase role="identifier">const_iterator</phrase><phrase role="special">;</phrase></para>
+ <para>A constant iterator whose value type is value_type. </para>
+ <para>The iterator category is at least a forward iterator.</para>
+ </listitem><listitem><para>
+<phrase role="keyword">typedef</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis> <anchor id="boost.unordered_multiset.local_iterator"/><phrase role="identifier">local_iterator</phrase><phrase role="special">;</phrase></para>
+ <para>An iterator with the same value type, difference type and pointer and reference type as iterator.</para>
+ <para>A local_iterator object can be used to iterate through a single bucket.</para>
+ </listitem><listitem><para>
+<phrase role="keyword">typedef</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis> <anchor id="boost.unordered_multiset.const_local_iterator"/><phrase role="identifier">const_local_iterator</phrase><phrase role="special">;</phrase></para>
+ <para>A constant iterator with the same value type, difference type and pointer and reference type as const_iterator.</para>
+ <para>A const_local_iterator object can be used to iterate through a single bucket.</para>
+ </listitem></orderedlist></refsect2><refsect2><title><anchor id="boost.unordered_multisetconstruct-copy-destruct"/><computeroutput>unordered_multiset</computeroutput>
+ public
+ construct/copy/destruct</title><orderedlist><listitem><para><literallayout class="monospaced"><phrase role="keyword">explicit</phrase> <anchor id="id70-bb"/><phrase role="identifier">unordered_multiset</phrase><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase> n <phrase role="special">=</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis><phrase role="special">,</phrase>
+ <phrase role="identifier">hasher</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> hf <phrase role="special">=</phrase> <phrase role="identifier">hasher</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">key_equal</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> eq <phrase role="special">=</phrase> <phrase role="identifier">key_equal</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">allocator_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> a <phrase role="special">=</phrase> <phrase role="identifier">allocator_type</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Constructs an empty container with at least n buckets, using hf as the hash function, eq as the key equality predicate, a as the allocator and a maximum load factor of 1.0.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Postconditions:</term><listitem><computeroutput><link linkend="id82-bb">size</link>() == 0</computeroutput></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> InputIterator<phrase role="special">></phrase>
+ <anchor id="id71-bb"/><phrase role="identifier">unordered_multiset</phrase><phrase role="special">(</phrase><phrase role="identifier">InputIterator</phrase> f<phrase role="special">,</phrase> <phrase role="identifier">InputIterator</phrase> l<phrase role="special">,</phrase>
+ <phrase role="identifier">size_type</phrase> n <phrase role="special">=</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis><phrase role="special">,</phrase>
+ <phrase role="identifier">hasher</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> hf <phrase role="special">=</phrase> <phrase role="identifier">hasher</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">key_equal</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> eq <phrase role="special">=</phrase> <phrase role="identifier">key_equal</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">allocator_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> a <phrase role="special">=</phrase> <phrase role="identifier">allocator_type</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Constructs an empty container with at least n buckets, using hf as the hash function, eq as the key equality predicate, a as the allocator and a maximum load factor of 1.0 and inserts the elements from [f, l) into it.</para></listitem><listitem><para><literallayout class="monospaced"><anchor id="id72-bb"/><phrase role="identifier">unordered_multiset</phrase><phrase role="special">(</phrase><phrase role="identifier">unordered_multiset</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>The copy const
ructor. Copies the contained elements, hash function, predicate, maximum load factor and allocator.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Requires:</term><listitem><para><computeroutput>value_type</computeroutput> is copy constructible</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><anchor id="id73-bb"/><phrase role="identifier">unordered_multiset</phrase><phrase role="special">(</phrase><phrase role="identifier">unordered_multiset</phrase> <phrase role="special">&&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>The move constructor.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Notes:</term><listitem><para>This is emulated on compilers without rvalue references.</para></listitem></varlistentry><varlistentry><term>Requires:</term><listitem><para>
+ <computeroutput>value_type</computeroutput> is move constructible.
+ (TODO: This is not actually required in this implementation).
+ </para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="keyword">explicit</phrase> <anchor id="id74-bb"/><phrase role="identifier">unordered_multiset</phrase><phrase role="special">(</phrase><phrase role="identifier">Allocator</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> a<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Constructs an empty container, using allocator <computeroutput>a</computeroutput>.</para></listitem><listitem><para><literallayout class="monospaced"><anchor id="id75-bb"/><phrase role="identifier">unordered_multiset</phrase><phrase role="special">(</phrase><phrase role="identifier">unordered_multiset</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> x<phrase role="special">,</phrase> <phrase role="identifier">Allocator</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</
phrase> a<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Constructs an container, copying <computeroutput>x</computeroutput>'s contained elements, hash function, predicate, maximum load factor, but using allocator <computeroutput>a</computeroutput>.</para></listitem><listitem><para><literallayout class="monospaced"><anchor id="id76-bb"/><phrase role="special">~</phrase><phrase role="identifier">unordered_multiset</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Notes:</term><listitem><para>The destructor is applied to every element, and all memory is deallocated</para></listitem></varlistentry></variablelist></listitem></orderedlist></refsect2><para><literallayout class="monospaced"><phrase role="identifier">unordered_multiset</phrase><phrase role="special">&</phrase> <anchor id="id77-bb"/><phrase role="keyword">operator</phrase><phrase role="special">=</phrase><phrase role="special">(</phrase><phrase role="identifier">unordered_multiset</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>The assignment operator. Copies the contained elements, hash function, predicate and maximum load factor but not the allocator.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Notes:</term><listitem><para>
+ On compilers without rvalue references, there is a single assignment
+ operator with the signature <computeroutput>operator=(unordered_multiset)</computeroutput>
+ in order to emulate move semantics.
+ </para></listitem></varlistentry><varlistentry><term>Requires:</term><listitem><para><computeroutput>value_type</computeroutput> is copy constructible</para></listitem></varlistentry></variablelist><para><literallayout class="monospaced"><phrase role="identifier">unordered_multiset</phrase><phrase role="special">&</phrase> <anchor id="id78-bb"/><phrase role="keyword">operator</phrase><phrase role="special">=</phrase><phrase role="special">(</phrase><phrase role="identifier">unordered_multiset</phrase> <phrase role="special">&&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>The move assignment operator.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Notes:</term><listitem><para>
+ On compilers without rvalue references, there is a single assignment
+ operator with the signature <computeroutput>operator=(unordered_multiset)</computeroutput>
+ in order to emulate move semantics.
+ </para></listitem></varlistentry><varlistentry><term>Requires:</term><listitem><para>
+ <computeroutput>value_type</computeroutput> is move constructible.
+ (TODO: This is not actually required in this implementation).
+ </para></listitem></varlistentry></variablelist><para><literallayout class="monospaced"><phrase role="identifier">allocator_type</phrase> <anchor id="id79-bb"/><phrase role="identifier">get_allocator</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><refsect2><title><anchor id="id80-bb"/><computeroutput>unordered_multiset</computeroutput> size and capacity</title><orderedlist><listitem><para><literallayout class="monospaced"><phrase role="keyword">bool</phrase> <anchor id="id81-bb"/><phrase role="identifier">empty</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><computeroutput><link linkend="id82-bb">size</link>() == 0</computeroutput></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">size_type</phrase> <anchor id="id82-bb"/><phrase role="identifier">size</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><computeroutput>std::distance(<link linkend="id85-bb">begin</link>(), <link linkend="id88-bb">end</link>())</computeroutput></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">size_type</phrase> <anchor id="id83-bb"/><phrase role="identifier">max_size</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><computeroutput><link linkend="id82-bb">size</link>()</computeroutput> of the largest possible container.
+ </listitem></varlistentry></variablelist></listitem></orderedlist></refsect2><refsect2><title><anchor id="id84-bb"/><computeroutput>unordered_multiset</computeroutput> iterators</title><orderedlist><listitem><para><literallayout class="monospaced"><anchor id="id85-bb"/><phrase role="identifier">iterator</phrase> <anchor id="id86-bb"/><phrase role="identifier">begin</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="identifier">const_iterator</phrase> <anchor id="id87-bb"/><phrase role="identifier">begin</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem>An iterator referring to the first element of the container, or if the container is empty the past-the-end value for the container.
+ </listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><anchor id="id88-bb"/><phrase role="identifier">iterator</phrase> <anchor id="id89-bb"/><phrase role="identifier">end</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="identifier">const_iterator</phrase> <anchor id="id90-bb"/><phrase role="identifier">end</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem>An iterator which refers to the past-the-end value for the container.
+ </listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">const_iterator</phrase> <anchor id="id91-bb"/><phrase role="identifier">cbegin</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem>A constant iterator referring to the first element of the container, or if the container is empty the past-the-end value for the container.
+ </listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">const_iterator</phrase> <anchor id="id92-bb"/><phrase role="identifier">cend</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem>A constant iterator which refers to the past-the-end value for the container.
+ </listitem></varlistentry></variablelist></listitem></orderedlist></refsect2><refsect2><title><anchor id="id93-bb"/><computeroutput>unordered_multiset</computeroutput> modifiers</title><orderedlist><listitem><para><literallayout class="monospaced"><phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase><phrase role="special">...</phrase> Args<phrase role="special">></phrase> <phrase role="identifier">iterator</phrase> <anchor id="id94-bb"/><phrase role="identifier">emplace</phrase><phrase role="special">(</phrase><phrase role="identifier">Args</phrase><phrase role="special">&&</phrase><phrase role="special">...</phrase> args<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Inserts an object, constructed with the arguments <computeroutput>args</computeroutput>, in the container.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>An iterator pointing to the inserted element.</para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><para>If an exception is thrown by an operation other than a call to <computeroutput>hasher</computeroutput> the function has no effect.</para></listitem></varlistentry><varlistentry><term>Notes:</term><listitem><para>Can invalidate iterators, but only if the insert causes the load factor to be greater to or equal to the maximum load factor.</para><para>Pointers and references to elements are never invalidated.</para><para>If the compiler doesn't support variadic template arguments or rvalue
+ references, this is emulated for up to 10 arguments, with no support
+ for rvalue references or move semantics.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase><phrase role="special">...</phrase> Args<phrase role="special">></phrase>
+ <phrase role="identifier">iterator</phrase> <anchor id="id95-bb"/><phrase role="identifier">emplace_hint</phrase><phrase role="special">(</phrase><phrase role="identifier">const_iterator</phrase> hint<phrase role="special">,</phrase> <phrase role="identifier">Args</phrase><phrase role="special">&&</phrase><phrase role="special">...</phrase> args<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Inserts an object, constructed with the arguments <computeroutput>args</computeroutput>, in the container.</para><para>hint is a suggestion to where the element should be inserted.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>An iterator pointing to the inserted element.</para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><para>If an exception is thrown by an operation other than a call to <computeroutput>hasher</computeroutput> the function has no effect.</para></listitem></varlistentry><varlistentry><term>Notes:</term><listitem><para>The standard is fairly vague on the meaning of the hint. But the only practical way to use it, and the only way that Boost.Unordered supports is to point to an existing element with the same value. </para><para>Can invalidate iterators, but only if the insert causes the load factor to be greater to or equal to the maximum load factor.</para><para>Pointers and references to elements are never invalidated.</para><para>If the compiler doesn't support variadic template arguments or rvalue
+ references, this is emulated for up to 10 arguments, with no support
+ for rvalue references or move semantics.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">iterator</phrase> <anchor id="id96-bb"/><phrase role="identifier">insert</phrase><phrase role="special">(</phrase><phrase role="identifier">value_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> obj<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Inserts obj in the container.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>An iterator pointing to the inserted element.</para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><para>If an exception is thrown by an operation other than a call to <computeroutput>hasher</computeroutput> the function has no effect.</para></listitem></varlistentry><varlistentry><term>Notes:</term><listitem><para>Can invalidate iterators, but only if the insert causes the load factor to be greater to or equal to the maximum load factor.</para><para>Pointers and references to elements are never invalidated.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">iterator</phrase> <anchor id="id97-bb"/><phrase role="identifier">insert</phrase><phrase role="special">(</phrase><phrase role="identifier">const_iterator</phrase> hint<phrase role="special">,</phrase> <phrase role="identifier">value_type</phrase> <phrase role="keyword">const</phrase><phra
se role="special">&</phrase> obj<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Inserts obj in the container.</para><para>hint is a suggestion to where the element should be inserted.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>An iterator pointing to the inserted element.</para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><para>If an exception is thrown by an operation other than a call to <computeroutput>hasher</computeroutput> the function has no effect.</para></listitem></varlistentry><varlistentry><term>Notes:</term><listitem><para>The standard is fairly vague on the meaning of the hint. But the only practical way to use it, and the only way that Boost.Unordered supports is to point to an existing element with the same value. </para><para>Can invalidate iterators, but only if the insert causes the load factor to be greater to or equal to the maximum load factor.</para><para>Pointers and references to elements are never invalidated.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typena
me</phrase> InputIterator<phrase role="special">></phrase>
+ <phrase role="keyword">void</phrase> <anchor id="id98-bb"/><phrase role="identifier">insert</phrase><phrase role="special">(</phrase><phrase role="identifier">InputIterator</phrase> first<phrase role="special">,</phrase> <phrase role="identifier">InputIterator</phrase> last<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Inserts a range of elements into the container.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Throws:</term><listitem><para>When inserting a single element, if an exception is thrown by an operation other than a call to <computeroutput>hasher</computeroutput> the function has no effect.</para></listitem></varlistentry><varlistentry><term>Notes:</term><listitem><para>Can invalidate iterators, but only if the insert causes the load factor to be greater to or equal to the maximum load factor.</para><para>Pointers and references to elements are never invalidated.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">iterator</phrase> <anchor id="id99-bb"/><phrase role="identifier">erase</phrase><phrase role="special">(</phrase><phrase role="identifier">const_iterator</phrase> position<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Erase the element pointed to by <computeroutput>position</computeroutput>.</para><variablelist spacing="compact"><?dbhtm
l
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>The iterator following <computeroutput>position</computeroutput> before the erasure.</para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><para>Only throws an exception if it is thrown by <computeroutput>hasher</computeroutput> or <computeroutput>key_equal</computeroutput>.</para><para>In this implementation, this overload doesn't call either function object's methods so it is no throw, but this might not be true in other implementations.</para></listitem></varlistentry><varlistentry><term>Notes:</term><listitem><para>
+ When the number of elements is a lot smaller than the number of buckets
+ this function can be very inefficient as it has to search through empty
+ buckets for the next element, in order to return the iterator.
+ The method <link linkend="id102-bb">quick_erase</link> is faster, but has yet
+ to be standardized.
+ </para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">size_type</phrase> <anchor id="id100-bb"/><phrase role="identifier">erase</phrase><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> k<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Erase all elements with key equivalent to <computeroutput>k</computeroutput>.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>The number of elements erased.</para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><para>Only throws an exception if it is thrown by <computeroutput>hasher</computeroutput> or <computeroutput>key_equal</computeroutput>.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">iterator</phrase> <anchor id="id101-bb"/><phrase role="identifier">erase</phrase><phrase role="special">(</phrase><phrase role="identifier">const_iterator</phrase> first<phrase role="special">,</phrase> <phrase role="identifier">const_iterator</phrase> last<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Erases the elements in the range from <computeroutput>first</computeroutput> to <computeroutput>last</computeroutput>.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>The iterator following the erased elements - i.e. <computeroutput>last</computeroutput>.</para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><para>Only throws an exception if it is thrown by <computeroutput>hasher</computeroutput> or <computeroutput>key_equal</computeroutput>.</para><para>In this implementation, this overload doesn't call either function object's methods so it is no throw, but this might not be true in other implementations.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="keyword">void</phrase> <anchor id="id102-bb"/><phrase role="identifier">quick_erase</phrase><phrase role="special">(</phrase><phrase role="identifier">const_iterator</phrase> position<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Erase the element pointed to by <computeroutput>position</computeroutput>.</para><variablel
ist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Throws:</term><listitem><para>Only throws an exception if it is thrown by <computeroutput>hasher</computeroutput> or <computeroutput>key_equal</computeroutput>.</para><para>In this implementation, this overload doesn't call either function object's methods so it is no throw, but this might not be true in other implementations.</para></listitem></varlistentry><varlistentry><term>Notes:</term><listitem><para>
+ This method is faster than <link linkend="id99-bb">erase</link> as
+ it doesn't have to find the next element in the container -
+ a potentially costly operation.
+ </para><para>
+ As it hasn't been standardized, it's likely that this may
+ change in the future.
+ </para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="keyword">void</phrase> <anchor id="id103-bb"/><phrase role="identifier">erase_return_void</phrase><phrase role="special">(</phrase><phrase role="identifier">const_iterator</phrase> position<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Erase the element pointed to by <computeroutput>position</computeroutput>.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Throws:</term><listitem><para>Only throws an exception if it is thrown by <computeroutput>hasher</computeroutput> or <computeroutput>key_equal</computeroutput>.</para><para>In this implementation, this overload doesn't call either function object's methods so it is no throw, but this might not be true in other implementations.</para></listitem></varlistentry><varlistentry><term>Notes:</term><listitem><para>
+ This method is now deprecated, use
+ quick_return instead. Although be
+ warned that as that isn't standardized yet, it could also
+ change.
+ </para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="keyword">void</phrase> <anchor id="id104-bb"/><phrase role="identifier">clear</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Erases all elements in the container.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Postconditions:</term><listitem><para><computeroutput><link linkend="id82-bb">size</link>() == 0</computeroutput></para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><para>Never throws an exception.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="keyword">void</phrase> <anchor id="id105-bb"/><phrase role="identifier">swap</phrase><phrase role="special">(</phrase><phrase role="identifier">unordered_multiset</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Throws:</term><listitem><para>If the allocators are equal, doesn't throw an exception unless it is thrown by the copy constructor or copy assignment operator of <computeroutput>key_equal</computeroutput> or <computeroutput>hasher</computeroutput>.</para></listitem></varlistentry><varlistentry><term>Notes:</term><listitem><para>For a discussion of the behavior when allocators aren't equal see
+ <link linkend="unordered.rationale.swapping_containers_with_unequal_allocators">the implementation details</link>.</para></listitem></varlistentry></variablelist></listitem></orderedlist></refsect2><refsect2><title><anchor id="id106-bb"/><computeroutput>unordered_multiset</computeroutput> observers</title><orderedlist><listitem><para><literallayout class="monospaced"><phrase role="identifier">hasher</phrase> <anchor id="id107-bb"/><phrase role="identifier">hash_function</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem>The container's hash function.
+ </listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">key_equal</phrase> <anchor id="id108-bb"/><phrase role="identifier">key_eq</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem>The container's key equality predicate.
+ </listitem></varlistentry></variablelist></listitem></orderedlist></refsect2><refsect2><title><anchor id="id109-bb"/><computeroutput>unordered_multiset</computeroutput> lookup</title><orderedlist><listitem><para><literallayout class="monospaced"><anchor id="id110-bb"/><phrase role="identifier">iterator</phrase> <anchor id="id111-bb"/><phrase role="identifier">find</phrase><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> k<phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="identifier">const_iterator</phrase> <anchor id="id112-bb"/><phrase role="identifier">find</phrase><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> k<phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+<phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> CompatibleKey<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> CompatibleHash<phrase role="special">,</phrase>
+ <phrase role="keyword">typename</phrase> CompatiblePredicate<phrase role="special">></phrase>
+ <phrase role="identifier">iterator</phrase> <anchor id="id113-bb"/><phrase role="identifier">find</phrase><phrase role="special">(</phrase><phrase role="identifier">CompatibleKey</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> k<phrase role="special">,</phrase> <phrase role="identifier">CompatibleHash</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> hash<phrase role="special">,</phrase>
+ <phrase role="identifier">CompatiblePredicate</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> eq<phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> CompatibleKey<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> CompatibleHash<phrase role="special">,</phrase>
+ <phrase role="keyword">typename</phrase> CompatiblePredicate<phrase role="special">></phrase>
+ <phrase role="identifier">const_iterator</phrase>
+ <anchor id="id114-bb"/><phrase role="identifier">find</phrase><phrase role="special">(</phrase><phrase role="identifier">CompatibleKey</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> k<phrase role="special">,</phrase> <phrase role="identifier">CompatibleHash</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> hash<phrase role="special">,</phrase>
+ <phrase role="identifier">CompatiblePredicate</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> eq<phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>An iterator pointing to an element with key equivalent to <computeroutput>k</computeroutput>, or <computeroutput>b.end()</computeroutput> if no such element exists.</para></listitem></varlistentry><varlistentry><term>Notes:</term><listitem><para>
+ The templated overloads are a non-standard extensions which
+ allows you to use a compatible hash function and equality
+ predicate for a key of a different type in order to avoid
+ an expensive type cast. In general, its use is not encouraged.
+ </para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">size_type</phrase> <anchor id="id115-bb"/><phrase role="identifier">count</phrase><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> k<phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>The number of elements with key equivalent to <computeroutput>k</computeroutput>.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><anchor id="id116-bb"/><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">pair</phrase><phrase role="special"><</phrase><phrase role="identifier">iterator</phrase><phrase role="special">,</phrase> <phrase role="identifier">iterator</phrase><phrase role="special">></phrase> <anchor id="id117-bb"/><phrase role="identifier">equal_range</phrase><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> k<phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">pair</phrase><phrase role="special"><</phrase><phrase role="identifier">const_iterator</phrase><phrase role="special">,</phrase> <phrase role="identifier">const_iterator</phrase><phrase role="special">></phrase> <anchor id="id118-bb"/><phrase role="identifier">equal_range</phrase><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> k<phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>A range containing all elements with key equivalent to <computeroutput>k</computeroutput>.
+ If the container doesn't container any such elements, returns
+ <computeroutput>std::make_pair(b.end(),b.end())</computeroutput>.
+ </para></listitem></varlistentry></variablelist></listitem></orderedlist></refsect2><refsect2><title><anchor id="id119-bb"/><computeroutput>unordered_multiset</computeroutput> bucket interface</title><orderedlist><listitem><para><literallayout class="monospaced"><phrase role="identifier">size_type</phrase> <anchor id="id120-bb"/><phrase role="identifier">bucket_count</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>The number of buckets.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">size_type</phrase> <anchor id="id121-bb"/><phrase role="identifier">max_bucket_count</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>An upper bound on the number of buckets.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">size_type</phrase> <anchor id="id122-bb"/><phrase role="identifier">bucket_size</phrase><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase> n<phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Requires:</term><listitem><para><computeroutput>n < <link linkend="id120-bb">bucket_count</link>()</computeroutput></para></listitem></varlistentry><varlistentry><term>Returns:</term><listitem><para>The number of elements in bucket <computeroutput>n</computeroutput>.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">size_type</phrase> <anchor id="id123-bb"/><phrase role="identifier">bucket</phrase><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> k<phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>The index of the bucket which would contain an element with key <computeroutput>k</computeroutput>.</para></listitem></varlistentry><varlistentry><term>Postconditions:</term><listitem><para>The return value is less than <computeroutput>bucket_count()</computeroutput></para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><anchor id="id124-bb"/><phrase role="identifier">local_iterator</phrase> <anchor id="id125-bb"/><phrase role="identifier">begin</phrase><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase> n<phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="identifier">const_local_iterator</phrase> <anchor id="id126-bb"/><phrase role="identifier">begin</phrase><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase> n<phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Requires:</term><listitem><para><computeroutput>n</computeroutput> shall be in the range <computeroutput>[0, bucket_count())</computeroutput>.</para></listitem></varlistentry><varlistentry><term>Returns:</term><listitem><para>A local iterator pointing the first element in the bucket with index <computeroutput>n</computeroutput>.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><anchor id="id127-bb"/><phrase role="identifier">local_iterator</phrase> <anchor id="id128-bb"/><phrase role="identifier">end</phrase><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase> n<phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="identifier">const_local_iterator</phrase> <anchor id="id129-bb"/><phrase role="identifier">end</phrase><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase> n<phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Requires:</term><listitem><para><computeroutput>n</computeroutput> shall be in the range <computeroutput>[0, bucket_count())</computeroutput>.</para></listitem></varlistentry><varlistentry><term>Returns:</term><listitem><para>A local iterator pointing the 'one past the end' element in the bucket with index <computeroutput>n</computeroutput>.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">const_local_iterator</phrase> <anchor id="id130-bb"/><phrase role="identifier">cbegin</phrase><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase> n<phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Requires:</term><listitem><para><computeroutput>n</computeroutput> shall be in the range <computeroutput>[0, bucket_count())</computeroutput>.</para></listitem></varlistentry><varlistentry><term>Returns:</term><listitem><para>A constant local iterator pointing the first element in the bucket with index <computeroutput>n</computeroutput>.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">const_local_iterator</phrase> <anchor id="id131-bb"/><phrase role="identifier">cend</phrase><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase> n<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Requires:</term><listitem><para><computeroutput>n</computeroutput> shall be in the range <computeroutput>[0, bucket_count())</computeroutput>.</para></listitem></varlistentry><varlistentry><term>Returns:</term><listitem><para>A constant local iterator pointing the 'one past the end' element in the bucket with index <computeroutput>n</computeroutput>.</para></listitem></varlistentry></variablelist></listitem></orderedlist></refsect2><refsect2><title><anchor id="id132-bb"/><computeroutput>unordered_multiset</computeroutput> hash policy</title><orderedlist><listitem><para><literallayout class="monospaced"><phrase role="keyword">float</phrase> <anchor id="id133-bb"/><phrase role="identifier">load_factor</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>The average number of elements per bucket.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="keyword">float</phrase> <anchor id="id134-bb"/><phrase role="identifier">max_load_factor</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>Returns the current maximum load factor.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="keyword">void</phrase> <anchor id="id135-bb"/><phrase role="identifier">max_load_factor</phrase><phrase role="special">(</phrase><phrase role="keyword">float</phrase> z<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Effects:</term><listitem><para>Changes the container's maximum load factor, using <computeroutput>z</computeroutput> as a hint.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="keyword">void</phrase> <anchor id="id136-bb"/><phrase role="identifier">rehash</phrase><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase> n<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Changes the number of buckets so that there at least <computeroutput>n</computeroutput> buckets, and so that the load factor is less than the maximum load factor.</para><para>Invalidates iterators, and changes the order of elements. Pointers and references to elements are not invalidated.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Throws:</term><listitem><para>The function has no effect if an exception is thrown, unless it is thrown by the container's hash function or comparison function.</para></listitem></varlistentry></variablelist></listitem></orderedlist></refsect2><refsect2><title><anchor id="id137-bb"/><computeroutput>unordered_multiset</computeroutput> Equality Comparisons</title><orderedlist><listitem><para><literallayout class="monospaced"><phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> Value<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Hash<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Pred<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Alloc<phrase role="special">></phrase>
+ <phrase role="keyword">bool</phrase> <anchor id="boost.unordered_multiset.operator==_id1"/><phrase role="keyword">operator</phrase><phrase role="special">==</phrase><phrase role="special">(</phrase><phrase role="identifier">unordered_multiset</phrase><phrase role="special"><</phrase><phrase role="identifier">Value</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> x<phrase role="special">,</phrase>
+ <phrase role="identifier">unordered_multiset</phrase><phrase role="special"><</phrase><phrase role="identifier">Value</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> y<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Notes:</term><listitem><para>This is a boost extension.</para><para>Behavior is undefined if the two containers don't have
+ equivalent equality predicates.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> Value<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Hash<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Pred<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Alloc<phrase role="special">></phrase>
+ <phrase role="keyword">bool</phrase> <anchor id="boost.unordered_multiset.operator!=_id1"/><phrase role="keyword">operator</phrase><phrase role="special">!=</phrase><phrase role="special">(</phrase><phrase role="identifier">unordered_multiset</phrase><phrase role="special"><</phrase><phrase role="identifier">Value</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> x<phrase role="special">,</phrase>
+ <phrase role="identifier">unordered_multiset</phrase><phrase role="special"><</phrase><phrase role="identifier">Value</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> y<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Notes:</term><listitem><para>This is a boost extension.</para><para>Behavior is undefined if the two containers don't have
+ equivalent equality predicates.</para></listitem></varlistentry></variablelist></listitem></orderedlist></refsect2><refsect2><title><anchor id="id138-bb"/><computeroutput>unordered_multiset</computeroutput> swap</title><orderedlist><listitem><para><literallayout class="monospaced"><phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> Value<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Hash<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Pred<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Alloc<phrase role="special">></phrase>
+ <phrase role="keyword">void</phrase> <anchor id="boost.unordered_multiset.swap_id1"/><phrase role="identifier">swap</phrase><phrase role="special">(</phrase><phrase role="identifier">unordered_multiset</phrase><phrase role="special"><</phrase><phrase role="identifier">Value</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase><phrase role="special">&</phrase> x<phrase role="special">,</phrase>
+ <phrase role="identifier">unordered_multiset</phrase><phrase role="special"><</phrase><phrase role="identifier">Value</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase><phrase role="special">&</phrase> y<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Effects:</term><listitem><para><computeroutput>x.swap(y)</computeroutput></para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><para>If the allocators are equal, doesn't throw an exception unless it is thrown by the copy constructor or copy assignment operator of <computeroutput>Hash</computeroutput> or <computeroutput>Pred</computeroutput>.</para></listitem></varlistentry><varlistentry><term>Notes:</term><listitem><para>For a discussion of the behavior when allocators aren't equal see
+ <link linkend="unordered.rationale.swapping_containers_with_unequal_allocators">the implementation details</link>.</para></listitem></varlistentry></variablelist></listitem></orderedlist></refsect2></refsect1></refentry>
+ </section>
+ <section id="header.boost.unordered_map_hpp"><title>Header <<ulink url="../../boost/unordered_map.hpp">boost/unordered_map.hpp</ulink>></title><synopsis xmlns:xi="http://www.w3.org/2001/XInclude"><phrase role="keyword">namespace</phrase> <phrase role="identifier">boost</phrase> <phrase role="special">{</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> Key<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Mapped<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Hash <phrase role="special">=</phrase> <phrase role="identifier">boost</phrase><phrase role="special">::</phrase><phrase role="identifier">hash</phrase><phrase role="special"><</phrase><phrase role="identifier">Key</phrase><phrase role="special">></phrase><phrase role="special">,</phrase>
+ <phrase role="keyword">typename</phrase> Pred <phrase role="special">=</phrase> <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">equal_to</phrase><phrase role="special"><</phrase><phrase role="identifier">Key</phrase><phrase role="special">></phrase><phrase role="special">,</phrase>
+ <phrase role="keyword">typename</phrase> Alloc <phrase role="special">=</phrase> <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">allocator</phrase><phrase role="special"><</phrase><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">pair</phrase><phrase role="special"><</phrase><phrase role="identifier">Key</phrase> <phrase role="keyword">const</phrase><phrase role="special">,</phrase> <phrase role="identifier">Mapped</phrase><phrase role="special">></phrase> <phrase role="special">></phrase> <phrase role="special">></phrase>
+ <phrase role="keyword">class</phrase> <link linkend="boost.unordered_map">unordered_map</link><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> Key<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Mapped<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Hash<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Pred<phrase role="special">,</phrase>
+ <phrase role="keyword">typename</phrase> Alloc<phrase role="special">></phrase>
+ <phrase role="keyword">bool</phrase> <link linkend="boost.unordered_map.operator==_id1"><phrase role="keyword">operator</phrase><phrase role="special">==</phrase></link><phrase role="special">(</phrase><phrase role="identifier">unordered_map</phrase><phrase role="special"><</phrase><phrase role="identifier">Key</phrase><phrase role="special">,</phrase> <phrase role="identifier">Mapped</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">unordered_map</phrase><phrase role="special"><</phrase><phrase role="identifier">Key</phrase><phrase role="special">,</phrase> <phrase role="identifier">Mapped</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> Key<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Mapped<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Hash<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Pred<phrase role="special">,</phrase>
+ <phrase role="keyword">typename</phrase> Alloc<phrase role="special">></phrase>
+ <phrase role="keyword">bool</phrase> <link linkend="boost.unordered_map.operator!=_id1"><phrase role="keyword">operator</phrase><phrase role="special">!=</phrase></link><phrase role="special">(</phrase><phrase role="identifier">unordered_map</phrase><phrase role="special"><</phrase><phrase role="identifier">Key</phrase><phrase role="special">,</phrase> <phrase role="identifier">Mapped</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">unordered_map</phrase><phrase role="special"><</phrase><phrase role="identifier">Key</phrase><phrase role="special">,</phrase> <phrase role="identifier">Mapped</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> Key<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Mapped<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Hash<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Pred<phrase role="special">,</phrase>
+ <phrase role="keyword">typename</phrase> Alloc<phrase role="special">></phrase>
+ <phrase role="keyword">void</phrase> <link linkend="boost.unordered_map.swap_id1"><phrase role="identifier">swap</phrase></link><phrase role="special">(</phrase><phrase role="identifier">unordered_map</phrase><phrase role="special"><</phrase><phrase role="identifier">Key</phrase><phrase role="special">,</phrase> <phrase role="identifier">Mapped</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase><phrase role="special">&</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">unordered_map</phrase><phrase role="special"><</phrase><phrase role="identifier">Key</phrase><phrase role="special">,</phrase> <phrase role="identifier">Mapped</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> Key<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Mapped<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Hash <phrase role="special">=</phrase> <phrase role="identifier">boost</phrase><phrase role="special">::</phrase><phrase role="identifier">hash</phrase><phrase role="special"><</phrase><phrase role="identifier">Key</phrase><phrase role="special">></phrase><phrase role="special">,</phrase>
+ <phrase role="keyword">typename</phrase> Pred <phrase role="special">=</phrase> <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">equal_to</phrase><phrase role="special"><</phrase><phrase role="identifier">Key</phrase><phrase role="special">></phrase><phrase role="special">,</phrase>
+ <phrase role="keyword">typename</phrase> Alloc <phrase role="special">=</phrase> <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">allocator</phrase><phrase role="special"><</phrase><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">pair</phrase><phrase role="special"><</phrase><phrase role="identifier">Key</phrase> <phrase role="keyword">const</phrase><phrase role="special">,</phrase> <phrase role="identifier">Mapped</phrase><phrase role="special">></phrase> <phrase role="special">></phrase> <phrase role="special">></phrase>
+ <phrase role="keyword">class</phrase> <link linkend="boost.unordered_multimap">unordered_multimap</link><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> Key<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Mapped<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Hash<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Pred<phrase role="special">,</phrase>
+ <phrase role="keyword">typename</phrase> Alloc<phrase role="special">></phrase>
+ <phrase role="keyword">bool</phrase> <link linkend="boost.unordered_multimap.operator==_id1"><phrase role="keyword">operator</phrase><phrase role="special">==</phrase></link><phrase role="special">(</phrase><phrase role="identifier">unordered_multimap</phrase><phrase role="special"><</phrase><phrase role="identifier">Key</phrase><phrase role="special">,</phrase> <phrase role="identifier">Mapped</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">unordered_multimap</phrase><phrase role="special"><</phrase><phrase role="identifier">Key</phrase><phrase role="special">,</phrase> <phrase role="identifier">Mapped</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> Key<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Mapped<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Hash<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Pred<phrase role="special">,</phrase>
+ <phrase role="keyword">typename</phrase> Alloc<phrase role="special">></phrase>
+ <phrase role="keyword">bool</phrase> <link linkend="boost.unordered_multimap.operator!=_id1"><phrase role="keyword">operator</phrase><phrase role="special">!=</phrase></link><phrase role="special">(</phrase><phrase role="identifier">unordered_multimap</phrase><phrase role="special"><</phrase><phrase role="identifier">Key</phrase><phrase role="special">,</phrase> <phrase role="identifier">Mapped</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">unordered_multimap</phrase><phrase role="special"><</phrase><phrase role="identifier">Key</phrase><phrase role="special">,</phrase> <phrase role="identifier">Mapped</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> Key<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Mapped<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Hash<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Pred<phrase role="special">,</phrase>
+ <phrase role="keyword">typename</phrase> Alloc<phrase role="special">></phrase>
+ <phrase role="keyword">void</phrase> <link linkend="boost.unordered_multimap.swap_id1"><phrase role="identifier">swap</phrase></link><phrase role="special">(</phrase><phrase role="identifier">unordered_multimap</phrase><phrase role="special"><</phrase><phrase role="identifier">Key</phrase><phrase role="special">,</phrase> <phrase role="identifier">Mapped</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase><phrase role="special">&</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">unordered_multimap</phrase><phrase role="special"><</phrase><phrase role="identifier">Key</phrase><phrase role="special">,</phrase> <phrase role="identifier">Mapped</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="special">}</phrase></synopsis>
+ <refentry xmlns:xi="http://www.w3.org/2001/XInclude" id="boost.unordered_map"><refmeta><refentrytitle>Class template unordered_map</refentrytitle><manvolnum>3</manvolnum></refmeta><refnamediv><refname>boost::unordered_map</refname><refpurpose>
+ An unordered associative container that associates unique keys with another value.
+ </refpurpose></refnamediv><refsynopsisdiv><synopsis><phrase role="comment">// In header: <<link linkend="header.boost.unordered_map_hpp">boost/unordered_map.hpp</link>>
+
+</phrase><phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> Key<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Mapped<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Hash <phrase role="special">=</phrase> <phrase role="identifier">boost</phrase><phrase role="special">::</phrase><phrase role="identifier">hash</phrase><phrase role="special"><</phrase><phrase role="identifier">Key</phrase><phrase role="special">></phrase><phrase role="special">,</phrase>
+ <phrase role="keyword">typename</phrase> Pred <phrase role="special">=</phrase> <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">equal_to</phrase><phrase role="special"><</phrase><phrase role="identifier">Key</phrase><phrase role="special">></phrase><phrase role="special">,</phrase>
+ <phrase role="keyword">typename</phrase> Alloc <phrase role="special">=</phrase> <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">allocator</phrase><phrase role="special"><</phrase><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">pair</phrase><phrase role="special"><</phrase><phrase role="identifier">Key</phrase> <phrase role="keyword">const</phrase><phrase role="special">,</phrase> <phrase role="identifier">Mapped</phrase><phrase role="special">></phrase> <phrase role="special">></phrase> <phrase role="special">></phrase>
+<phrase role="keyword">class</phrase> <link linkend="boost.unordered_map">unordered_map</link> <phrase role="special">{</phrase>
+<phrase role="keyword">public</phrase><phrase role="special">:</phrase>
+ <phrase role="comment">// <link linkend="boost.unordered_maptypes">types</link></phrase>
+ <phrase role="keyword">typedef</phrase> <phrase role="identifier">Key</phrase> <anchor id="boost.unordered_map.key_type"/><phrase role="identifier">key_type</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">typedef</phrase> <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">pair</phrase><phrase role="special"><</phrase><phrase role="identifier">Key</phrase> <phrase role="keyword">const</phrase><phrase role="special">,</phrase> <phrase role="identifier">Mapped</phrase><phrase role="special">></phrase> <anchor id="boost.unordered_map.value_type"/><phrase role="identifier">value_type</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">typedef</phrase> <phrase role="identifier">Mapped</phrase> <anchor id="boost.unordered_map.mapped_type"/><phrase role="identifier">mapped_type</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">typedef</phrase> <phrase role="identifier">Hash</phrase> <anchor id="boost.unordered_map.hasher"/><phrase role="identifier">hasher</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">typedef</phrase> <phrase role="identifier">Pred</phrase> <anchor id="boost.unordered_map.key_equal"/><phrase role="identifier">key_equal</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">typedef</phrase> <phrase role="identifier">Alloc</phrase> <anchor id="boost.unordered_map.allocator_type"/><phrase role="identifier">allocator_type</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">typedef</phrase> <phrase role="keyword">typename</phrase> <phrase role="identifier">allocator_type</phrase><phrase role="special">::</phrase><phrase role="identifier">pointer</phrase> <anchor id="boost.unordered_map.pointer"/><phrase role="identifier">pointer</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">typedef</phrase> <phrase role="keyword">typename</phrase> <phrase role="identifier">allocator_type</phrase><phrase role="special">::</phrase><phrase role="identifier">const_pointer</phrase> <anchor id="boost.unordered_map.const_pointer"/><phrase role="identifier">const_pointer</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">typedef</phrase> <phrase role="keyword">typename</phrase> <phrase role="identifier">allocator_type</phrase><phrase role="special">::</phrase><phrase role="identifier">reference</phrase> <anchor id="boost.unordered_map.reference"/><phrase role="identifier">reference</phrase><phrase role="special">;</phrase> <phrase role="comment">// lvalue of value_type.</phrase>
+ <phrase role="keyword">typedef</phrase> <phrase role="keyword">typename</phrase> <phrase role="identifier">allocator_type</phrase><phrase role="special">::</phrase><phrase role="identifier">const_reference</phrase> <anchor id="boost.unordered_map.const_reference"/><phrase role="identifier">const_reference</phrase><phrase role="special">;</phrase> <phrase role="comment">// const lvalue of value_type.</phrase>
+ <phrase role="keyword">typedef</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis> <link linkend="boost.unordered_map.size_type"><phrase role="identifier">size_type</phrase></link><phrase role="special">;</phrase>
+ <phrase role="keyword">typedef</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis> <link linkend="boost.unordered_map.difference_type"><phrase role="identifier">difference_type</phrase></link><phrase role="special">;</phrase>
+ <phrase role="keyword">typedef</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis> <link linkend="boost.unordered_map.iterator"><phrase role="identifier">iterator</phrase></link><phrase role="special">;</phrase>
+ <phrase role="keyword">typedef</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis> <link linkend="boost.unordered_map.const_iterator"><phrase role="identifier">const_iterator</phrase></link><phrase role="special">;</phrase>
+ <phrase role="keyword">typedef</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis> <link linkend="boost.unordered_map.local_iterator"><phrase role="identifier">local_iterator</phrase></link><phrase role="special">;</phrase>
+ <phrase role="keyword">typedef</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis> <link linkend="boost.unordered_map.const_local_iterator"><phrase role="identifier">const_local_iterator</phrase></link><phrase role="special">;</phrase>
+
+ <phrase role="comment">// <link linkend="boost.unordered_mapconstruct-copy-destruct">construct/copy/destruct</link></phrase>
+ <phrase role="keyword">explicit</phrase> <link linkend="id139-bb"><phrase role="identifier">unordered_map</phrase></link><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase> <phrase role="special">=</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis><phrase role="special">,</phrase>
+ <phrase role="identifier">hasher</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> <phrase role="special">=</phrase> <phrase role="identifier">hasher</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">key_equal</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> <phrase role="special">=</phrase> <phrase role="identifier">key_equal</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">allocator_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> <phrase role="special">=</phrase> <phrase role="identifier">allocator_type</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> InputIterator<phrase role="special">></phrase>
+ <link linkend="id140-bb"><phrase role="identifier">unordered_map</phrase></link><phrase role="special">(</phrase><phrase role="identifier">InputIterator</phrase><phrase role="special">,</phrase> <phrase role="identifier">InputIterator</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">size_type</phrase> <phrase role="special">=</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis><phrase role="special">,</phrase>
+ <phrase role="identifier">hasher</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> <phrase role="special">=</phrase> <phrase role="identifier">hasher</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">,</phrase> <phrase role="identifier">key_equal</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> <phrase role="special">=</phrase> <phrase role="identifier">key_equal</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">allocator_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> <phrase role="special">=</phrase> <phrase role="identifier">allocator_type</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <link linkend="id141-bb"><phrase role="identifier">unordered_map</phrase></link><phrase role="special">(</phrase><phrase role="identifier">unordered_map</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <link linkend="id142-bb"><phrase role="identifier">unordered_map</phrase></link><phrase role="special">(</phrase><phrase role="identifier">unordered_map</phrase> <phrase role="special">&&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">explicit</phrase> <link linkend="id143-bb"><phrase role="identifier">unordered_map</phrase></link><phrase role="special">(</phrase><phrase role="identifier">Allocator</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <link linkend="id144-bb"><phrase role="identifier">unordered_map</phrase></link><phrase role="special">(</phrase><phrase role="identifier">unordered_map</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">,</phrase> <phrase role="identifier">Allocator</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <link linkend="id145-bb"><phrase role="special">~</phrase><phrase role="identifier">unordered_map</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">unordered_map</phrase><phrase role="special">&</phrase> <link linkend="id146-bb"><phrase role="keyword">operator</phrase><phrase role="special">=</phrase></link><phrase role="special">(</phrase><phrase role="identifier">unordered_map</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">unordered_map</phrase><phrase role="special">&</phrase> <link linkend="id147-bb"><phrase role="keyword">operator</phrase><phrase role="special">=</phrase></link><phrase role="special">(</phrase><phrase role="identifier">unordered_map</phrase> <phrase role="special">&&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">allocator_type</phrase> <link linkend="id148-bb"><phrase role="identifier">get_allocator</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+
+ <phrase role="comment">// <link linkend="id149-bb">size and capacity</link></phrase>
+ <phrase role="keyword">bool</phrase> <link linkend="id150-bb"><phrase role="identifier">empty</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">size_type</phrase> <link linkend="id151-bb"><phrase role="identifier">size</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">size_type</phrase> <link linkend="id152-bb"><phrase role="identifier">max_size</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+
+ <phrase role="comment">// <link linkend="id153-bb">iterators</link></phrase>
+ <phrase role="identifier">iterator</phrase> <link linkend="id155-bb"><phrase role="identifier">begin</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">const_iterator</phrase> <link linkend="id156-bb"><phrase role="identifier">begin</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">iterator</phrase> <link linkend="id158-bb"><phrase role="identifier">end</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">const_iterator</phrase> <link linkend="id159-bb"><phrase role="identifier">end</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">const_iterator</phrase> <link linkend="id160-bb"><phrase role="identifier">cbegin</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">const_iterator</phrase> <link linkend="id161-bb"><phrase role="identifier">cend</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+
+ <phrase role="comment">// <link linkend="id162-bb">modifiers</link></phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase><phrase role="special">...</phrase> Args<phrase role="special">></phrase> <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">pair</phrase><phrase role="special"><</phrase><phrase role="identifier">iterator</phrase><phrase role="special">,</phrase> <phrase role="keyword">bool</phrase><phrase role="special">></phrase> <link linkend="id163-bb"><phrase role="identifier">emplace</phrase></link><phrase role="special">(</phrase><phrase role="identifier">Args</phrase><phrase role="special">&&</phrase><phrase role="special">...</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase><phrase role="special">...</phrase> Args<phrase role="special">></phrase> <phrase role="identifier">iterator</phrase> <link linkend="id164-bb"><phrase role="identifier">emplace_hint</phrase></link><phrase role="special">(</phrase><phrase role="identifier">const_iterator</phrase><phrase role="special">,</phrase> <phrase role="identifier">Args</phrase><phrase role="special">&&</phrase><phrase role="special">...</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">pair</phrase><phrase role="special"><</phrase><phrase role="identifier">iterator</phrase><phrase role="special">,</phrase> <phrase role="keyword">bool</phrase><phrase role="special">></phrase> <link linkend="id165-bb"><phrase role="identifier">insert</phrase></link><phrase role="special">(</phrase><phrase role="identifier">value_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">iterator</phrase> <link linkend="id166-bb"><phrase role="identifier">insert</phrase></link><phrase role="special">(</phrase><phrase role="identifier">const_iterator</phrase><phrase role="special">,</phrase> <phrase role="identifier">value_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> InputIterator<phrase role="special">></phrase> <phrase role="keyword">void</phrase> <link linkend="id167-bb"><phrase role="identifier">insert</phrase></link><phrase role="special">(</phrase><phrase role="identifier">InputIterator</phrase><phrase role="special">,</phrase> <phrase role="identifier">InputIterator</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">iterator</phrase> <link linkend="id168-bb"><phrase role="identifier">erase</phrase></link><phrase role="special">(</phrase><phrase role="identifier">const_iterator</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">size_type</phrase> <link linkend="id169-bb"><phrase role="identifier">erase</phrase></link><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">iterator</phrase> <link linkend="id170-bb"><phrase role="identifier">erase</phrase></link><phrase role="special">(</phrase><phrase role="identifier">const_iterator</phrase><phrase role="special">,</phrase> <phrase role="identifier">const_iterator</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">void</phrase> <link linkend="id171-bb"><phrase role="identifier">quick_erase</phrase></link><phrase role="special">(</phrase><phrase role="identifier">const_iterator</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">void</phrase> <link linkend="id172-bb"><phrase role="identifier">erase_return_void</phrase></link><phrase role="special">(</phrase><phrase role="identifier">const_iterator</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">void</phrase> <link linkend="id173-bb"><phrase role="identifier">clear</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">void</phrase> <link linkend="id174-bb"><phrase role="identifier">swap</phrase></link><phrase role="special">(</phrase><phrase role="identifier">unordered_map</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+
+ <phrase role="comment">// <link linkend="id175-bb">observers</link></phrase>
+ <phrase role="identifier">hasher</phrase> <link linkend="id176-bb"><phrase role="identifier">hash_function</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">key_equal</phrase> <link linkend="id177-bb"><phrase role="identifier">key_eq</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+
+ <phrase role="comment">// <link linkend="id178-bb">lookup</link></phrase>
+ <phrase role="identifier">iterator</phrase> <link linkend="id180-bb"><phrase role="identifier">find</phrase></link><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">const_iterator</phrase> <link linkend="id181-bb"><phrase role="identifier">find</phrase></link><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> CompatibleKey<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> CompatibleHash<phrase role="special">,</phrase>
+ <phrase role="keyword">typename</phrase> CompatiblePredicate<phrase role="special">></phrase>
+ <phrase role="identifier">iterator</phrase> <link linkend="id182-bb"><phrase role="identifier">find</phrase></link><phrase role="special">(</phrase><phrase role="identifier">CompatibleKey</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">,</phrase> <phrase role="identifier">CompatibleHash</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">CompatiblePredicate</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> CompatibleKey<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> CompatibleHash<phrase role="special">,</phrase>
+ <phrase role="keyword">typename</phrase> CompatiblePredicate<phrase role="special">></phrase>
+ <phrase role="identifier">const_iterator</phrase>
+ <link linkend="id183-bb"><phrase role="identifier">find</phrase></link><phrase role="special">(</phrase><phrase role="identifier">CompatibleKey</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">,</phrase> <phrase role="identifier">CompatibleHash</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">CompatiblePredicate</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">size_type</phrase> <link linkend="id184-bb"><phrase role="identifier">count</phrase></link><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">pair</phrase><phrase role="special"><</phrase><phrase role="identifier">iterator</phrase><phrase role="special">,</phrase> <phrase role="identifier">iterator</phrase><phrase role="special">></phrase> <link linkend="id186-bb"><phrase role="identifier">equal_range</phrase></link><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">pair</phrase><phrase role="special"><</phrase><phrase role="identifier">const_iterator</phrase><phrase role="special">,</phrase> <phrase role="identifier">const_iterator</phrase><phrase role="special">></phrase> <link linkend="id187-bb"><phrase role="identifier">equal_range</phrase></link><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">mapped_type</phrase><phrase role="special">&</phrase> <link linkend="id188-bb"><phrase role="keyword">operator</phrase><phrase role="special">[</phrase><phrase role="special">]</phrase></link><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">Mapped</phrase><phrase role="special">&</phrase> <link linkend="id190-bb"><phrase role="identifier">at</phrase></link><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">Mapped</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> <link linkend="id191-bb"><phrase role="identifier">at</phrase></link><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+
+ <phrase role="comment">// <link linkend="id192-bb">bucket interface</link></phrase>
+ <phrase role="identifier">size_type</phrase> <link linkend="id193-bb"><phrase role="identifier">bucket_count</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">size_type</phrase> <link linkend="id194-bb"><phrase role="identifier">max_bucket_count</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">size_type</phrase> <link linkend="id195-bb"><phrase role="identifier">bucket_size</phrase></link><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">size_type</phrase> <link linkend="id196-bb"><phrase role="identifier">bucket</phrase></link><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">local_iterator</phrase> <link linkend="id198-bb"><phrase role="identifier">begin</phrase></link><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">const_local_iterator</phrase> <link linkend="id199-bb"><phrase role="identifier">begin</phrase></link><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">local_iterator</phrase> <link linkend="id201-bb"><phrase role="identifier">end</phrase></link><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">const_local_iterator</phrase> <link linkend="id202-bb"><phrase role="identifier">end</phrase></link><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">const_local_iterator</phrase> <link linkend="id203-bb"><phrase role="identifier">cbegin</phrase></link><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">const_local_iterator</phrase> <link linkend="id204-bb"><phrase role="identifier">cend</phrase></link><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+
+ <phrase role="comment">// <link linkend="id205-bb">hash policy</link></phrase>
+ <phrase role="keyword">float</phrase> <link linkend="id206-bb"><phrase role="identifier">load_factor</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">float</phrase> <link linkend="id207-bb"><phrase role="identifier">max_load_factor</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">void</phrase> <link linkend="id208-bb"><phrase role="identifier">max_load_factor</phrase></link><phrase role="special">(</phrase><phrase role="keyword">float</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">void</phrase> <link linkend="id209-bb"><phrase role="identifier">rehash</phrase></link><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="special">}</phrase><phrase role="special">;</phrase>
+
+<phrase role="comment">// <link linkend="id210-bb">Equality Comparisons</link></phrase>
+<phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> Key<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Mapped<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Hash<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Pred<phrase role="special">,</phrase>
+ <phrase role="keyword">typename</phrase> Alloc<phrase role="special">></phrase>
+ <phrase role="keyword">bool</phrase> <link linkend="boost.unordered_map.operator==_id1"><phrase role="keyword">operator</phrase><phrase role="special">==</phrase></link><phrase role="special">(</phrase><phrase role="identifier">unordered_map</phrase><phrase role="special"><</phrase><phrase role="identifier">Key</phrase><phrase role="special">,</phrase> <phrase role="identifier">Mapped</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">unordered_map</phrase><phrase role="special"><</phrase><phrase role="identifier">Key</phrase><phrase role="special">,</phrase> <phrase role="identifier">Mapped</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> Key<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Mapped<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Hash<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Pred<phrase role="special">,</phrase>
+ <phrase role="keyword">typename</phrase> Alloc<phrase role="special">></phrase>
+ <phrase role="keyword">bool</phrase> <link linkend="boost.unordered_map.operator!=_id1"><phrase role="keyword">operator</phrase><phrase role="special">!=</phrase></link><phrase role="special">(</phrase><phrase role="identifier">unordered_map</phrase><phrase role="special"><</phrase><phrase role="identifier">Key</phrase><phrase role="special">,</phrase> <phrase role="identifier">Mapped</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">unordered_map</phrase><phrase role="special"><</phrase><phrase role="identifier">Key</phrase><phrase role="special">,</phrase> <phrase role="identifier">Mapped</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+
+<phrase role="comment">// <link linkend="id211-bb">swap</link></phrase>
+<phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> Key<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Mapped<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Hash<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Pred<phrase role="special">,</phrase>
+ <phrase role="keyword">typename</phrase> Alloc<phrase role="special">></phrase>
+ <phrase role="keyword">void</phrase> <link linkend="boost.unordered_map.swap_id1"><phrase role="identifier">swap</phrase></link><phrase role="special">(</phrase><phrase role="identifier">unordered_map</phrase><phrase role="special"><</phrase><phrase role="identifier">Key</phrase><phrase role="special">,</phrase> <phrase role="identifier">Mapped</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase><phrase role="special">&</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">unordered_map</phrase><phrase role="special"><</phrase><phrase role="identifier">Key</phrase><phrase role="special">,</phrase> <phrase role="identifier">Mapped</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase></synopsis></refsynopsisdiv><refsect1><title>Description</title>
+ <para>Based on chapter 23 of
+ <ulink url="http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2009/n2960.pdf">the working draft of the C++ standard [n2960]</ulink>.
+ But without the updated rules for allocators.
+ </para>
+ <para><emphasis role="bold">Template Parameters</emphasis>
+ <informaltable>
+ <tgroup cols="2">
+ <tbody>
+ <row>
+ <entry><emphasis>Key</emphasis></entry>
+ <entry>Key must be Assignable and CopyConstructible.</entry></row>
+ <row>
+ <entry><emphasis>Mapped</emphasis></entry>
+ <entry>Mapped must be CopyConstructible</entry></row>
+ <row>
+ <entry><emphasis>Hash</emphasis></entry>
+ <entry>A unary function object type that acts a hash function for a <computeroutput>Key</computeroutput>. It takes a single argument of type <computeroutput>Key</computeroutput> and returns a value of type std::size_t.</entry></row>
+ <row>
+ <entry><emphasis>Pred</emphasis></entry>
+ <entry>A binary function object that implements an equivalence relation on values of type <computeroutput>Key</computeroutput>.
+ A binary function object that induces an equivalence relation on values of type Key.
+ It takes two arguments of type Key and returns a value of type bool.</entry></row>
+ <row>
+ <entry><emphasis>Alloc</emphasis></entry>
+ <entry>An allocator whose value type is the same as the container's value type.</entry></row></tbody></tgroup></informaltable></para>
+ <para>The elements are organized into buckets. Keys with the same hash code are stored in the same bucket.</para>
+ <para>The number of buckets can be automatically increased by a call to insert, or as the result of calling rehash.</para>
+ <refsect2><title><anchor id="boost.unordered_maptypes"/><computeroutput>unordered_map</computeroutput>
+ public
+ types</title><orderedlist><listitem><para>
+<phrase role="keyword">typedef</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis> <anchor id="boost.unordered_map.size_type"/><phrase role="identifier">size_type</phrase><phrase role="special">;</phrase></para>
+ <para>An unsigned integral type.</para>
+ <para>size_type can represent any non-negative value of difference_type.</para>
+ </listitem><listitem><para>
+<phrase role="keyword">typedef</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis> <anchor id="boost.unordered_map.difference_type"/><phrase role="identifier">difference_type</phrase><phrase role="special">;</phrase></para>
+ <para>A signed integral type.</para>
+ <para>Is identical to the difference type of iterator and const_iterator.</para>
+ </listitem><listitem><para>
+<phrase role="keyword">typedef</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis> <anchor id="boost.unordered_map.iterator"/><phrase role="identifier">iterator</phrase><phrase role="special">;</phrase></para>
+ <para>A iterator whose value type is value_type. </para>
+ <para>The iterator category is at least a forward iterator.</para>
+ <para>Convertible to const_iterator.</para>
+ </listitem><listitem><para>
+<phrase role="keyword">typedef</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis> <anchor id="boost.unordered_map.const_iterator"/><phrase role="identifier">const_iterator</phrase><phrase role="special">;</phrase></para>
+ <para>A constant iterator whose value type is value_type. </para>
+ <para>The iterator category is at least a forward iterator.</para>
+ </listitem><listitem><para>
+<phrase role="keyword">typedef</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis> <anchor id="boost.unordered_map.local_iterator"/><phrase role="identifier">local_iterator</phrase><phrase role="special">;</phrase></para>
+ <para>An iterator with the same value type, difference type and pointer and reference type as iterator.</para>
+ <para>A local_iterator object can be used to iterate through a single bucket.</para>
+ </listitem><listitem><para>
+<phrase role="keyword">typedef</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis> <anchor id="boost.unordered_map.const_local_iterator"/><phrase role="identifier">const_local_iterator</phrase><phrase role="special">;</phrase></para>
+ <para>A constant iterator with the same value type, difference type and pointer and reference type as const_iterator.</para>
+ <para>A const_local_iterator object can be used to iterate through a single bucket.</para>
+ </listitem></orderedlist></refsect2><refsect2><title><anchor id="boost.unordered_mapconstruct-copy-destruct"/><computeroutput>unordered_map</computeroutput>
+ public
+ construct/copy/destruct</title><orderedlist><listitem><para><literallayout class="monospaced"><phrase role="keyword">explicit</phrase> <anchor id="id139-bb"/><phrase role="identifier">unordered_map</phrase><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase> n <phrase role="special">=</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis><phrase role="special">,</phrase>
+ <phrase role="identifier">hasher</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> hf <phrase role="special">=</phrase> <phrase role="identifier">hasher</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">key_equal</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> eq <phrase role="special">=</phrase> <phrase role="identifier">key_equal</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">allocator_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> a <phrase role="special">=</phrase> <phrase role="identifier">allocator_type</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Constructs an empty container with at least n buckets, using hf as the hash function, eq as the key equality predicate, a as the allocator and a maximum load factor of 1.0.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Postconditions:</term><listitem><computeroutput><link linkend="id151-bb">size</link>() == 0</computeroutput></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> InputIterator<phrase role="special">></phrase>
+ <anchor id="id140-bb"/><phrase role="identifier">unordered_map</phrase><phrase role="special">(</phrase><phrase role="identifier">InputIterator</phrase> f<phrase role="special">,</phrase> <phrase role="identifier">InputIterator</phrase> l<phrase role="special">,</phrase>
+ <phrase role="identifier">size_type</phrase> n <phrase role="special">=</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis><phrase role="special">,</phrase>
+ <phrase role="identifier">hasher</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> hf <phrase role="special">=</phrase> <phrase role="identifier">hasher</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">key_equal</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> eq <phrase role="special">=</phrase> <phrase role="identifier">key_equal</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">allocator_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> a <phrase role="special">=</phrase> <phrase role="identifier">allocator_type</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Constructs an empty container with at least n buckets, using hf as the hash function, eq as the key equality predicate, a as the allocator and a maximum load factor of 1.0 and inserts the elements from [f, l) into it.</para></listitem><listitem><para><literallayout class="monospaced"><anchor id="id141-bb"/><phrase role="identifier">unordered_map</phrase><phrase role="special">(</phrase><phrase role="identifier">unordered_map</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>The copy constructor. Copies
the contained elements, hash function, predicate, maximum load factor and allocator.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Requires:</term><listitem><para><computeroutput>value_type</computeroutput> is copy constructible</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><anchor id="id142-bb"/><phrase role="identifier">unordered_map</phrase><phrase role="special">(</phrase><phrase role="identifier">unordered_map</phrase> <phrase role="special">&&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>The move constructor.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Notes:</term><listitem><para>This is emulated on compilers without rvalue references.</para></listitem></varlistentry><varlistentry><term>Requires:</term><listitem><para>
+ <computeroutput>value_type</computeroutput> is move constructible.
+ (TODO: This is not actually required in this implementation).
+ </para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="keyword">explicit</phrase> <anchor id="id143-bb"/><phrase role="identifier">unordered_map</phrase><phrase role="special">(</phrase><phrase role="identifier">Allocator</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> a<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Constructs an empty container, using allocator <computeroutput>a</computeroutput>.</para></listitem><listitem><para><literallayout class="monospaced"><anchor id="id144-bb"/><phrase role="identifier">unordered_map</phrase><phrase role="special">(</phrase><phrase role="identifier">unordered_map</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> x<phrase role="special">,</phrase> <phrase role="identifier">Allocator</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> a<phr
ase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Constructs an container, copying <computeroutput>x</computeroutput>'s contained elements, hash function, predicate, maximum load factor, but using allocator <computeroutput>a</computeroutput>.</para></listitem><listitem><para><literallayout class="monospaced"><anchor id="id145-bb"/><phrase role="special">~</phrase><phrase role="identifier">unordered_map</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Notes:</term><listitem><para>The destructor is applied to every element, and all memory is deallocated</para></listitem></varlistentry></variablelist></listitem></orderedlist></refsect2><para><literallayout class="monospaced"><phrase role="identifier">unordered_map</phrase><phrase role="special">&</phrase> <anchor id="id146-bb"/><phrase role="keyword">operator</phrase><phrase role="special">=</phrase><phrase role="special">(</phrase><phrase role="identifier">unordered_map</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>The assignment operator. Copies the contained elements, hash function, predicate and maximum load factor but not the allocator.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Notes:</term><listitem><para>
+ On compilers without rvalue references, there is a single assignment
+ operator with the signature <computeroutput>operator=(unordered_map)</computeroutput>
+ in order to emulate move semantics.
+ </para></listitem></varlistentry><varlistentry><term>Requires:</term><listitem><para><computeroutput>value_type</computeroutput> is copy constructible</para></listitem></varlistentry></variablelist><para><literallayout class="monospaced"><phrase role="identifier">unordered_map</phrase><phrase role="special">&</phrase> <anchor id="id147-bb"/><phrase role="keyword">operator</phrase><phrase role="special">=</phrase><phrase role="special">(</phrase><phrase role="identifier">unordered_map</phrase> <phrase role="special">&&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>The move assignment operator.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Notes:</term><listitem><para>
+ On compilers without rvalue references, there is a single assignment
+ operator with the signature <computeroutput>operator=(unordered_map)</computeroutput>
+ in order to emulate move semantics.
+ </para></listitem></varlistentry><varlistentry><term>Requires:</term><listitem><para>
+ <computeroutput>value_type</computeroutput> is move constructible.
+ (TODO: This is not actually required in this implementation).
+ </para></listitem></varlistentry></variablelist><para><literallayout class="monospaced"><phrase role="identifier">allocator_type</phrase> <anchor id="id148-bb"/><phrase role="identifier">get_allocator</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><refsect2><title><anchor id="id149-bb"/><computeroutput>unordered_map</computeroutput> size and capacity</title><orderedlist><listitem><para><literallayout class="monospaced"><phrase role="keyword">bool</phrase> <anchor id="id150-bb"/><phrase role="identifier">empty</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><computeroutput><link linkend="id151-bb">size</link>() == 0</computeroutput></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">size_type</phrase> <anchor id="id151-bb"/><phrase role="identifier">size</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><computeroutput>std::distance(<link linkend="id154-bb">begin</link>(), <link linkend="id157-bb">end</link>())</computeroutput></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">size_type</phrase> <anchor id="id152-bb"/><phrase role="identifier">max_size</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><computeroutput><link linkend="id151-bb">size</link>()</computeroutput> of the largest possible container.
+ </listitem></varlistentry></variablelist></listitem></orderedlist></refsect2><refsect2><title><anchor id="id153-bb"/><computeroutput>unordered_map</computeroutput> iterators</title><orderedlist><listitem><para><literallayout class="monospaced"><anchor id="id154-bb"/><phrase role="identifier">iterator</phrase> <anchor id="id155-bb"/><phrase role="identifier">begin</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="identifier">const_iterator</phrase> <anchor id="id156-bb"/><phrase role="identifier">begin</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem>An iterator referring to the first element of the container, or if the container is empty the past-the-end value for the container.
+ </listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><anchor id="id157-bb"/><phrase role="identifier">iterator</phrase> <anchor id="id158-bb"/><phrase role="identifier">end</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="identifier">const_iterator</phrase> <anchor id="id159-bb"/><phrase role="identifier">end</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem>An iterator which refers to the past-the-end value for the container.
+ </listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">const_iterator</phrase> <anchor id="id160-bb"/><phrase role="identifier">cbegin</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem>A constant iterator referring to the first element of the container, or if the container is empty the past-the-end value for the container.
+ </listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">const_iterator</phrase> <anchor id="id161-bb"/><phrase role="identifier">cend</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem>A constant iterator which refers to the past-the-end value for the container.
+ </listitem></varlistentry></variablelist></listitem></orderedlist></refsect2><refsect2><title><anchor id="id162-bb"/><computeroutput>unordered_map</computeroutput> modifiers</title><orderedlist><listitem><para><literallayout class="monospaced"><phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase><phrase role="special">...</phrase> Args<phrase role="special">></phrase> <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">pair</phrase><phrase role="special"><</phrase><phrase role="identifier">iterator</phrase><phrase role="special">,</phrase> <phrase role="keyword">bool</phrase><phrase role="special">></phrase> <anchor id="id163-bb"/><phrase role="identifier">emplace</phrase><phrase role="special">(</phrase><phrase role="identifier">Args</phrase><phrase role="special">&&</phrase><phrase role="special">...</phrase> args<phrase role="special">)</phrase><phrase role="special"
>;</phrase></literallayout></para><para>Inserts an object, constructed with the arguments <computeroutput>args</computeroutput>, in the container if and only if there is no element in the container with an equivalent key.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>The bool component of the return type is true if an insert took place.</para><para>If an insert took place, then the iterator points to the newly inserted element. Otherwise, it points to the element with equivalent key.</para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><para>If an exception is thrown by an operation other than a call to <computeroutput>hasher</computeroutput> the function has no effect.</para></listitem></varlistentry><varlistentry><term>Notes:</term><listitem><para>Can invalidate iterators, but only if the insert causes the load factor to be greater to or equal to the maximum load factor.</para><para>Pointers and references to elements are never invalidated.</para><para>If the compiler doesn't support variadic template arguments or rvalue
+ references, this is emulated for up to 10 arguments, with no support
+ for rvalue references or move semantics.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase><phrase role="special">...</phrase> Args<phrase role="special">></phrase>
+ <phrase role="identifier">iterator</phrase> <anchor id="id164-bb"/><phrase role="identifier">emplace_hint</phrase><phrase role="special">(</phrase><phrase role="identifier">const_iterator</phrase> hint<phrase role="special">,</phrase> <phrase role="identifier">Args</phrase><phrase role="special">&&</phrase><phrase role="special">...</phrase> args<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Inserts an object, constructed with the arguments <computeroutput>args</computeroutput>, in the container if and only if there is no element in the container with an equivalent key.</para><para>hint is a suggestion to where the element should be inserted.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>If an insert took place, then the iterator points to the newly inserted element. Otherwise, it points to the element with equivalent key.</para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><para>If an exception is thrown by an operation other than a call to <computeroutput>hasher</computeroutput> the function has no effect.</para></listitem></varlistentry><varlistentry><term>Notes:</term><listitem><para>The standard is fairly vague on the meaning of the hint. But the only practical way to use it, and the only way that Boost.Unordered supports is to point to an existing element with the same key. </para><para>Can invalidate iterators, but only if the insert causes the load factor to be greater to or equal to the maximum load factor.</para><para>Pointers and references to elements are never invalidated.</para><para>If the compiler doesn't support variadic template arguments or rvalue
+ references, this is emulated for up to 10 arguments, with no support
+ for rvalue references or move semantics.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">pair</phrase><phrase role="special"><</phrase><phrase role="identifier">iterator</phrase><phrase role="special">,</phrase> <phrase role="keyword">bool</phrase><phrase role="special">></phrase> <anchor id="id165-bb"/><phrase role="identifier">insert</phrase><phrase role="special">(</phrase><phrase role="identifier">value_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> obj<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Inserts obj in the container if and only if there is no element in the container with an equivalent key.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>The bool component of the return type is true if an insert took place.</para><para>If an insert took place, then the iterator points to the newly inserted element. Otherwise, it points to the element with equivalent key.</para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><para>If an exception is thrown by an operation other than a call to <computeroutput>hasher</computeroutput> the function has no effect.</para></listitem></varlistentry><varlistentry><term>Notes:</term><listitem><para>Can invalidate iterators, but only if the insert causes the load factor to be greater to or equal to the maximum load factor.</para><para>Pointers and references to elements are never invalidated.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">iterator</phrase> <anchor id="id166-bb"/><phrase role="identifier">insert</phrase><phrase role="special">(</phrase>
<phrase role="identifier">const_iterator</phrase> hint<phrase role="special">,</phrase> <phrase role="identifier">value_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> obj<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Inserts obj in the container if and only if there is no element in the container with an equivalent key.</para><para>hint is a suggestion to where the element should be inserted.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>If an insert took place, then the iterator points to the newly inserted element. Otherwise, it points to the element with equivalent key.</para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><para>If an exception is thrown by an operation other than a call to <computeroutput>hasher</computeroutput> the function has no effect.</para></listitem></varlistentry><varlistentry><term>Notes:</term><listitem><para>The standard is fairly vague on the meaning of the hint. But the only practical way to use it, and the only way that Boost.Unordered supports is to point to an existing element with the same key. </para><para>Can invalidate iterators, but only if the insert causes the load factor to be greater to or equal to the maximum load factor.</para><para>Pointers and references to elements are never invalidated.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="k
eyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> InputIterator<phrase role="special">></phrase>
+ <phrase role="keyword">void</phrase> <anchor id="id167-bb"/><phrase role="identifier">insert</phrase><phrase role="special">(</phrase><phrase role="identifier">InputIterator</phrase> first<phrase role="special">,</phrase> <phrase role="identifier">InputIterator</phrase> last<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Inserts a range of elements into the container. Elements are inserted if and only if there is no element in the container with an equivalent key.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Throws:</term><listitem><para>When inserting a single element, if an exception is thrown by an operation other than a call to <computeroutput>hasher</computeroutput> the function has no effect.</para></listitem></varlistentry><varlistentry><term>Notes:</term><listitem><para>Can invalidate iterators, but only if the insert causes the load factor to be greater to or equal to the maximum load factor.</para><para>Pointers and references to elements are never invalidated.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">iterator</phrase> <anchor id="id168-bb"/><phrase role="identifier">erase</phrase><phrase role="special">(</phrase><phrase role="identifier">const_iterator</phrase> position<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Erase the element pointed to by <computeroutput>position</computeroutput>.</para><variablelist spacing="compact"><?dbht
ml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>The iterator following <computeroutput>position</computeroutput> before the erasure.</para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><para>Only throws an exception if it is thrown by <computeroutput>hasher</computeroutput> or <computeroutput>key_equal</computeroutput>.</para><para>In this implementation, this overload doesn't call either function object's methods so it is no throw, but this might not be true in other implementations.</para></listitem></varlistentry><varlistentry><term>Notes:</term><listitem><para>
+ When the number of elements is a lot smaller than the number of buckets
+ this function can be very inefficient as it has to search through empty
+ buckets for the next element, in order to return the iterator.
+ The method <link linkend="id171-bb">quick_erase</link> is faster, but has yet
+ to be standardized.
+ </para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">size_type</phrase> <anchor id="id169-bb"/><phrase role="identifier">erase</phrase><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> k<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Erase all elements with key equivalent to <computeroutput>k</computeroutput>.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>The number of elements erased.</para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><para>Only throws an exception if it is thrown by <computeroutput>hasher</computeroutput> or <computeroutput>key_equal</computeroutput>.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">iterator</phrase> <anchor id="id170-bb"/><phrase role="identifier">erase</phrase><phrase role="special">(</phrase><phrase role="identifier">const_iterator</phrase> first<phrase role="special">,</phrase> <phrase role="identifier">const_iterator</phrase> last<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Erases the elements in the range from <computeroutput>first</computeroutput> to <computeroutput>last</computeroutput>.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>The iterator following the erased elements - i.e. <computeroutput>last</computeroutput>.</para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><para>Only throws an exception if it is thrown by <computeroutput>hasher</computeroutput> or <computeroutput>key_equal</computeroutput>.</para><para>In this implementation, this overload doesn't call either function object's methods so it is no throw, but this might not be true in other implementations.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="keyword">void</phrase> <anchor id="id171-bb"/><phrase role="identifier">quick_erase</phrase><phrase role="special">(</phrase><phrase role="identifier">const_iterator</phrase> position<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Erase the element pointed to by <computeroutput>position</computeroutput>.</para><variablel
ist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Throws:</term><listitem><para>Only throws an exception if it is thrown by <computeroutput>hasher</computeroutput> or <computeroutput>key_equal</computeroutput>.</para><para>In this implementation, this overload doesn't call either function object's methods so it is no throw, but this might not be true in other implementations.</para></listitem></varlistentry><varlistentry><term>Notes:</term><listitem><para>
+ This method is faster than <link linkend="id168-bb">erase</link> as
+ it doesn't have to find the next element in the container -
+ a potentially costly operation.
+ </para><para>
+ As it hasn't been standardized, it's likely that this may
+ change in the future.
+ </para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="keyword">void</phrase> <anchor id="id172-bb"/><phrase role="identifier">erase_return_void</phrase><phrase role="special">(</phrase><phrase role="identifier">const_iterator</phrase> position<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Erase the element pointed to by <computeroutput>position</computeroutput>.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Throws:</term><listitem><para>Only throws an exception if it is thrown by <computeroutput>hasher</computeroutput> or <computeroutput>key_equal</computeroutput>.</para><para>In this implementation, this overload doesn't call either function object's methods so it is no throw, but this might not be true in other implementations.</para></listitem></varlistentry><varlistentry><term>Notes:</term><listitem><para>
+ This method is now deprecated, use
+ quick_return instead. Although be
+ warned that as that isn't standardized yet, it could also
+ change.
+ </para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="keyword">void</phrase> <anchor id="id173-bb"/><phrase role="identifier">clear</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Erases all elements in the container.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Postconditions:</term><listitem><para><computeroutput><link linkend="id151-bb">size</link>() == 0</computeroutput></para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><para>Never throws an exception.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="keyword">void</phrase> <anchor id="id174-bb"/><phrase role="identifier">swap</phrase><phrase role="special">(</phrase><phrase role="identifier">unordered_map</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Throws:</term><listitem><para>If the allocators are equal, doesn't throw an exception unless it is thrown by the copy constructor or copy assignment operator of <computeroutput>key_equal</computeroutput> or <computeroutput>hasher</computeroutput>.</para></listitem></varlistentry><varlistentry><term>Notes:</term><listitem><para>For a discussion of the behavior when allocators aren't equal see
+ <link linkend="unordered.rationale.swapping_containers_with_unequal_allocators">the implementation details</link>.</para></listitem></varlistentry></variablelist></listitem></orderedlist></refsect2><refsect2><title><anchor id="id175-bb"/><computeroutput>unordered_map</computeroutput> observers</title><orderedlist><listitem><para><literallayout class="monospaced"><phrase role="identifier">hasher</phrase> <anchor id="id176-bb"/><phrase role="identifier">hash_function</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem>The container's hash function.
+ </listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">key_equal</phrase> <anchor id="id177-bb"/><phrase role="identifier">key_eq</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem>The container's key equality predicate.
+ </listitem></varlistentry></variablelist></listitem></orderedlist></refsect2><refsect2><title><anchor id="id178-bb"/><computeroutput>unordered_map</computeroutput> lookup</title><orderedlist><listitem><para><literallayout class="monospaced"><anchor id="id179-bb"/><phrase role="identifier">iterator</phrase> <anchor id="id180-bb"/><phrase role="identifier">find</phrase><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> k<phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="identifier">const_iterator</phrase> <anchor id="id181-bb"/><phrase role="identifier">find</phrase><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> k<phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+<phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> CompatibleKey<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> CompatibleHash<phrase role="special">,</phrase>
+ <phrase role="keyword">typename</phrase> CompatiblePredicate<phrase role="special">></phrase>
+ <phrase role="identifier">iterator</phrase> <anchor id="id182-bb"/><phrase role="identifier">find</phrase><phrase role="special">(</phrase><phrase role="identifier">CompatibleKey</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> k<phrase role="special">,</phrase> <phrase role="identifier">CompatibleHash</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> hash<phrase role="special">,</phrase>
+ <phrase role="identifier">CompatiblePredicate</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> eq<phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> CompatibleKey<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> CompatibleHash<phrase role="special">,</phrase>
+ <phrase role="keyword">typename</phrase> CompatiblePredicate<phrase role="special">></phrase>
+ <phrase role="identifier">const_iterator</phrase>
+ <anchor id="id183-bb"/><phrase role="identifier">find</phrase><phrase role="special">(</phrase><phrase role="identifier">CompatibleKey</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> k<phrase role="special">,</phrase> <phrase role="identifier">CompatibleHash</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> hash<phrase role="special">,</phrase>
+ <phrase role="identifier">CompatiblePredicate</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> eq<phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>An iterator pointing to an element with key equivalent to <computeroutput>k</computeroutput>, or <computeroutput>b.end()</computeroutput> if no such element exists.</para></listitem></varlistentry><varlistentry><term>Notes:</term><listitem><para>
+ The templated overloads are a non-standard extensions which
+ allows you to use a compatible hash function and equality
+ predicate for a key of a different type in order to avoid
+ an expensive type cast. In general, its use is not encouraged.
+ </para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">size_type</phrase> <anchor id="id184-bb"/><phrase role="identifier">count</phrase><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> k<phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>The number of elements with key equivalent to <computeroutput>k</computeroutput>.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><anchor id="id185-bb"/><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">pair</phrase><phrase role="special"><</phrase><phrase role="identifier">iterator</phrase><phrase role="special">,</phrase> <phrase role="identifier">iterator</phrase><phrase role="special">></phrase> <anchor id="id186-bb"/><phrase role="identifier">equal_range</phrase><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> k<phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">pair</phrase><phrase role="special"><</phrase><phrase role="identifier">const_iterator</phrase><phrase role="special">,</phrase> <phrase role="identifier">const_iterator</phrase><phrase role="special">></phrase> <anchor id="id187-bb"/><phrase role="identifier">equal_range</phrase><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> k<phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>A range containing all elements with key equivalent to <computeroutput>k</computeroutput>.
+ If the container doesn't container any such elements, returns
+ <computeroutput>std::make_pair(b.end(),b.end())</computeroutput>.
+ </para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">mapped_type</phrase><phrase role="special">&</phrase> <anchor id="id188-bb"/><phrase role="keyword">operator</phrase><phrase role="special">[</phrase><phrase role="special">]</phrase><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> k<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Effects:</term><listitem><para>If the container does not already contain an elements with a key equivalent to <computeroutput>k</computeroutput>, inserts the value <computeroutput>std::pair<key_type const, mapped_type>(k, mapped_type())</computeroutput></para></listitem></varlistentry><varlistentry><term>Returns:</term><listitem><para>A reference to <computeroutput>x.second</computeroutput> where x is the element already in the container, or the newly inserted element with a key equivalent to <computeroutput>k</computeroutput></para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><para>If an exception is thrown by an operation other than a call to <computeroutput>hasher</computeroutput> the function has no effect.</para></listitem></varlistentry><varlistentry><term>Notes:</term><listitem><para>Can invalidate iterators, but only if the insert causes the load factor to be greater to or equal to the maximum load factor.</para><para>Pointers and referenc
es to elements are never invalidated.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><anchor id="id189-bb"/><phrase role="identifier">Mapped</phrase><phrase role="special">&</phrase> <anchor id="id190-bb"/><phrase role="identifier">at</phrase><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> k<phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="identifier">Mapped</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> <anchor id="id191-bb"/><phrase role="identifier">at</phrase><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> k<phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>A reference to <computeroutput>x.second</computeroutput> where <computeroutput>x</computeroutput> is the (unique) element whose key is equivalent to <computeroutput>k</computeroutput>.</para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><para>An exception object of type <computeroutput>std::out_of_range</computeroutput> if no such element is present.</para></listitem></varlistentry><varlistentry><term>Notes:</term><listitem><para>This is not specified in the draft standard, but that is probably an oversight. The issue has been raised in
+ <ulink url="http://groups.google.com/group/comp.std.c++/browse_thread/thread/ab7c22a868fd370b">comp.std.c++</ulink>.</para></listitem></varlistentry></variablelist></listitem></orderedlist></refsect2><refsect2><title><anchor id="id192-bb"/><computeroutput>unordered_map</computeroutput> bucket interface</title><orderedlist><listitem><para><literallayout class="monospaced"><phrase role="identifier">size_type</phrase> <anchor id="id193-bb"/><phrase role="identifier">bucket_count</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>The number of buckets.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">size_type</phrase> <anchor id="id194-bb"/><phrase role="identifier">max_bucket_count</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>An upper bound on the number of buckets.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">size_type</phrase> <anchor id="id195-bb"/><phrase role="identifier">bucket_size</phrase><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase> n<phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Requires:</term><listitem><para><computeroutput>n < <link linkend="id193-bb">bucket_count</link>()</computeroutput></para></listitem></varlistentry><varlistentry><term>Returns:</term><listitem><para>The number of elements in bucket <computeroutput>n</computeroutput>.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">size_type</phrase> <anchor id="id196-bb"/><phrase role="identifier">bucket</phrase><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> k<phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>The index of the bucket which would contain an element with key <computeroutput>k</computeroutput>.</para></listitem></varlistentry><varlistentry><term>Postconditions:</term><listitem><para>The return value is less than <computeroutput>bucket_count()</computeroutput></para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><anchor id="id197-bb"/><phrase role="identifier">local_iterator</phrase> <anchor id="id198-bb"/><phrase role="identifier">begin</phrase><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase> n<phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="identifier">const_local_iterator</phrase> <anchor id="id199-bb"/><phrase role="identifier">begin</phrase><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase> n<phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Requires:</term><listitem><para><computeroutput>n</computeroutput> shall be in the range <computeroutput>[0, bucket_count())</computeroutput>.</para></listitem></varlistentry><varlistentry><term>Returns:</term><listitem><para>A local iterator pointing the first element in the bucket with index <computeroutput>n</computeroutput>.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><anchor id="id200-bb"/><phrase role="identifier">local_iterator</phrase> <anchor id="id201-bb"/><phrase role="identifier">end</phrase><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase> n<phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="identifier">const_local_iterator</phrase> <anchor id="id202-bb"/><phrase role="identifier">end</phrase><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase> n<phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Requires:</term><listitem><para><computeroutput>n</computeroutput> shall be in the range <computeroutput>[0, bucket_count())</computeroutput>.</para></listitem></varlistentry><varlistentry><term>Returns:</term><listitem><para>A local iterator pointing the 'one past the end' element in the bucket with index <computeroutput>n</computeroutput>.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">const_local_iterator</phrase> <anchor id="id203-bb"/><phrase role="identifier">cbegin</phrase><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase> n<phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Requires:</term><listitem><para><computeroutput>n</computeroutput> shall be in the range <computeroutput>[0, bucket_count())</computeroutput>.</para></listitem></varlistentry><varlistentry><term>Returns:</term><listitem><para>A constant local iterator pointing the first element in the bucket with index <computeroutput>n</computeroutput>.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">const_local_iterator</phrase> <anchor id="id204-bb"/><phrase role="identifier">cend</phrase><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase> n<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Requires:</term><listitem><para><computeroutput>n</computeroutput> shall be in the range <computeroutput>[0, bucket_count())</computeroutput>.</para></listitem></varlistentry><varlistentry><term>Returns:</term><listitem><para>A constant local iterator pointing the 'one past the end' element in the bucket with index <computeroutput>n</computeroutput>.</para></listitem></varlistentry></variablelist></listitem></orderedlist></refsect2><refsect2><title><anchor id="id205-bb"/><computeroutput>unordered_map</computeroutput> hash policy</title><orderedlist><listitem><para><literallayout class="monospaced"><phrase role="keyword">float</phrase> <anchor id="id206-bb"/><phrase role="identifier">load_factor</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>The average number of elements per bucket.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="keyword">float</phrase> <anchor id="id207-bb"/><phrase role="identifier">max_load_factor</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>Returns the current maximum load factor.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="keyword">void</phrase> <anchor id="id208-bb"/><phrase role="identifier">max_load_factor</phrase><phrase role="special">(</phrase><phrase role="keyword">float</phrase> z<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Effects:</term><listitem><para>Changes the container's maximum load factor, using <computeroutput>z</computeroutput> as a hint.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="keyword">void</phrase> <anchor id="id209-bb"/><phrase role="identifier">rehash</phrase><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase> n<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Changes the number of buckets so that there at least <computeroutput>n</computeroutput> buckets, and so that the load factor is less than the maximum load factor.</para><para>Invalidates iterators, and changes the order of elements. Pointers and references to elements are not invalidated.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Throws:</term><listitem><para>The function has no effect if an exception is thrown, unless it is thrown by the container's hash function or comparison function.</para></listitem></varlistentry></variablelist></listitem></orderedlist></refsect2><refsect2><title><anchor id="id210-bb"/><computeroutput>unordered_map</computeroutput> Equality Comparisons</title><orderedlist><listitem><para><literallayout class="monospaced"><phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> Key<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Mapped<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Hash<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Pred<phrase role="special">,</phrase>
+ <phrase role="keyword">typename</phrase> Alloc<phrase role="special">></phrase>
+ <phrase role="keyword">bool</phrase> <anchor id="boost.unordered_map.operator==_id1"/><phrase role="keyword">operator</phrase><phrase role="special">==</phrase><phrase role="special">(</phrase><phrase role="identifier">unordered_map</phrase><phrase role="special"><</phrase><phrase role="identifier">Key</phrase><phrase role="special">,</phrase> <phrase role="identifier">Mapped</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> x<phrase role="special">,</phrase>
+ <phrase role="identifier">unordered_map</phrase><phrase role="special"><</phrase><phrase role="identifier">Key</phrase><phrase role="special">,</phrase> <phrase role="identifier">Mapped</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> y<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Notes:</term><listitem><para>This is a boost extension.</para><para>Behavior is undefined if the two containers don't have
+ equivalent equality predicates.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> Key<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Mapped<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Hash<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Pred<phrase role="special">,</phrase>
+ <phrase role="keyword">typename</phrase> Alloc<phrase role="special">></phrase>
+ <phrase role="keyword">bool</phrase> <anchor id="boost.unordered_map.operator!=_id1"/><phrase role="keyword">operator</phrase><phrase role="special">!=</phrase><phrase role="special">(</phrase><phrase role="identifier">unordered_map</phrase><phrase role="special"><</phrase><phrase role="identifier">Key</phrase><phrase role="special">,</phrase> <phrase role="identifier">Mapped</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> x<phrase role="special">,</phrase>
+ <phrase role="identifier">unordered_map</phrase><phrase role="special"><</phrase><phrase role="identifier">Key</phrase><phrase role="special">,</phrase> <phrase role="identifier">Mapped</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> y<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Notes:</term><listitem><para>This is a boost extension.</para><para>Behavior is undefined if the two containers don't have
+ equivalent equality predicates.</para></listitem></varlistentry></variablelist></listitem></orderedlist></refsect2><refsect2><title><anchor id="id211-bb"/><computeroutput>unordered_map</computeroutput> swap</title><orderedlist><listitem><para><literallayout class="monospaced"><phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> Key<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Mapped<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Hash<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Pred<phrase role="special">,</phrase>
+ <phrase role="keyword">typename</phrase> Alloc<phrase role="special">></phrase>
+ <phrase role="keyword">void</phrase> <anchor id="boost.unordered_map.swap_id1"/><phrase role="identifier">swap</phrase><phrase role="special">(</phrase><phrase role="identifier">unordered_map</phrase><phrase role="special"><</phrase><phrase role="identifier">Key</phrase><phrase role="special">,</phrase> <phrase role="identifier">Mapped</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase><phrase role="special">&</phrase> x<phrase role="special">,</phrase>
+ <phrase role="identifier">unordered_map</phrase><phrase role="special"><</phrase><phrase role="identifier">Key</phrase><phrase role="special">,</phrase> <phrase role="identifier">Mapped</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase><phrase role="special">&</phrase> y<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Effects:</term><listitem><para><computeroutput>x.swap(y)</computeroutput></para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><para>If the allocators are equal, doesn't throw an exception unless it is thrown by the copy constructor or copy assignment operator of <computeroutput>Hash</computeroutput> or <computeroutput>Pred</computeroutput>.</para></listitem></varlistentry><varlistentry><term>Notes:</term><listitem><para>For a discussion of the behavior when allocators aren't equal see
+ <link linkend="unordered.rationale.swapping_containers_with_unequal_allocators">the implementation details</link>.</para></listitem></varlistentry></variablelist></listitem></orderedlist></refsect2></refsect1></refentry><refentry xmlns:xi="http://www.w3.org/2001/XInclude" id="boost.unordered_multimap"><refmeta><refentrytitle>Class template unordered_multimap</refentrytitle><manvolnum>3</manvolnum></refmeta><refnamediv><refname>boost::unordered_multimap</refname><refpurpose>
+ An unordered associative container that associates keys with another value. The same key can be stored multiple times.
+ </refpurpose></refnamediv><refsynopsisdiv><synopsis><phrase role="comment">// In header: <<link linkend="header.boost.unordered_map_hpp">boost/unordered_map.hpp</link>>
+
+</phrase><phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> Key<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Mapped<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Hash <phrase role="special">=</phrase> <phrase role="identifier">boost</phrase><phrase role="special">::</phrase><phrase role="identifier">hash</phrase><phrase role="special"><</phrase><phrase role="identifier">Key</phrase><phrase role="special">></phrase><phrase role="special">,</phrase>
+ <phrase role="keyword">typename</phrase> Pred <phrase role="special">=</phrase> <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">equal_to</phrase><phrase role="special"><</phrase><phrase role="identifier">Key</phrase><phrase role="special">></phrase><phrase role="special">,</phrase>
+ <phrase role="keyword">typename</phrase> Alloc <phrase role="special">=</phrase> <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">allocator</phrase><phrase role="special"><</phrase><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">pair</phrase><phrase role="special"><</phrase><phrase role="identifier">Key</phrase> <phrase role="keyword">const</phrase><phrase role="special">,</phrase> <phrase role="identifier">Mapped</phrase><phrase role="special">></phrase> <phrase role="special">></phrase> <phrase role="special">></phrase>
+<phrase role="keyword">class</phrase> <link linkend="boost.unordered_multimap">unordered_multimap</link> <phrase role="special">{</phrase>
+<phrase role="keyword">public</phrase><phrase role="special">:</phrase>
+ <phrase role="comment">// <link linkend="boost.unordered_multimaptypes">types</link></phrase>
+ <phrase role="keyword">typedef</phrase> <phrase role="identifier">Key</phrase> <anchor id="boost.unordered_multimap.key_type"/><phrase role="identifier">key_type</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">typedef</phrase> <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">pair</phrase><phrase role="special"><</phrase><phrase role="identifier">Key</phrase> <phrase role="keyword">const</phrase><phrase role="special">,</phrase> <phrase role="identifier">Mapped</phrase><phrase role="special">></phrase> <anchor id="boost.unordered_multimap.value_type"/><phrase role="identifier">value_type</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">typedef</phrase> <phrase role="identifier">Mapped</phrase> <anchor id="boost.unordered_multimap.mapped_type"/><phrase role="identifier">mapped_type</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">typedef</phrase> <phrase role="identifier">Hash</phrase> <anchor id="boost.unordered_multimap.hasher"/><phrase role="identifier">hasher</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">typedef</phrase> <phrase role="identifier">Pred</phrase> <anchor id="boost.unordered_multimap.key_equal"/><phrase role="identifier">key_equal</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">typedef</phrase> <phrase role="identifier">Alloc</phrase> <anchor id="boost.unordered_multimap.allocator_type"/><phrase role="identifier">allocator_type</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">typedef</phrase> <phrase role="keyword">typename</phrase> <phrase role="identifier">allocator_type</phrase><phrase role="special">::</phrase><phrase role="identifier">pointer</phrase> <anchor id="boost.unordered_multimap.pointer"/><phrase role="identifier">pointer</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">typedef</phrase> <phrase role="keyword">typename</phrase> <phrase role="identifier">allocator_type</phrase><phrase role="special">::</phrase><phrase role="identifier">const_pointer</phrase> <anchor id="boost.unordered_multimap.const_pointer"/><phrase role="identifier">const_pointer</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">typedef</phrase> <phrase role="keyword">typename</phrase> <phrase role="identifier">allocator_type</phrase><phrase role="special">::</phrase><phrase role="identifier">reference</phrase> <anchor id="boost.unordered_multimap.reference"/><phrase role="identifier">reference</phrase><phrase role="special">;</phrase> <phrase role="comment">// lvalue of value_type.</phrase>
+ <phrase role="keyword">typedef</phrase> <phrase role="keyword">typename</phrase> <phrase role="identifier">allocator_type</phrase><phrase role="special">::</phrase><phrase role="identifier">const_reference</phrase> <anchor id="boost.unordered_multimap.const_reference"/><phrase role="identifier">const_reference</phrase><phrase role="special">;</phrase> <phrase role="comment">// const lvalue of value_type.</phrase>
+ <phrase role="keyword">typedef</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis> <link linkend="boost.unordered_multimap.size_type"><phrase role="identifier">size_type</phrase></link><phrase role="special">;</phrase>
+ <phrase role="keyword">typedef</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis> <link linkend="boost.unordered_multimap.difference_type"><phrase role="identifier">difference_type</phrase></link><phrase role="special">;</phrase>
+ <phrase role="keyword">typedef</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis> <link linkend="boost.unordered_multimap.iterator"><phrase role="identifier">iterator</phrase></link><phrase role="special">;</phrase>
+ <phrase role="keyword">typedef</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis> <link linkend="boost.unordered_multimap.const_iterator"><phrase role="identifier">const_iterator</phrase></link><phrase role="special">;</phrase>
+ <phrase role="keyword">typedef</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis> <link linkend="boost.unordered_multimap.local_iterator"><phrase role="identifier">local_iterator</phrase></link><phrase role="special">;</phrase>
+ <phrase role="keyword">typedef</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis> <link linkend="boost.unordered_multimap.const_local_iterator"><phrase role="identifier">const_local_iterator</phrase></link><phrase role="special">;</phrase>
+
+ <phrase role="comment">// <link linkend="boost.unordered_multimapconstruct-copy-destruct">construct/copy/destruct</link></phrase>
+ <phrase role="keyword">explicit</phrase> <link linkend="id212-bb"><phrase role="identifier">unordered_multimap</phrase></link><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase> <phrase role="special">=</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis><phrase role="special">,</phrase>
+ <phrase role="identifier">hasher</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> <phrase role="special">=</phrase> <phrase role="identifier">hasher</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">key_equal</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> <phrase role="special">=</phrase> <phrase role="identifier">key_equal</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">allocator_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> <phrase role="special">=</phrase> <phrase role="identifier">allocator_type</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> InputIterator<phrase role="special">></phrase>
+ <link linkend="id213-bb"><phrase role="identifier">unordered_multimap</phrase></link><phrase role="special">(</phrase><phrase role="identifier">InputIterator</phrase><phrase role="special">,</phrase> <phrase role="identifier">InputIterator</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">size_type</phrase> <phrase role="special">=</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis><phrase role="special">,</phrase>
+ <phrase role="identifier">hasher</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> <phrase role="special">=</phrase> <phrase role="identifier">hasher</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">key_equal</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> <phrase role="special">=</phrase> <phrase role="identifier">key_equal</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">allocator_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> <phrase role="special">=</phrase> <phrase role="identifier">allocator_type</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <link linkend="id214-bb"><phrase role="identifier">unordered_multimap</phrase></link><phrase role="special">(</phrase><phrase role="identifier">unordered_multimap</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <link linkend="id215-bb"><phrase role="identifier">unordered_multimap</phrase></link><phrase role="special">(</phrase><phrase role="identifier">unordered_multimap</phrase> <phrase role="special">&&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">explicit</phrase> <link linkend="id216-bb"><phrase role="identifier">unordered_multimap</phrase></link><phrase role="special">(</phrase><phrase role="identifier">Allocator</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <link linkend="id217-bb"><phrase role="identifier">unordered_multimap</phrase></link><phrase role="special">(</phrase><phrase role="identifier">unordered_multimap</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">,</phrase> <phrase role="identifier">Allocator</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <link linkend="id218-bb"><phrase role="special">~</phrase><phrase role="identifier">unordered_multimap</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">unordered_multimap</phrase><phrase role="special">&</phrase> <link linkend="id219-bb"><phrase role="keyword">operator</phrase><phrase role="special">=</phrase></link><phrase role="special">(</phrase><phrase role="identifier">unordered_multimap</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">unordered_multimap</phrase><phrase role="special">&</phrase> <link linkend="id220-bb"><phrase role="keyword">operator</phrase><phrase role="special">=</phrase></link><phrase role="special">(</phrase><phrase role="identifier">unordered_multimap</phrase> <phrase role="special">&&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">allocator_type</phrase> <link linkend="id221-bb"><phrase role="identifier">get_allocator</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+
+ <phrase role="comment">// <link linkend="id222-bb">size and capacity</link></phrase>
+ <phrase role="keyword">bool</phrase> <link linkend="id223-bb"><phrase role="identifier">empty</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">size_type</phrase> <link linkend="id224-bb"><phrase role="identifier">size</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">size_type</phrase> <link linkend="id225-bb"><phrase role="identifier">max_size</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+
+ <phrase role="comment">// <link linkend="id226-bb">iterators</link></phrase>
+ <phrase role="identifier">iterator</phrase> <link linkend="id228-bb"><phrase role="identifier">begin</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">const_iterator</phrase> <link linkend="id229-bb"><phrase role="identifier">begin</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">iterator</phrase> <link linkend="id231-bb"><phrase role="identifier">end</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">const_iterator</phrase> <link linkend="id232-bb"><phrase role="identifier">end</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">const_iterator</phrase> <link linkend="id233-bb"><phrase role="identifier">cbegin</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">const_iterator</phrase> <link linkend="id234-bb"><phrase role="identifier">cend</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+
+ <phrase role="comment">// <link linkend="id235-bb">modifiers</link></phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase><phrase role="special">...</phrase> Args<phrase role="special">></phrase> <phrase role="identifier">iterator</phrase> <link linkend="id236-bb"><phrase role="identifier">emplace</phrase></link><phrase role="special">(</phrase><phrase role="identifier">Args</phrase><phrase role="special">&&</phrase><phrase role="special">...</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase><phrase role="special">...</phrase> Args<phrase role="special">></phrase> <phrase role="identifier">iterator</phrase> <link linkend="id237-bb"><phrase role="identifier">emplace_hint</phrase></link><phrase role="special">(</phrase><phrase role="identifier">const_iterator</phrase><phrase role="special">,</phrase> <phrase role="identifier">Args</phrase><phrase role="special">&&</phrase><phrase role="special">...</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">iterator</phrase> <link linkend="id238-bb"><phrase role="identifier">insert</phrase></link><phrase role="special">(</phrase><phrase role="identifier">value_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">iterator</phrase> <link linkend="id239-bb"><phrase role="identifier">insert</phrase></link><phrase role="special">(</phrase><phrase role="identifier">const_iterator</phrase><phrase role="special">,</phrase> <phrase role="identifier">value_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> InputIterator<phrase role="special">></phrase> <phrase role="keyword">void</phrase> <link linkend="id240-bb"><phrase role="identifier">insert</phrase></link><phrase role="special">(</phrase><phrase role="identifier">InputIterator</phrase><phrase role="special">,</phrase> <phrase role="identifier">InputIterator</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">iterator</phrase> <link linkend="id241-bb"><phrase role="identifier">erase</phrase></link><phrase role="special">(</phrase><phrase role="identifier">const_iterator</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">size_type</phrase> <link linkend="id242-bb"><phrase role="identifier">erase</phrase></link><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">iterator</phrase> <link linkend="id243-bb"><phrase role="identifier">erase</phrase></link><phrase role="special">(</phrase><phrase role="identifier">const_iterator</phrase><phrase role="special">,</phrase> <phrase role="identifier">const_iterator</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">void</phrase> <link linkend="id244-bb"><phrase role="identifier">quick_erase</phrase></link><phrase role="special">(</phrase><phrase role="identifier">const_iterator</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">void</phrase> <link linkend="id245-bb"><phrase role="identifier">erase_return_void</phrase></link><phrase role="special">(</phrase><phrase role="identifier">const_iterator</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">void</phrase> <link linkend="id246-bb"><phrase role="identifier">clear</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">void</phrase> <link linkend="id247-bb"><phrase role="identifier">swap</phrase></link><phrase role="special">(</phrase><phrase role="identifier">unordered_multimap</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+
+ <phrase role="comment">// <link linkend="id248-bb">observers</link></phrase>
+ <phrase role="identifier">hasher</phrase> <link linkend="id249-bb"><phrase role="identifier">hash_function</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">key_equal</phrase> <link linkend="id250-bb"><phrase role="identifier">key_eq</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+
+ <phrase role="comment">// <link linkend="id251-bb">lookup</link></phrase>
+ <phrase role="identifier">iterator</phrase> <link linkend="id253-bb"><phrase role="identifier">find</phrase></link><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">const_iterator</phrase> <link linkend="id254-bb"><phrase role="identifier">find</phrase></link><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> CompatibleKey<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> CompatibleHash<phrase role="special">,</phrase>
+ <phrase role="keyword">typename</phrase> CompatiblePredicate<phrase role="special">></phrase>
+ <phrase role="identifier">iterator</phrase> <link linkend="id255-bb"><phrase role="identifier">find</phrase></link><phrase role="special">(</phrase><phrase role="identifier">CompatibleKey</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">,</phrase> <phrase role="identifier">CompatibleHash</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">CompatiblePredicate</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> CompatibleKey<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> CompatibleHash<phrase role="special">,</phrase>
+ <phrase role="keyword">typename</phrase> CompatiblePredicate<phrase role="special">></phrase>
+ <phrase role="identifier">const_iterator</phrase>
+ <link linkend="id256-bb"><phrase role="identifier">find</phrase></link><phrase role="special">(</phrase><phrase role="identifier">CompatibleKey</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">,</phrase> <phrase role="identifier">CompatibleHash</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">CompatiblePredicate</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">size_type</phrase> <link linkend="id257-bb"><phrase role="identifier">count</phrase></link><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">pair</phrase><phrase role="special"><</phrase><phrase role="identifier">iterator</phrase><phrase role="special">,</phrase> <phrase role="identifier">iterator</phrase><phrase role="special">></phrase> <link linkend="id259-bb"><phrase role="identifier">equal_range</phrase></link><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">pair</phrase><phrase role="special"><</phrase><phrase role="identifier">const_iterator</phrase><phrase role="special">,</phrase> <phrase role="identifier">const_iterator</phrase><phrase role="special">></phrase> <link linkend="id260-bb"><phrase role="identifier">equal_range</phrase></link><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+
+ <phrase role="comment">// <link linkend="id261-bb">bucket interface</link></phrase>
+ <phrase role="identifier">size_type</phrase> <link linkend="id262-bb"><phrase role="identifier">bucket_count</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">size_type</phrase> <link linkend="id263-bb"><phrase role="identifier">max_bucket_count</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">size_type</phrase> <link linkend="id264-bb"><phrase role="identifier">bucket_size</phrase></link><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">size_type</phrase> <link linkend="id265-bb"><phrase role="identifier">bucket</phrase></link><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">local_iterator</phrase> <link linkend="id267-bb"><phrase role="identifier">begin</phrase></link><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">const_local_iterator</phrase> <link linkend="id268-bb"><phrase role="identifier">begin</phrase></link><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">local_iterator</phrase> <link linkend="id270-bb"><phrase role="identifier">end</phrase></link><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">const_local_iterator</phrase> <link linkend="id271-bb"><phrase role="identifier">end</phrase></link><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">const_local_iterator</phrase> <link linkend="id272-bb"><phrase role="identifier">cbegin</phrase></link><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="identifier">const_local_iterator</phrase> <link linkend="id273-bb"><phrase role="identifier">cend</phrase></link><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+
+ <phrase role="comment">// <link linkend="id274-bb">hash policy</link></phrase>
+ <phrase role="keyword">float</phrase> <link linkend="id275-bb"><phrase role="identifier">load_factor</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">float</phrase> <link linkend="id276-bb"><phrase role="identifier">max_load_factor</phrase></link><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">void</phrase> <link linkend="id277-bb"><phrase role="identifier">max_load_factor</phrase></link><phrase role="special">(</phrase><phrase role="keyword">float</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+ <phrase role="keyword">void</phrase> <link linkend="id278-bb"><phrase role="identifier">rehash</phrase></link><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="special">}</phrase><phrase role="special">;</phrase>
+
+<phrase role="comment">// <link linkend="id279-bb">Equality Comparisons</link></phrase>
+<phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> Key<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Mapped<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Hash<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Pred<phrase role="special">,</phrase>
+ <phrase role="keyword">typename</phrase> Alloc<phrase role="special">></phrase>
+ <phrase role="keyword">bool</phrase> <link linkend="boost.unordered_multimap.operator==_id1"><phrase role="keyword">operator</phrase><phrase role="special">==</phrase></link><phrase role="special">(</phrase><phrase role="identifier">unordered_multimap</phrase><phrase role="special"><</phrase><phrase role="identifier">Key</phrase><phrase role="special">,</phrase> <phrase role="identifier">Mapped</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">unordered_multimap</phrase><phrase role="special"><</phrase><phrase role="identifier">Key</phrase><phrase role="special">,</phrase> <phrase role="identifier">Mapped</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> Key<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Mapped<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Hash<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Pred<phrase role="special">,</phrase>
+ <phrase role="keyword">typename</phrase> Alloc<phrase role="special">></phrase>
+ <phrase role="keyword">bool</phrase> <link linkend="boost.unordered_multimap.operator!=_id1"><phrase role="keyword">operator</phrase><phrase role="special">!=</phrase></link><phrase role="special">(</phrase><phrase role="identifier">unordered_multimap</phrase><phrase role="special"><</phrase><phrase role="identifier">Key</phrase><phrase role="special">,</phrase> <phrase role="identifier">Mapped</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">unordered_multimap</phrase><phrase role="special"><</phrase><phrase role="identifier">Key</phrase><phrase role="special">,</phrase> <phrase role="identifier">Mapped</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+
+<phrase role="comment">// <link linkend="id280-bb">swap</link></phrase>
+<phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> Key<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Mapped<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Hash<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Pred<phrase role="special">,</phrase>
+ <phrase role="keyword">typename</phrase> Alloc<phrase role="special">></phrase>
+ <phrase role="keyword">void</phrase> <link linkend="boost.unordered_multimap.swap_id1"><phrase role="identifier">swap</phrase></link><phrase role="special">(</phrase><phrase role="identifier">unordered_multimap</phrase><phrase role="special"><</phrase><phrase role="identifier">Key</phrase><phrase role="special">,</phrase> <phrase role="identifier">Mapped</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase><phrase role="special">&</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">unordered_multimap</phrase><phrase role="special"><</phrase><phrase role="identifier">Key</phrase><phrase role="special">,</phrase> <phrase role="identifier">Mapped</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase></synopsis></refsynopsisdiv><refsect1><title>Description</title>
+ <para>Based on chapter 23 of
+ <ulink url="http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2009/n2960.pdf">the working draft of the C++ standard [n2960]</ulink>.
+ But without the updated rules for allocators.
+ </para>
+ <para><emphasis role="bold">Template Parameters</emphasis>
+ <informaltable>
+ <tgroup cols="2">
+ <tbody>
+ <row>
+ <entry><emphasis>Key</emphasis></entry>
+ <entry>Key must be Assignable and CopyConstructible.</entry></row>
+ <row>
+ <entry><emphasis>Mapped</emphasis></entry>
+ <entry>Mapped must be CopyConstructible</entry></row>
+ <row>
+ <entry><emphasis>Hash</emphasis></entry>
+ <entry>A unary function object type that acts a hash function for a <computeroutput>Key</computeroutput>. It takes a single argument of type <computeroutput>Key</computeroutput> and returns a value of type std::size_t.</entry></row>
+ <row>
+ <entry><emphasis>Pred</emphasis></entry>
+ <entry>A binary function object that implements an equivalence relation on values of type <computeroutput>Key</computeroutput>.
+ A binary function object that induces an equivalence relation on values of type Key.
+ It takes two arguments of type Key and returns a value of type bool.</entry></row>
+ <row>
+ <entry><emphasis>Alloc</emphasis></entry>
+ <entry>An allocator whose value type is the same as the container's value type.</entry></row></tbody></tgroup></informaltable></para>
+ <para>The elements are organized into buckets. Keys with the same hash code are stored in the same bucket and elements with equivalent keys are stored next to each other.</para>
+ <para>The number of buckets can be automatically increased by a call to insert, or as the result of calling rehash.</para>
+ <refsect2><title><anchor id="boost.unordered_multimaptypes"/><computeroutput>unordered_multimap</computeroutput>
+ public
+ types</title><orderedlist><listitem><para>
+<phrase role="keyword">typedef</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis> <anchor id="boost.unordered_multimap.size_type"/><phrase role="identifier">size_type</phrase><phrase role="special">;</phrase></para>
+ <para>An unsigned integral type.</para>
+ <para>size_type can represent any non-negative value of difference_type.</para>
+ </listitem><listitem><para>
+<phrase role="keyword">typedef</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis> <anchor id="boost.unordered_multimap.difference_type"/><phrase role="identifier">difference_type</phrase><phrase role="special">;</phrase></para>
+ <para>A signed integral type.</para>
+ <para>Is identical to the difference type of iterator and const_iterator.</para>
+ </listitem><listitem><para>
+<phrase role="keyword">typedef</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis> <anchor id="boost.unordered_multimap.iterator"/><phrase role="identifier">iterator</phrase><phrase role="special">;</phrase></para>
+ <para>A iterator whose value type is value_type. </para>
+ <para>The iterator category is at least a forward iterator.</para>
+ <para>Convertible to const_iterator.</para>
+ </listitem><listitem><para>
+<phrase role="keyword">typedef</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis> <anchor id="boost.unordered_multimap.const_iterator"/><phrase role="identifier">const_iterator</phrase><phrase role="special">;</phrase></para>
+ <para>A constant iterator whose value type is value_type. </para>
+ <para>The iterator category is at least a forward iterator.</para>
+ </listitem><listitem><para>
+<phrase role="keyword">typedef</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis> <anchor id="boost.unordered_multimap.local_iterator"/><phrase role="identifier">local_iterator</phrase><phrase role="special">;</phrase></para>
+ <para>An iterator with the same value type, difference type and pointer and reference type as iterator.</para>
+ <para>A local_iterator object can be used to iterate through a single bucket.</para>
+ </listitem><listitem><para>
+<phrase role="keyword">typedef</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis> <anchor id="boost.unordered_multimap.const_local_iterator"/><phrase role="identifier">const_local_iterator</phrase><phrase role="special">;</phrase></para>
+ <para>A constant iterator with the same value type, difference type and pointer and reference type as const_iterator.</para>
+ <para>A const_local_iterator object can be used to iterate through a single bucket.</para>
+ </listitem></orderedlist></refsect2><refsect2><title><anchor id="boost.unordered_multimapconstruct-copy-destruct"/><computeroutput>unordered_multimap</computeroutput>
+ public
+ construct/copy/destruct</title><orderedlist><listitem><para><literallayout class="monospaced"><phrase role="keyword">explicit</phrase> <anchor id="id212-bb"/><phrase role="identifier">unordered_multimap</phrase><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase> n <phrase role="special">=</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis><phrase role="special">,</phrase>
+ <phrase role="identifier">hasher</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> hf <phrase role="special">=</phrase> <phrase role="identifier">hasher</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">key_equal</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> eq <phrase role="special">=</phrase> <phrase role="identifier">key_equal</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">allocator_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> a <phrase role="special">=</phrase> <phrase role="identifier">allocator_type</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Constructs an empty container with at least n buckets, using hf as the hash function, eq as the key equality predicate, a as the allocator and a maximum load factor of 1.0.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Postconditions:</term><listitem><computeroutput><link linkend="id224-bb">size</link>() == 0</computeroutput></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> InputIterator<phrase role="special">></phrase>
+ <anchor id="id213-bb"/><phrase role="identifier">unordered_multimap</phrase><phrase role="special">(</phrase><phrase role="identifier">InputIterator</phrase> f<phrase role="special">,</phrase> <phrase role="identifier">InputIterator</phrase> l<phrase role="special">,</phrase>
+ <phrase role="identifier">size_type</phrase> n <phrase role="special">=</phrase> <emphasis><phrase role="identifier">implementation</phrase><phrase role="special">-</phrase><phrase role="identifier">defined</phrase></emphasis><phrase role="special">,</phrase>
+ <phrase role="identifier">hasher</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> hf <phrase role="special">=</phrase> <phrase role="identifier">hasher</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">key_equal</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> eq <phrase role="special">=</phrase> <phrase role="identifier">key_equal</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">,</phrase>
+ <phrase role="identifier">allocator_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> a <phrase role="special">=</phrase> <phrase role="identifier">allocator_type</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Constructs an empty container with at least n buckets, using hf as the hash function, eq as the key equality predicate, a as the allocator and a maximum load factor of 1.0 and inserts the elements from [f, l) into it.</para></listitem><listitem><para><literallayout class="monospaced"><anchor id="id214-bb"/><phrase role="identifier">unordered_multimap</phrase><phrase role="special">(</phrase><phrase role="identifier">unordered_multimap</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>The copy cons
tructor. Copies the contained elements, hash function, predicate, maximum load factor and allocator.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Requires:</term><listitem><para><computeroutput>value_type</computeroutput> is copy constructible</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><anchor id="id215-bb"/><phrase role="identifier">unordered_multimap</phrase><phrase role="special">(</phrase><phrase role="identifier">unordered_multimap</phrase> <phrase role="special">&&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>The move constructor.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Notes:</term><listitem><para>This is emulated on compilers without rvalue references.</para></listitem></varlistentry><varlistentry><term>Requires:</term><listitem><para>
+ <computeroutput>value_type</computeroutput> is move constructible.
+ (TODO: This is not actually required in this implementation).
+ </para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="keyword">explicit</phrase> <anchor id="id216-bb"/><phrase role="identifier">unordered_multimap</phrase><phrase role="special">(</phrase><phrase role="identifier">Allocator</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> a<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Constructs an empty container, using allocator <computeroutput>a</computeroutput>.</para></listitem><listitem><para><literallayout class="monospaced"><anchor id="id217-bb"/><phrase role="identifier">unordered_multimap</phrase><phrase role="special">(</phrase><phrase role="identifier">unordered_multimap</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> x<phrase role="special">,</phrase> <phrase role="identifier">Allocator</phrase> <phrase role="keyword">const</phrase><phrase role="special">&
</phrase> a<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Constructs an container, copying <computeroutput>x</computeroutput>'s contained elements, hash function, predicate, maximum load factor, but using allocator <computeroutput>a</computeroutput>.</para></listitem><listitem><para><literallayout class="monospaced"><anchor id="id218-bb"/><phrase role="special">~</phrase><phrase role="identifier">unordered_multimap</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Notes:</term><listitem><para>The destructor is applied to every element, and all memory is deallocated</para></listitem></varlistentry></variablelist></listitem></orderedlist></refsect2><para><literallayout class="monospaced"><phrase role="identifier">unordered_multimap</phrase><phrase role="special">&</phrase> <anchor id="id219-bb"/><phrase role="keyword">operator</phrase><phrase role="special">=</phrase><phrase role="special">(</phrase><phrase role="identifier">unordered_multimap</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>The assignment operator. Copies the contained elements, hash function, predicate and maximum load factor but not the allocator.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Notes:</term><listitem><para>
+ On compilers without rvalue references, there is a single assignment
+ operator with the signature <computeroutput>operator=(unordered_multimap)</computeroutput>
+ in order to emulate move semantics.
+ </para></listitem></varlistentry><varlistentry><term>Requires:</term><listitem><para><computeroutput>value_type</computeroutput> is copy constructible</para></listitem></varlistentry></variablelist><para><literallayout class="monospaced"><phrase role="identifier">unordered_multimap</phrase><phrase role="special">&</phrase> <anchor id="id220-bb"/><phrase role="keyword">operator</phrase><phrase role="special">=</phrase><phrase role="special">(</phrase><phrase role="identifier">unordered_multimap</phrase> <phrase role="special">&&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>The move assignment operator.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Notes:</term><listitem><para>
+ On compilers without rvalue references, there is a single assignment
+ operator with the signature <computeroutput>operator=(unordered_multimap)</computeroutput>
+ in order to emulate move semantics.
+ </para></listitem></varlistentry><varlistentry><term>Requires:</term><listitem><para>
+ <computeroutput>value_type</computeroutput> is move constructible.
+ (TODO: This is not actually required in this implementation).
+ </para></listitem></varlistentry></variablelist><para><literallayout class="monospaced"><phrase role="identifier">allocator_type</phrase> <anchor id="id221-bb"/><phrase role="identifier">get_allocator</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><refsect2><title><anchor id="id222-bb"/><computeroutput>unordered_multimap</computeroutput> size and capacity</title><orderedlist><listitem><para><literallayout class="monospaced"><phrase role="keyword">bool</phrase> <anchor id="id223-bb"/><phrase role="identifier">empty</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><computeroutput><link linkend="id224-bb">size</link>() == 0</computeroutput></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">size_type</phrase> <anchor id="id224-bb"/><phrase role="identifier">size</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><computeroutput>std::distance(<link linkend="id227-bb">begin</link>(), <link linkend="id230-bb">end</link>())</computeroutput></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">size_type</phrase> <anchor id="id225-bb"/><phrase role="identifier">max_size</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><computeroutput><link linkend="id224-bb">size</link>()</computeroutput> of the largest possible container.
+ </listitem></varlistentry></variablelist></listitem></orderedlist></refsect2><refsect2><title><anchor id="id226-bb"/><computeroutput>unordered_multimap</computeroutput> iterators</title><orderedlist><listitem><para><literallayout class="monospaced"><anchor id="id227-bb"/><phrase role="identifier">iterator</phrase> <anchor id="id228-bb"/><phrase role="identifier">begin</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="identifier">const_iterator</phrase> <anchor id="id229-bb"/><phrase role="identifier">begin</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem>An iterator referring to the first element of the container, or if the container is empty the past-the-end value for the container.
+ </listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><anchor id="id230-bb"/><phrase role="identifier">iterator</phrase> <anchor id="id231-bb"/><phrase role="identifier">end</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="identifier">const_iterator</phrase> <anchor id="id232-bb"/><phrase role="identifier">end</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem>An iterator which refers to the past-the-end value for the container.
+ </listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">const_iterator</phrase> <anchor id="id233-bb"/><phrase role="identifier">cbegin</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem>A constant iterator referring to the first element of the container, or if the container is empty the past-the-end value for the container.
+ </listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">const_iterator</phrase> <anchor id="id234-bb"/><phrase role="identifier">cend</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem>A constant iterator which refers to the past-the-end value for the container.
+ </listitem></varlistentry></variablelist></listitem></orderedlist></refsect2><refsect2><title><anchor id="id235-bb"/><computeroutput>unordered_multimap</computeroutput> modifiers</title><orderedlist><listitem><para><literallayout class="monospaced"><phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase><phrase role="special">...</phrase> Args<phrase role="special">></phrase> <phrase role="identifier">iterator</phrase> <anchor id="id236-bb"/><phrase role="identifier">emplace</phrase><phrase role="special">(</phrase><phrase role="identifier">Args</phrase><phrase role="special">&&</phrase><phrase role="special">...</phrase> args<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Inserts an object, constructed with the arguments <computeroutput>args</computeroutput>, in the container.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>An iterator pointing to the inserted element.</para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><para>If an exception is thrown by an operation other than a call to <computeroutput>hasher</computeroutput> the function has no effect.</para></listitem></varlistentry><varlistentry><term>Notes:</term><listitem><para>Can invalidate iterators, but only if the insert causes the load factor to be greater to or equal to the maximum load factor.</para><para>Pointers and references to elements are never invalidated.</para><para>If the compiler doesn't support variadic template arguments or rvalue
+ references, this is emulated for up to 10 arguments, with no support
+ for rvalue references or move semantics.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase><phrase role="special">...</phrase> Args<phrase role="special">></phrase>
+ <phrase role="identifier">iterator</phrase> <anchor id="id237-bb"/><phrase role="identifier">emplace_hint</phrase><phrase role="special">(</phrase><phrase role="identifier">const_iterator</phrase> hint<phrase role="special">,</phrase> <phrase role="identifier">Args</phrase><phrase role="special">&&</phrase><phrase role="special">...</phrase> args<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Inserts an object, constructed with the arguments <computeroutput>args</computeroutput>, in the container.</para><para>hint is a suggestion to where the element should be inserted.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>An iterator pointing to the inserted element.</para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><para>If an exception is thrown by an operation other than a call to <computeroutput>hasher</computeroutput> the function has no effect.</para></listitem></varlistentry><varlistentry><term>Notes:</term><listitem><para>The standard is fairly vague on the meaning of the hint. But the only practical way to use it, and the only way that Boost.Unordered supports is to point to an existing element with the same key. </para><para>Can invalidate iterators, but only if the insert causes the load factor to be greater to or equal to the maximum load factor.</para><para>Pointers and references to elements are never invalidated.</para><para>If the compiler doesn't support variadic template arguments or rvalue
+ references, this is emulated for up to 10 arguments, with no support
+ for rvalue references or move semantics.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">iterator</phrase> <anchor id="id238-bb"/><phrase role="identifier">insert</phrase><phrase role="special">(</phrase><phrase role="identifier">value_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> obj<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Inserts obj in the container.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>An iterator pointing to the inserted element.</para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><para>If an exception is thrown by an operation other than a call to <computeroutput>hasher</computeroutput> the function has no effect.</para></listitem></varlistentry><varlistentry><term>Notes:</term><listitem><para>Can invalidate iterators, but only if the insert causes the load factor to be greater to or equal to the maximum load factor.</para><para>Pointers and references to elements are never invalidated.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">iterator</phrase> <anchor id="id239-bb"/><phrase role="identifier">insert</phrase><phrase role="special">(</phrase><phrase role="identifier">const_iterator</phrase> hint<phrase role="special">,</phrase> <phrase role="identifier">value_type</phrase> <phrase role="keyword">const</phrase><phr
ase role="special">&</phrase> obj<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Inserts obj in the container.</para><para>hint is a suggestion to where the element should be inserted.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>An iterator pointing to the inserted element.</para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><para>If an exception is thrown by an operation other than a call to <computeroutput>hasher</computeroutput> the function has no effect.</para></listitem></varlistentry><varlistentry><term>Notes:</term><listitem><para>The standard is fairly vague on the meaning of the hint. But the only practical way to use it, and the only way that Boost.Unordered supports is to point to an existing element with the same key. </para><para>Can invalidate iterators, but only if the insert causes the load factor to be greater to or equal to the maximum load factor.</para><para>Pointers and references to elements are never invalidated.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename
</phrase> InputIterator<phrase role="special">></phrase>
+ <phrase role="keyword">void</phrase> <anchor id="id240-bb"/><phrase role="identifier">insert</phrase><phrase role="special">(</phrase><phrase role="identifier">InputIterator</phrase> first<phrase role="special">,</phrase> <phrase role="identifier">InputIterator</phrase> last<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Inserts a range of elements into the container.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Throws:</term><listitem><para>When inserting a single element, if an exception is thrown by an operation other than a call to <computeroutput>hasher</computeroutput> the function has no effect.</para></listitem></varlistentry><varlistentry><term>Notes:</term><listitem><para>Can invalidate iterators, but only if the insert causes the load factor to be greater to or equal to the maximum load factor.</para><para>Pointers and references to elements are never invalidated.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">iterator</phrase> <anchor id="id241-bb"/><phrase role="identifier">erase</phrase><phrase role="special">(</phrase><phrase role="identifier">const_iterator</phrase> position<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Erase the element pointed to by <computeroutput>position</computeroutput>.</para><variablelist spacing="compact"><?dbht
ml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>The iterator following <computeroutput>position</computeroutput> before the erasure.</para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><para>Only throws an exception if it is thrown by <computeroutput>hasher</computeroutput> or <computeroutput>key_equal</computeroutput>.</para><para>In this implementation, this overload doesn't call either function object's methods so it is no throw, but this might not be true in other implementations.</para></listitem></varlistentry><varlistentry><term>Notes:</term><listitem><para>
+ When the number of elements is a lot smaller than the number of buckets
+ this function can be very inefficient as it has to search through empty
+ buckets for the next element, in order to return the iterator.
+ The method <link linkend="id244-bb">quick_erase</link> is faster, but has yet
+ to be standardized.
+ </para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">size_type</phrase> <anchor id="id242-bb"/><phrase role="identifier">erase</phrase><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> k<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Erase all elements with key equivalent to <computeroutput>k</computeroutput>.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>The number of elements erased.</para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><para>Only throws an exception if it is thrown by <computeroutput>hasher</computeroutput> or <computeroutput>key_equal</computeroutput>.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">iterator</phrase> <anchor id="id243-bb"/><phrase role="identifier">erase</phrase><phrase role="special">(</phrase><phrase role="identifier">const_iterator</phrase> first<phrase role="special">,</phrase> <phrase role="identifier">const_iterator</phrase> last<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Erases the elements in the range from <computeroutput>first</computeroutput> to <computeroutput>last</computeroutput>.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>The iterator following the erased elements - i.e. <computeroutput>last</computeroutput>.</para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><para>Only throws an exception if it is thrown by <computeroutput>hasher</computeroutput> or <computeroutput>key_equal</computeroutput>.</para><para>In this implementation, this overload doesn't call either function object's methods so it is no throw, but this might not be true in other implementations.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="keyword">void</phrase> <anchor id="id244-bb"/><phrase role="identifier">quick_erase</phrase><phrase role="special">(</phrase><phrase role="identifier">const_iterator</phrase> position<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Erase the element pointed to by <computeroutput>position</computeroutput>.</para><variablel
ist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Throws:</term><listitem><para>Only throws an exception if it is thrown by <computeroutput>hasher</computeroutput> or <computeroutput>key_equal</computeroutput>.</para><para>In this implementation, this overload doesn't call either function object's methods so it is no throw, but this might not be true in other implementations.</para></listitem></varlistentry><varlistentry><term>Notes:</term><listitem><para>
+ This method is faster than <link linkend="id241-bb">erase</link> as
+ it doesn't have to find the next element in the container -
+ a potentially costly operation.
+ </para><para>
+ As it hasn't been standardized, it's likely that this may
+ change in the future.
+ </para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="keyword">void</phrase> <anchor id="id245-bb"/><phrase role="identifier">erase_return_void</phrase><phrase role="special">(</phrase><phrase role="identifier">const_iterator</phrase> position<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Erase the element pointed to by <computeroutput>position</computeroutput>.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Throws:</term><listitem><para>Only throws an exception if it is thrown by <computeroutput>hasher</computeroutput> or <computeroutput>key_equal</computeroutput>.</para><para>In this implementation, this overload doesn't call either function object's methods so it is no throw, but this might not be true in other implementations.</para></listitem></varlistentry><varlistentry><term>Notes:</term><listitem><para>
+ This method is now deprecated, use
+ quick_return instead. Although be
+ warned that as that isn't standardized yet, it could also
+ change.
+ </para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="keyword">void</phrase> <anchor id="id246-bb"/><phrase role="identifier">clear</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Erases all elements in the container.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Postconditions:</term><listitem><para><computeroutput><link linkend="id224-bb">size</link>() == 0</computeroutput></para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><para>Never throws an exception.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="keyword">void</phrase> <anchor id="id247-bb"/><phrase role="identifier">swap</phrase><phrase role="special">(</phrase><phrase role="identifier">unordered_multimap</phrase><phrase role="special">&</phrase><phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Throws:</term><listitem><para>If the allocators are equal, doesn't throw an exception unless it is thrown by the copy constructor or copy assignment operator of <computeroutput>key_equal</computeroutput> or <computeroutput>hasher</computeroutput>.</para></listitem></varlistentry><varlistentry><term>Notes:</term><listitem><para>For a discussion of the behavior when allocators aren't equal see
+ <link linkend="unordered.rationale.swapping_containers_with_unequal_allocators">the implementation details</link>.</para></listitem></varlistentry></variablelist></listitem></orderedlist></refsect2><refsect2><title><anchor id="id248-bb"/><computeroutput>unordered_multimap</computeroutput> observers</title><orderedlist><listitem><para><literallayout class="monospaced"><phrase role="identifier">hasher</phrase> <anchor id="id249-bb"/><phrase role="identifier">hash_function</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem>The container's hash function.
+ </listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">key_equal</phrase> <anchor id="id250-bb"/><phrase role="identifier">key_eq</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem>The container's key equality predicate.
+ </listitem></varlistentry></variablelist></listitem></orderedlist></refsect2><refsect2><title><anchor id="id251-bb"/><computeroutput>unordered_multimap</computeroutput> lookup</title><orderedlist><listitem><para><literallayout class="monospaced"><anchor id="id252-bb"/><phrase role="identifier">iterator</phrase> <anchor id="id253-bb"/><phrase role="identifier">find</phrase><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> k<phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="identifier">const_iterator</phrase> <anchor id="id254-bb"/><phrase role="identifier">find</phrase><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> k<phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase>
+<phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> CompatibleKey<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> CompatibleHash<phrase role="special">,</phrase>
+ <phrase role="keyword">typename</phrase> CompatiblePredicate<phrase role="special">></phrase>
+ <phrase role="identifier">iterator</phrase> <anchor id="id255-bb"/><phrase role="identifier">find</phrase><phrase role="special">(</phrase><phrase role="identifier">CompatibleKey</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> k<phrase role="special">,</phrase> <phrase role="identifier">CompatibleHash</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> hash<phrase role="special">,</phrase>
+ <phrase role="identifier">CompatiblePredicate</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> eq<phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> CompatibleKey<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> CompatibleHash<phrase role="special">,</phrase>
+ <phrase role="keyword">typename</phrase> CompatiblePredicate<phrase role="special">></phrase>
+ <phrase role="identifier">const_iterator</phrase>
+ <anchor id="id256-bb"/><phrase role="identifier">find</phrase><phrase role="special">(</phrase><phrase role="identifier">CompatibleKey</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> k<phrase role="special">,</phrase> <phrase role="identifier">CompatibleHash</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> hash<phrase role="special">,</phrase>
+ <phrase role="identifier">CompatiblePredicate</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> eq<phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>An iterator pointing to an element with key equivalent to <computeroutput>k</computeroutput>, or <computeroutput>b.end()</computeroutput> if no such element exists.</para></listitem></varlistentry><varlistentry><term>Notes:</term><listitem><para>
+ The templated overloads are a non-standard extensions which
+ allows you to use a compatible hash function and equality
+ predicate for a key of a different type in order to avoid
+ an expensive type cast. In general, its use is not encouraged.
+ </para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">size_type</phrase> <anchor id="id257-bb"/><phrase role="identifier">count</phrase><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> k<phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>The number of elements with key equivalent to <computeroutput>k</computeroutput>.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><anchor id="id258-bb"/><phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">pair</phrase><phrase role="special"><</phrase><phrase role="identifier">iterator</phrase><phrase role="special">,</phrase> <phrase role="identifier">iterator</phrase><phrase role="special">></phrase> <anchor id="id259-bb"/><phrase role="identifier">equal_range</phrase><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> k<phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="identifier">std</phrase><phrase role="special">::</phrase><phrase role="identifier">pair</phrase><phrase role="special"><</phrase><phrase role="identifier">const_iterator</phrase><phrase role="special">,</phrase> <phrase role="identifier">const_iterator</phrase><phrase role="special">></phrase> <anchor id="id260-bb"/><phrase role="identifier">equal_range</phrase><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> k<phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>A range containing all elements with key equivalent to <computeroutput>k</computeroutput>.
+ If the container doesn't container any such elements, returns
+ <computeroutput>std::make_pair(b.end(),b.end())</computeroutput>.
+ </para></listitem></varlistentry></variablelist></listitem></orderedlist></refsect2><refsect2><title><anchor id="id261-bb"/><computeroutput>unordered_multimap</computeroutput> bucket interface</title><orderedlist><listitem><para><literallayout class="monospaced"><phrase role="identifier">size_type</phrase> <anchor id="id262-bb"/><phrase role="identifier">bucket_count</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>The number of buckets.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">size_type</phrase> <anchor id="id263-bb"/><phrase role="identifier">max_bucket_count</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>An upper bound on the number of buckets.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">size_type</phrase> <anchor id="id264-bb"/><phrase role="identifier">bucket_size</phrase><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase> n<phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Requires:</term><listitem><para><computeroutput>n < <link linkend="id262-bb">bucket_count</link>()</computeroutput></para></listitem></varlistentry><varlistentry><term>Returns:</term><listitem><para>The number of elements in bucket <computeroutput>n</computeroutput>.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">size_type</phrase> <anchor id="id265-bb"/><phrase role="identifier">bucket</phrase><phrase role="special">(</phrase><phrase role="identifier">key_type</phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> k<phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>The index of the bucket which would contain an element with key <computeroutput>k</computeroutput>.</para></listitem></varlistentry><varlistentry><term>Postconditions:</term><listitem><para>The return value is less than <computeroutput>bucket_count()</computeroutput></para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><anchor id="id266-bb"/><phrase role="identifier">local_iterator</phrase> <anchor id="id267-bb"/><phrase role="identifier">begin</phrase><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase> n<phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="identifier">const_local_iterator</phrase> <anchor id="id268-bb"/><phrase role="identifier">begin</phrase><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase> n<phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Requires:</term><listitem><para><computeroutput>n</computeroutput> shall be in the range <computeroutput>[0, bucket_count())</computeroutput>.</para></listitem></varlistentry><varlistentry><term>Returns:</term><listitem><para>A local iterator pointing the first element in the bucket with index <computeroutput>n</computeroutput>.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><anchor id="id269-bb"/><phrase role="identifier">local_iterator</phrase> <anchor id="id270-bb"/><phrase role="identifier">end</phrase><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase> n<phrase role="special">)</phrase><phrase role="special">;</phrase>
+<phrase role="identifier">const_local_iterator</phrase> <anchor id="id271-bb"/><phrase role="identifier">end</phrase><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase> n<phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Requires:</term><listitem><para><computeroutput>n</computeroutput> shall be in the range <computeroutput>[0, bucket_count())</computeroutput>.</para></listitem></varlistentry><varlistentry><term>Returns:</term><listitem><para>A local iterator pointing the 'one past the end' element in the bucket with index <computeroutput>n</computeroutput>.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">const_local_iterator</phrase> <anchor id="id272-bb"/><phrase role="identifier">cbegin</phrase><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase> n<phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Requires:</term><listitem><para><computeroutput>n</computeroutput> shall be in the range <computeroutput>[0, bucket_count())</computeroutput>.</para></listitem></varlistentry><varlistentry><term>Returns:</term><listitem><para>A constant local iterator pointing the first element in the bucket with index <computeroutput>n</computeroutput>.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="identifier">const_local_iterator</phrase> <anchor id="id273-bb"/><phrase role="identifier">cend</phrase><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase> n<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Requires:</term><listitem><para><computeroutput>n</computeroutput> shall be in the range <computeroutput>[0, bucket_count())</computeroutput>.</para></listitem></varlistentry><varlistentry><term>Returns:</term><listitem><para>A constant local iterator pointing the 'one past the end' element in the bucket with index <computeroutput>n</computeroutput>.</para></listitem></varlistentry></variablelist></listitem></orderedlist></refsect2><refsect2><title><anchor id="id274-bb"/><computeroutput>unordered_multimap</computeroutput> hash policy</title><orderedlist><listitem><para><literallayout class="monospaced"><phrase role="keyword">float</phrase> <anchor id="id275-bb"/><phrase role="identifier">load_factor</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>The average number of elements per bucket.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="keyword">float</phrase> <anchor id="id276-bb"/><phrase role="identifier">max_load_factor</phrase><phrase role="special">(</phrase><phrase role="special">)</phrase> <phrase role="keyword">const</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Returns:</term><listitem><para>Returns the current maximum load factor.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="keyword">void</phrase> <anchor id="id277-bb"/><phrase role="identifier">max_load_factor</phrase><phrase role="special">(</phrase><phrase role="keyword">float</phrase> z<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Effects:</term><listitem><para>Changes the container's maximum load factor, using <computeroutput>z</computeroutput> as a hint.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="keyword">void</phrase> <anchor id="id278-bb"/><phrase role="identifier">rehash</phrase><phrase role="special">(</phrase><phrase role="identifier">size_type</phrase> n<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><para>Changes the number of buckets so that there at least <computeroutput>n</computeroutput> buckets, and so that the load factor is less than the maximum load factor.</para><para>Invalidates iterators, and changes the order of elements. Pointers and references to elements are not invalidated.</para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Throws:</term><listitem><para>The function has no effect if an exception is thrown, unless it is thrown by the container's hash function or comparison function.</para></listitem></varlistentry></variablelist></listitem></orderedlist></refsect2><refsect2><title><anchor id="id279-bb"/><computeroutput>unordered_multimap</computeroutput> Equality Comparisons</title><orderedlist><listitem><para><literallayout class="monospaced"><phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> Key<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Mapped<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Hash<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Pred<phrase role="special">,</phrase>
+ <phrase role="keyword">typename</phrase> Alloc<phrase role="special">></phrase>
+ <phrase role="keyword">bool</phrase> <anchor id="boost.unordered_multimap.operator==_id1"/><phrase role="keyword">operator</phrase><phrase role="special">==</phrase><phrase role="special">(</phrase><phrase role="identifier">unordered_multimap</phrase><phrase role="special"><</phrase><phrase role="identifier">Key</phrase><phrase role="special">,</phrase> <phrase role="identifier">Mapped</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> x<phrase role="special">,</phrase>
+ <phrase role="identifier">unordered_multimap</phrase><phrase role="special"><</phrase><phrase role="identifier">Key</phrase><phrase role="special">,</phrase> <phrase role="identifier">Mapped</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> y<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Notes:</term><listitem><para>This is a boost extension.</para><para>Behavior is undefined if the two containers don't have
+ equivalent equality predicates.</para></listitem></varlistentry></variablelist></listitem><listitem><para><literallayout class="monospaced"><phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> Key<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Mapped<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Hash<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Pred<phrase role="special">,</phrase>
+ <phrase role="keyword">typename</phrase> Alloc<phrase role="special">></phrase>
+ <phrase role="keyword">bool</phrase> <anchor id="boost.unordered_multimap.operator!=_id1"/><phrase role="keyword">operator</phrase><phrase role="special">!=</phrase><phrase role="special">(</phrase><phrase role="identifier">unordered_multimap</phrase><phrase role="special"><</phrase><phrase role="identifier">Key</phrase><phrase role="special">,</phrase> <phrase role="identifier">Mapped</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> x<phrase role="special">,</phrase>
+ <phrase role="identifier">unordered_multimap</phrase><phrase role="special"><</phrase><phrase role="identifier">Key</phrase><phrase role="special">,</phrase> <phrase role="identifier">Mapped</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase> <phrase role="keyword">const</phrase><phrase role="special">&</phrase> y<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Notes:</term><listitem><para>This is a boost extension.</para><para>Behavior is undefined if the two containers don't have
+ equivalent equality predicates.</para></listitem></varlistentry></variablelist></listitem></orderedlist></refsect2><refsect2><title><anchor id="id280-bb"/><computeroutput>unordered_multimap</computeroutput> swap</title><orderedlist><listitem><para><literallayout class="monospaced"><phrase role="keyword">template</phrase><phrase role="special"><</phrase><phrase role="keyword">typename</phrase> Key<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Mapped<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Hash<phrase role="special">,</phrase> <phrase role="keyword">typename</phrase> Pred<phrase role="special">,</phrase>
+ <phrase role="keyword">typename</phrase> Alloc<phrase role="special">></phrase>
+ <phrase role="keyword">void</phrase> <anchor id="boost.unordered_multimap.swap_id1"/><phrase role="identifier">swap</phrase><phrase role="special">(</phrase><phrase role="identifier">unordered_multimap</phrase><phrase role="special"><</phrase><phrase role="identifier">Key</phrase><phrase role="special">,</phrase> <phrase role="identifier">Mapped</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase><phrase role="special">&</phrase> x<phrase role="special">,</phrase>
+ <phrase role="identifier">unordered_multimap</phrase><phrase role="special"><</phrase><phrase role="identifier">Key</phrase><phrase role="special">,</phrase> <phrase role="identifier">Mapped</phrase><phrase role="special">,</phrase> <phrase role="identifier">Hash</phrase><phrase role="special">,</phrase> <phrase role="identifier">Pred</phrase><phrase role="special">,</phrase> <phrase role="identifier">Alloc</phrase><phrase role="special">></phrase><phrase role="special">&</phrase> y<phrase role="special">)</phrase><phrase role="special">;</phrase></literallayout></para><variablelist spacing="compact"><?dbhtml
+ list-presentation="table"
+ ?><varlistentry><term>Effects:</term><listitem><para><computeroutput>x.swap(y)</computeroutput></para></listitem></varlistentry><varlistentry><term>Throws:</term><listitem><para>If the allocators are equal, doesn't throw an exception unless it is thrown by the copy constructor or copy assignment operator of <computeroutput>Hash</computeroutput> or <computeroutput>Pred</computeroutput>.</para></listitem></varlistentry><varlistentry><term>Notes:</term><listitem><para>For a discussion of the behavior when allocators aren't equal see
+ <link linkend="unordered.rationale.swapping_containers_with_unequal_allocators">the implementation details</link>.</para></listitem></varlistentry></variablelist></listitem></orderedlist></refsect2></refsect1></refentry>
+ </section>
+ </section>
\ No newline at end of file
Added: trunk/tools/boostbook/test/more/tests/libs/unordered-ref.xml
==============================================================================
--- (empty file)
+++ trunk/tools/boostbook/test/more/tests/libs/unordered-ref.xml 2010-08-15 12:49:10 EDT (Sun, 15 Aug 2010)
@@ -0,0 +1,3629 @@
+<!--
+Copyright Daniel James 2006-2009
+Distributed under the Boost Software License, Version 1.0. (See accompanying
+file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
+--><library-reference>
+ <header name="boost/unordered_set.hpp">
+ <namespace name="boost">
+ <class name="unordered_set">
+ <template>
+ <template-type-parameter name="Value">
+ </template-type-parameter>
+ <template-type-parameter name="Hash">
+ <default><type>boost::hash<Value></type></default>
+ </template-type-parameter>
+ <template-type-parameter name="Pred">
+ <default><type>std::equal_to<Value></type></default>
+ </template-type-parameter>
+ <template-type-parameter name="Alloc">
+ <default><type>std::allocator<Value></type></default>
+ </template-type-parameter>
+ </template>
+ <purpose><simpara>
+ An unordered associative container that stores unique values.
+ </simpara></purpose>
+ <description>
+ <para>Based on chapter 23 of
+ <ulink url="http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2009/n2960.pdf">the working draft of the C++ standard [n2960]</ulink>.
+ But without the updated rules for allocators.
+ </para>
+ <para><emphasis role="bold">Template Parameters</emphasis>
+ <informaltable>
+ <tgroup cols="2">
+ <tbody>
+ <row>
+ <entry><emphasis>Value</emphasis></entry>
+ <entry>Value must be Assignable and CopyConstructible</entry></row>
+ <row>
+ <entry><emphasis>Hash</emphasis></entry>
+ <entry>A unary function object type that acts a hash function for a <code>Value</code>. It takes a single argument of type <code>Value</code> and returns a value of type std::size_t.</entry></row>
+ <row>
+ <entry><emphasis>Pred</emphasis></entry>
+ <entry>A binary function object that implements an equivalence relation on values of type <code>Value</code>.
+ A binary function object that induces an equivalence relation on values of type Key.
+ It takes two arguments of type Key and returns a value of type bool.</entry></row>
+ <row>
+ <entry><emphasis>Alloc</emphasis></entry>
+ <entry>An allocator whose value type is the same as the container's value type.</entry></row></tbody></tgroup></informaltable></para>
+ <para>The elements are organized into buckets. Keys with the same hash code are stored in the same bucket.</para>
+ <para>The number of buckets can be automatically increased by a call to insert, or as the result of calling rehash.</para>
+ </description>
+ <typedef name="key_type">
+ <type>Value</type>
+ </typedef>
+ <typedef name="value_type">
+ <type>Value</type>
+ </typedef>
+ <typedef name="hasher">
+ <type>Hash</type>
+ </typedef>
+ <typedef name="key_equal">
+ <type>Pred</type>
+ </typedef>
+ <typedef name="allocator_type">
+ <type>Alloc</type>
+ </typedef>
+ <typedef name="pointer">
+ <type>typename allocator_type::pointer</type>
+ </typedef>
+ <typedef name="const_pointer">
+ <type>typename allocator_type::const_pointer</type>
+ </typedef>
+ <typedef name="reference">
+ <type>typename allocator_type::reference</type>
+ <purpose><simpara>lvalue of <type>value_type</type>.</simpara></purpose>
+ </typedef>
+ <typedef name="const_reference">
+ <type>typename allocator_type::const_reference</type>
+ <purpose><simpara>const lvalue of <type>value_type</type>.</simpara></purpose>
+ </typedef>
+ <typedef name="size_type">
+ <type><emphasis>implementation-defined</emphasis></type>
+ <description>
+ <para>An unsigned integral type.</para>
+ <para><type>size_type</type> can represent any non-negative value of <type>difference_type</type>.</para>
+ </description>
+ </typedef>
+ <typedef name="difference_type">
+ <type><emphasis>implementation-defined</emphasis></type>
+ <description>
+ <para>A signed integral type.</para>
+ <para>Is identical to the difference type of <type>iterator</type> and <type>const_iterator</type>.</para>
+ </description>
+ </typedef>
+ <typedef name="iterator">
+ <type><emphasis>implementation-defined</emphasis></type>
+ <description>
+ <para>A constant iterator whose value type is <type>value_type</type>. </para>
+ <para>The iterator category is at least a forward iterator.</para>
+ <para>Convertible to <type>const_iterator</type>.</para>
+ </description>
+ </typedef>
+ <typedef name="const_iterator">
+ <type><emphasis>implementation-defined</emphasis></type>
+ <description>
+ <para>A constant iterator whose value type is <type>value_type</type>. </para>
+ <para>The iterator category is at least a forward iterator.</para>
+ </description>
+ </typedef>
+ <typedef name="local_iterator">
+ <type><emphasis>implementation-defined</emphasis></type>
+ <description>
+ <para>An iterator with the same value type, difference type and pointer and reference type as <type>iterator</type>.</para>
+ <para>A local_iterator object can be used to iterate through a single bucket.</para>
+ </description>
+ </typedef>
+ <typedef name="const_local_iterator">
+ <type><emphasis>implementation-defined</emphasis></type>
+ <description>
+ <para>A constant iterator with the same value type, difference type and pointer and reference type as <type>const_iterator</type>.</para>
+ <para>A const_local_iterator object can be used to iterate through a single bucket.</para>
+ </description>
+ </typedef>
+ <constructor specifiers="explicit">
+ <parameter name="n">
+ <paramtype>size_type</paramtype>
+ <default><emphasis>implementation-defined</emphasis></default>
+ </parameter>
+ <parameter name="hf">
+ <paramtype>hasher const&</paramtype>
+ <default>hasher()</default>
+ </parameter>
+ <parameter name="eq">
+ <paramtype>key_equal const&</paramtype>
+ <default>key_equal()</default>
+ </parameter>
+ <parameter name="a">
+ <paramtype>allocator_type const&</paramtype>
+ <default>allocator_type()</default>
+ </parameter>
+ <postconditions>
+ <code><methodname>size</methodname>() == 0</code>
+ </postconditions>
+ <description>
+ <para>Constructs an empty container with at least n buckets, using hf as the hash function, eq as the key equality predicate, a as the allocator and a maximum load factor of 1.0.</para>
+ </description>
+ </constructor>
+ <constructor>
+ <template>
+ <template-type-parameter name="InputIterator">
+ </template-type-parameter>
+ </template>
+ <parameter name="f">
+ <paramtype>InputIterator</paramtype>
+ </parameter>
+ <parameter name="l">
+ <paramtype>InputIterator</paramtype>
+ </parameter>
+ <parameter name="n">
+ <paramtype>size_type</paramtype>
+ <default><emphasis>implementation-defined</emphasis></default>
+ </parameter>
+ <parameter name="hf">
+ <paramtype>hasher const&</paramtype>
+ <default>hasher()</default>
+ </parameter>
+ <parameter name="eq">
+ <paramtype>key_equal const&</paramtype>
+ <default>key_equal()</default>
+ </parameter>
+ <parameter name="a">
+ <paramtype>allocator_type const&</paramtype>
+ <default>allocator_type()</default>
+ </parameter>
+ <description>
+ <para>Constructs an empty container with at least n buckets, using hf as the hash function, eq as the key equality predicate, a as the allocator and a maximum load factor of 1.0 and inserts the elements from [f, l) into it.</para>
+ </description>
+ </constructor>
+ <constructor>
+ <parameter>
+ <paramtype>unordered_set const&</paramtype>
+ </parameter>
+ <description>
+ <para>The copy constructor. Copies the contained elements, hash function, predicate, maximum load factor and allocator.</para>
+ </description>
+ <requires>
+ <para><code>value_type</code> is copy constructible</para>
+ </requires>
+ </constructor>
+ <constructor>
+ <parameter>
+ <paramtype>unordered_set &&</paramtype>
+ </parameter>
+ <description>
+ <para>The move constructor.</para>
+ </description>
+ <notes>
+ <para>This is emulated on compilers without rvalue references.</para>
+ </notes>
+ <requires>
+ <para>
+ <code>value_type</code> is move constructible.
+ (TODO: This is not actually required in this implementation).
+ </para>
+ </requires>
+ </constructor>
+ <constructor specifiers="explicit">
+ <parameter name="a">
+ <paramtype>Allocator const&</paramtype>
+ </parameter>
+ <description>
+ <para>Constructs an empty container, using allocator <code>a</code>.</para>
+ </description>
+ </constructor>
+ <constructor>
+ <parameter name="x">
+ <paramtype>unordered_set const&</paramtype>
+ </parameter>
+ <parameter name="a">
+ <paramtype>Allocator const&</paramtype>
+ </parameter>
+ <description>
+ <para>Constructs an container, copying <code>x</code>'s contained elements, hash function, predicate, maximum load factor, but using allocator <code>a</code>.</para>
+ </description>
+ </constructor>
+ <destructor>
+ <notes>
+ <para>The destructor is applied to every element, and all memory is deallocated</para>
+ </notes>
+ </destructor>
+ <method name="operator=">
+ <parameter>
+ <paramtype>unordered_set const&</paramtype>
+ </parameter>
+ <type>unordered_set&</type>
+ <description>
+ <para>The assignment operator. Copies the contained elements, hash function, predicate and maximum load factor but not the allocator.</para>
+ </description>
+ <notes>
+ <para>
+ On compilers without rvalue references, there is a single assignment
+ operator with the signature <code>operator=(unordered_set)</code>
+ in order to emulate move semantics.
+ </para>
+ </notes>
+ <requires>
+ <para><code>value_type</code> is copy constructible</para>
+ </requires>
+ </method>
+ <method name="operator=">
+ <parameter>
+ <paramtype>unordered_set &&</paramtype>
+ </parameter>
+ <type>unordered_set&</type>
+ <description>
+ <para>The move assignment operator.</para>
+ </description>
+ <notes>
+ <para>
+ On compilers without rvalue references, there is a single assignment
+ operator with the signature <code>operator=(unordered_set)</code>
+ in order to emulate move semantics.
+ </para>
+ </notes>
+ <requires>
+ <para>
+ <code>value_type</code> is move constructible.
+ (TODO: This is not actually required in this implementation).
+ </para>
+ </requires>
+ </method>
+ <method name="get_allocator" cv="const">
+ <type>allocator_type</type>
+ </method>
+ <method-group name="size and capacity">
+ <method name="empty" cv="const">
+ <type>bool</type>
+ <returns>
+ <code><methodname>size</methodname>() == 0</code>
+ </returns>
+ </method>
+ <method name="size" cv="const">
+ <type>size_type</type>
+ <returns>
+ <code>std::distance(<methodname>begin</methodname>(), <methodname>end</methodname>())</code>
+ </returns>
+ </method>
+ <method name="max_size" cv="const">
+ <type>size_type</type>
+ <returns><code><methodname>size</methodname>()</code> of the largest possible container.
+ </returns>
+ </method>
+ </method-group>
+ <method-group name="iterators">
+ <overloaded-method name="begin">
+ <signature><type>iterator</type></signature>
+ <signature cv="const"><type>const_iterator</type></signature>
+ <returns>An iterator referring to the first element of the container, or if the container is empty the past-the-end value for the container.
+ </returns>
+ </overloaded-method>
+ <overloaded-method name="end">
+ <signature>
+ <type>iterator</type>
+ </signature>
+ <signature cv="const">
+ <type>const_iterator</type>
+ </signature>
+ <returns>An iterator which refers to the past-the-end value for the container.
+ </returns>
+ </overloaded-method>
+ <method name="cbegin" cv="const">
+ <type>const_iterator</type>
+ <returns>A constant iterator referring to the first element of the container, or if the container is empty the past-the-end value for the container.
+ </returns>
+ </method>
+ <method name="cend" cv="const">
+ <type>const_iterator</type>
+ <returns>A constant iterator which refers to the past-the-end value for the container.
+ </returns>
+ </method>
+ </method-group>
+ <method-group name="modifiers">
+ <method name="emplace">
+ <template>
+ <template-type-parameter name="Args" pack="1">
+ </template-type-parameter>
+ </template>
+ <parameter name="args" pack="1">
+ <paramtype>Args&&</paramtype>
+ </parameter>
+ <type>std::pair<iterator, bool></type>
+ <description>
+ <para>Inserts an object, constructed with the arguments <code>args</code>, in the container if and only if there is no element in the container with an equivalent value.</para>
+ </description>
+ <returns>
+ <para>The bool component of the return type is true if an insert took place.</para>
+ <para>If an insert took place, then the iterator points to the newly inserted element. Otherwise, it points to the element with equivalent value.</para>
+ </returns>
+ <throws>
+ <para>If an exception is thrown by an operation other than a call to <code>hasher</code> the function has no effect.</para>
+ </throws>
+ <notes>
+ <para>Can invalidate iterators, but only if the insert causes the load factor to be greater to or equal to the maximum load factor.</para>
+ <para>Pointers and references to elements are never invalidated.</para>
+ <para>If the compiler doesn't support variadic template arguments or rvalue
+ references, this is emulated for up to 10 arguments, with no support
+ for rvalue references or move semantics.</para>
+ </notes>
+ </method>
+ <method name="emplace_hint">
+ <template>
+ <template-type-parameter name="Args" pack="1">
+ </template-type-parameter>
+ </template>
+ <parameter name="hint">
+ <paramtype>const_iterator</paramtype>
+ </parameter>
+ <parameter name="args" pack="1">
+ <paramtype>Args&&</paramtype>
+ </parameter>
+ <type>iterator</type>
+ <description>
+ <para>Inserts an object, constructed with the arguments <code>args</code>, in the container if and only if there is no element in the container with an equivalent value.</para>
+ <para>hint is a suggestion to where the element should be inserted.</para>
+ </description>
+ <returns>
+ <para>If an insert took place, then the iterator points to the newly inserted element. Otherwise, it points to the element with equivalent value.</para>
+ </returns>
+ <throws>
+ <para>If an exception is thrown by an operation other than a call to <code>hasher</code> the function has no effect.</para>
+ </throws>
+ <notes>
+ <para>The standard is fairly vague on the meaning of the hint. But the only practical way to use it, and the only way that Boost.Unordered supports is to point to an existing element with the same value. </para>
+ <para>Can invalidate iterators, but only if the insert causes the load factor to be greater to or equal to the maximum load factor.</para>
+ <para>Pointers and references to elements are never invalidated.</para>
+ <para>If the compiler doesn't support variadic template arguments or rvalue
+ references, this is emulated for up to 10 arguments, with no support
+ for rvalue references or move semantics.</para>
+ </notes>
+ </method>
+ <method name="insert">
+ <parameter name="obj">
+ <paramtype>value_type const&</paramtype>
+ </parameter>
+ <type>std::pair<iterator, bool></type>
+ <description>
+ <para>Inserts obj in the container if and only if there is no element in the container with an equivalent value.</para>
+ </description>
+ <returns>
+ <para>The bool component of the return type is true if an insert took place.</para>
+ <para>If an insert took place, then the iterator points to the newly inserted element. Otherwise, it points to the element with equivalent value.</para>
+ </returns>
+ <throws>
+ <para>If an exception is thrown by an operation other than a call to <code>hasher</code> the function has no effect.</para>
+ </throws>
+ <notes>
+ <para>Can invalidate iterators, but only if the insert causes the load factor to be greater to or equal to the maximum load factor.</para>
+ <para>Pointers and references to elements are never invalidated.</para>
+ </notes>
+ </method>
+ <method name="insert">
+ <parameter name="hint">
+ <paramtype>const_iterator</paramtype>
+ </parameter>
+ <parameter name="obj">
+ <paramtype>value_type const&</paramtype>
+ </parameter>
+ <type>iterator</type>
+ <description>
+ <para>Inserts obj in the container if and only if there is no element in the container with an equivalent value.</para>
+ <para>hint is a suggestion to where the element should be inserted.</para>
+ </description>
+ <returns>
+ <para>If an insert took place, then the iterator points to the newly inserted element. Otherwise, it points to the element with equivalent value.</para>
+ </returns>
+ <throws>
+ <para>If an exception is thrown by an operation other than a call to <code>hasher</code> the function has no effect.</para>
+ </throws>
+ <notes>
+ <para>The standard is fairly vague on the meaning of the hint. But the only practical way to use it, and the only way that Boost.Unordered supports is to point to an existing element with the same value. </para>
+ <para>Can invalidate iterators, but only if the insert causes the load factor to be greater to or equal to the maximum load factor.</para>
+ <para>Pointers and references to elements are never invalidated.</para>
+ </notes>
+ </method>
+ <method name="insert">
+ <template>
+ <template-type-parameter name="InputIterator">
+ </template-type-parameter>
+ </template>
+ <parameter name="first">
+ <paramtype>InputIterator</paramtype>
+ </parameter>
+ <parameter name="last">
+ <paramtype>InputIterator</paramtype>
+ </parameter>
+ <type>void</type>
+ <description>
+ <para>Inserts a range of elements into the container. Elements are inserted if and only if there is no element in the container with an equivalent value.</para>
+ </description>
+ <throws>
+ <para>When inserting a single element, if an exception is thrown by an operation other than a call to <code>hasher</code> the function has no effect.</para>
+ </throws>
+ <notes>
+ <para>Can invalidate iterators, but only if the insert causes the load factor to be greater to or equal to the maximum load factor.</para>
+ <para>Pointers and references to elements are never invalidated.</para>
+ </notes>
+ </method>
+ <method name="erase">
+ <parameter name="position">
+ <paramtype>const_iterator</paramtype>
+ </parameter>
+ <type>iterator</type>
+ <description>
+ <para>Erase the element pointed to by <code>position</code>.</para>
+ </description>
+ <returns>
+ <para>The iterator following <code>position</code> before the erasure.</para>
+ </returns>
+ <throws>
+ <para>Only throws an exception if it is thrown by <code>hasher</code> or <code>key_equal</code>.</para>
+ <para>In this implementation, this overload doesn't call either function object's methods so it is no throw, but this might not be true in other implementations.</para>
+ </throws>
+ <notes>
+ <para>
+ When the number of elements is a lot smaller than the number of buckets
+ this function can be very inefficient as it has to search through empty
+ buckets for the next element, in order to return the iterator.
+ The method <methodname>quick_erase</methodname> is faster, but has yet
+ to be standardized.
+ </para>
+ </notes>
+ </method>
+ <method name="erase">
+ <parameter name="k">
+ <paramtype>key_type const&</paramtype>
+ </parameter>
+ <type>size_type</type>
+ <description>
+ <para>Erase all elements with key equivalent to <code>k</code>.</para>
+ </description>
+ <returns>
+ <para>The number of elements erased.</para>
+ </returns>
+ <throws>
+ <para>Only throws an exception if it is thrown by <code>hasher</code> or <code>key_equal</code>.</para>
+ </throws>
+ </method>
+ <method name="erase">
+ <parameter name="first">
+ <paramtype>const_iterator</paramtype>
+ </parameter>
+ <parameter name="last">
+ <paramtype>const_iterator</paramtype>
+ </parameter>
+ <type>iterator</type>
+ <description>
+ <para>Erases the elements in the range from <code>first</code> to <code>last</code>.</para>
+ </description>
+ <returns>
+ <para>The iterator following the erased elements - i.e. <code>last</code>.</para>
+ </returns>
+ <throws>
+ <para>Only throws an exception if it is thrown by <code>hasher</code> or <code>key_equal</code>.</para>
+ <para>In this implementation, this overload doesn't call either function object's methods so it is no throw, but this might not be true in other implementations.</para>
+ </throws>
+ </method>
+ <method name="quick_erase">
+ <parameter name="position">
+ <paramtype>const_iterator</paramtype>
+ </parameter>
+ <type>void</type>
+ <description>
+ <para>Erase the element pointed to by <code>position</code>.</para>
+ </description>
+ <throws>
+ <para>Only throws an exception if it is thrown by <code>hasher</code> or <code>key_equal</code>.</para>
+ <para>In this implementation, this overload doesn't call either function object's methods so it is no throw, but this might not be true in other implementations.</para>
+ </throws>
+ <notes>
+ <para>
+ This method is faster than <methodname>erase</methodname> as
+ it doesn't have to find the next element in the container -
+ a potentially costly operation.
+ </para>
+ <para>
+ As it hasn't been standardized, it's likely that this may
+ change in the future.
+ </para>
+ </notes>
+ </method>
+ <method name="erase_return_void">
+ <parameter name="position">
+ <paramtype>const_iterator</paramtype>
+ </parameter>
+ <type>void</type>
+ <description>
+ <para>Erase the element pointed to by <code>position</code>.</para>
+ </description>
+ <throws>
+ <para>Only throws an exception if it is thrown by <code>hasher</code> or <code>key_equal</code>.</para>
+ <para>In this implementation, this overload doesn't call either function object's methods so it is no throw, but this might not be true in other implementations.</para>
+ </throws>
+ <notes>
+ <para>
+ This method is now deprecated, use
+ <methodname>quick_return</methodname> instead. Although be
+ warned that as that isn't standardized yet, it could also
+ change.
+ </para>
+ </notes>
+ </method>
+ <method name="clear">
+ <type>void</type>
+ <description>
+ <para>Erases all elements in the container.</para>
+ </description>
+ <postconditions>
+ <para><code><methodname>size</methodname>() == 0</code></para>
+ </postconditions>
+ <throws>
+ <para>Never throws an exception.</para>
+ </throws>
+ </method>
+ <method name="swap">
+ <parameter>
+ <paramtype>unordered_set&</paramtype>
+ </parameter>
+ <type>void</type>
+ <throws>
+ <para>If the allocators are equal, doesn't throw an exception unless it is thrown by the copy constructor or copy assignment operator of <code>key_equal</code> or <code>hasher</code>.</para>
+ </throws>
+ <notes>
+ <para>For a discussion of the behavior when allocators aren't equal see
+ <link linkend="unordered.rationale.swapping_containers_with_unequal_allocators">the implementation details</link>.</para>
+ </notes>
+ </method>
+ </method-group>
+ <method-group name="observers">
+ <method name="hash_function" cv="const">
+ <type>hasher</type>
+ <returns>The container's hash function.
+ </returns>
+ </method>
+ <method name="key_eq" cv="const">
+ <type>key_equal</type>
+ <returns>The container's key equality predicate.
+ </returns>
+ </method>
+ </method-group>
+ <method-group name="lookup">
+ <overloaded-method name="find">
+ <signature>
+ <parameter name="k">
+ <paramtype>key_type const&</paramtype>
+ </parameter>
+ <type>iterator</type>
+ </signature>
+ <signature cv="const">
+ <parameter name="k">
+ <paramtype>key_type const&</paramtype>
+ </parameter>
+ <type>const_iterator</type>
+ </signature>
+ <signature>
+ <template>
+ <template-type-parameter name="CompatibleKey"/>
+ <template-type-parameter name="CompatibleHash"/>
+ <template-type-parameter name="CompatiblePredicate"/>
+ </template>
+ <parameter name="k">
+ <paramtype>CompatibleKey const&</paramtype>
+ </parameter>
+ <parameter name="hash">
+ <paramtype>CompatibleHash const&</paramtype>
+ </parameter>
+ <parameter name="eq">
+ <paramtype>CompatiblePredicate const&</paramtype>
+ </parameter>
+ <type>iterator</type>
+ </signature>
+ <signature cv="const">
+ <template>
+ <template-type-parameter name="CompatibleKey"/>
+ <template-type-parameter name="CompatibleHash"/>
+ <template-type-parameter name="CompatiblePredicate"/>
+ </template>
+ <parameter name="k">
+ <paramtype>CompatibleKey const&</paramtype>
+ </parameter>
+ <parameter name="hash">
+ <paramtype>CompatibleHash const&</paramtype>
+ </parameter>
+ <parameter name="eq">
+ <paramtype>CompatiblePredicate const&</paramtype>
+ </parameter>
+ <type>const_iterator</type>
+ </signature>
+ <returns>
+ <para>An iterator pointing to an element with key equivalent to <code>k</code>, or <code>b.end()</code> if no such element exists.</para>
+ </returns>
+ <notes><para>
+ The templated overloads are a non-standard extensions which
+ allows you to use a compatible hash function and equality
+ predicate for a key of a different type in order to avoid
+ an expensive type cast. In general, its use is not encouraged.
+ </para></notes>
+ </overloaded-method>
+ <method name="count" cv="const">
+ <parameter name="k">
+ <paramtype>key_type const&</paramtype>
+ </parameter>
+ <type>size_type</type>
+ <returns>
+ <para>The number of elements with key equivalent to <code>k</code>.</para>
+ </returns>
+ </method>
+ <overloaded-method name="equal_range">
+ <signature>
+ <parameter name="k">
+ <paramtype>key_type const&</paramtype>
+ </parameter>
+ <type>std::pair<iterator, iterator></type>
+ </signature>
+ <signature cv="const">
+ <parameter name="k">
+ <paramtype>key_type const&</paramtype>
+ </parameter>
+ <type>std::pair<const_iterator, const_iterator></type>
+ </signature>
+ <returns>
+ <para>A range containing all elements with key equivalent to <code>k</code>.
+ If the container doesn't container any such elements, returns
+ <code><functionname>std::make_pair</functionname>(<methodname>b.end</methodname>(),<methodname>b.end</methodname>())</code>.
+ </para>
+ </returns>
+ </overloaded-method>
+ </method-group>
+ <method-group name="bucket interface">
+ <method name="bucket_count" cv="const">
+ <type>size_type</type>
+ <returns>
+ <para>The number of buckets.</para>
+ </returns>
+ </method>
+ <method name="max_bucket_count" cv="const">
+ <type>size_type</type>
+ <returns>
+ <para>An upper bound on the number of buckets.</para>
+ </returns>
+ </method>
+ <method name="bucket_size" cv="const">
+ <parameter name="n">
+ <paramtype>size_type</paramtype>
+ </parameter>
+ <type>size_type</type>
+ <requires>
+ <para><code>n < <methodname>bucket_count</methodname>()</code></para>
+ </requires>
+ <returns>
+ <para>The number of elements in bucket <code>n</code>.</para>
+ </returns>
+ </method>
+ <method name="bucket" cv="const">
+ <parameter name="k">
+ <paramtype>key_type const&</paramtype>
+ </parameter>
+ <type>size_type</type>
+ <returns>
+ <para>The index of the bucket which would contain an element with key <code>k</code>.</para>
+ </returns>
+ <postconditions>
+ <para>The return value is less than <code>bucket_count()</code></para>
+ </postconditions>
+ </method>
+ <overloaded-method name="begin">
+ <signature>
+ <parameter name="n">
+ <paramtype>size_type</paramtype>
+ </parameter>
+ <type>local_iterator</type>
+ </signature>
+ <signature cv="const">
+ <parameter name="n">
+ <paramtype>size_type</paramtype>
+ </parameter>
+ <type>const_local_iterator</type>
+ </signature>
+ <requires>
+ <para><code>n</code> shall be in the range <code>[0, bucket_count())</code>.</para>
+ </requires>
+ <returns>
+ <para>A local iterator pointing the first element in the bucket with index <code>n</code>.</para>
+ </returns>
+ </overloaded-method>
+ <overloaded-method name="end">
+ <signature>
+ <parameter name="n">
+ <paramtype>size_type</paramtype>
+ </parameter>
+ <type>local_iterator</type>
+ </signature>
+ <signature cv="const">
+ <parameter name="n">
+ <paramtype>size_type</paramtype>
+ </parameter>
+ <type>const_local_iterator</type>
+ </signature>
+ <requires>
+ <para><code>n</code> shall be in the range <code>[0, bucket_count())</code>.</para>
+ </requires>
+ <returns>
+ <para>A local iterator pointing the 'one past the end' element in the bucket with index <code>n</code>.</para>
+ </returns>
+ </overloaded-method>
+ <method name="cbegin" cv="const">
+ <parameter name="n">
+ <paramtype>size_type</paramtype>
+ </parameter>
+ <type>const_local_iterator</type>
+ <requires>
+ <para><code>n</code> shall be in the range <code>[0, bucket_count())</code>.</para>
+ </requires>
+ <returns>
+ <para>A constant local iterator pointing the first element in the bucket with index <code>n</code>.</para>
+ </returns>
+ </method>
+ <method name="cend">
+ <parameter name="n">
+ <paramtype>size_type</paramtype>
+ </parameter>
+ <type>const_local_iterator</type>
+ <requires>
+ <para><code>n</code> shall be in the range <code>[0, bucket_count())</code>.</para>
+ </requires>
+ <returns>
+ <para>A constant local iterator pointing the 'one past the end' element in the bucket with index <code>n</code>.</para>
+ </returns>
+ </method>
+ </method-group>
+ <method-group name="hash policy">
+ <method name="load_factor" cv="const">
+ <type>float</type>
+ <returns>
+ <para>The average number of elements per bucket.</para>
+ </returns>
+ </method>
+ <method name="max_load_factor" cv="const">
+ <type>float</type>
+ <returns>
+ <para>Returns the current maximum load factor.</para>
+ </returns>
+ </method>
+ <method name="max_load_factor">
+ <parameter name="z">
+ <paramtype>float</paramtype>
+ </parameter>
+ <type>void</type>
+ <effects>
+ <para>Changes the container's maximum load factor, using <code>z</code> as a hint.</para>
+ </effects>
+ </method>
+ <method name="rehash">
+ <parameter name="n">
+ <paramtype>size_type</paramtype>
+ </parameter>
+ <type>void</type>
+ <description>
+ <para>Changes the number of buckets so that there at least <code>n</code> buckets, and so that the load factor is less than the maximum load factor.</para>
+ <para>Invalidates iterators, and changes the order of elements. Pointers and references to elements are not invalidated.</para>
+ </description>
+ <throws>
+ <para>The function has no effect if an exception is thrown, unless it is thrown by the container's hash function or comparison function.</para>
+ </throws>
+ </method>
+ </method-group>
+ <free-function-group name="Equality Comparisons">
+ <function name="operator==">
+ <template>
+ <template-type-parameter name="Value">
+ </template-type-parameter>
+ <template-type-parameter name="Hash">
+ </template-type-parameter>
+ <template-type-parameter name="Pred">
+ </template-type-parameter>
+ <template-type-parameter name="Alloc">
+ </template-type-parameter>
+ </template>
+ <parameter name="x">
+ <paramtype>unordered_set<Value, Hash, Pred, Alloc> const&</paramtype>
+ </parameter>
+ <parameter name="y">
+ <paramtype>unordered_set<Value, Hash, Pred, Alloc> const&</paramtype>
+ </parameter>
+ <type>bool</type>
+ <notes>
+ <para>This is a boost extension.</para>
+ <para>Behavior is undefined if the two containers don't have
+ equivalent equality predicates.</para>
+ </notes>
+ </function>
+ <function name="operator!=">
+ <template>
+ <template-type-parameter name="Value">
+ </template-type-parameter>
+ <template-type-parameter name="Hash">
+ </template-type-parameter>
+ <template-type-parameter name="Pred">
+ </template-type-parameter>
+ <template-type-parameter name="Alloc">
+ </template-type-parameter>
+ </template>
+ <parameter name="x">
+ <paramtype>unordered_set<Value, Hash, Pred, Alloc> const&</paramtype>
+ </parameter>
+ <parameter name="y">
+ <paramtype>unordered_set<Value, Hash, Pred, Alloc> const&</paramtype>
+ </parameter>
+ <type>bool</type>
+ <notes>
+ <para>This is a boost extension.</para>
+ <para>Behavior is undefined if the two containers don't have
+ equivalent equality predicates.</para>
+ </notes>
+ </function>
+ </free-function-group>
+ <free-function-group name="swap">
+ <function name="swap">
+ <template>
+ <template-type-parameter name="Value">
+ </template-type-parameter>
+ <template-type-parameter name="Hash">
+ </template-type-parameter>
+ <template-type-parameter name="Pred">
+ </template-type-parameter>
+ <template-type-parameter name="Alloc">
+ </template-type-parameter>
+ </template>
+ <parameter name="x">
+ <paramtype>unordered_set<Value, Hash, Pred, Alloc>&</paramtype>
+ </parameter>
+ <parameter name="y">
+ <paramtype>unordered_set<Value, Hash, Pred, Alloc>&</paramtype>
+ </parameter>
+ <type>void</type>
+ <effects>
+ <para><code>x.swap(y)</code></para>
+ </effects>
+ <throws>
+ <para>If the allocators are equal, doesn't throw an exception unless it is thrown by the copy constructor or copy assignment operator of <code>Hash</code> or <code>Pred</code>.</para>
+ </throws>
+ <notes>
+ <para>For a discussion of the behavior when allocators aren't equal see
+ <link linkend="unordered.rationale.swapping_containers_with_unequal_allocators">the implementation details</link>.</para>
+ </notes>
+ </function>
+ </free-function-group>
+ </class>
+ <class name="unordered_multiset">
+ <template>
+ <template-type-parameter name="Value">
+ </template-type-parameter>
+ <template-type-parameter name="Hash">
+ <default><type>boost::hash<Value></type></default>
+ </template-type-parameter>
+ <template-type-parameter name="Pred">
+ <default><type>std::equal_to<Value></type></default>
+ </template-type-parameter>
+ <template-type-parameter name="Alloc">
+ <default><type>std::allocator<Value></type></default>
+ </template-type-parameter>
+ </template>
+ <purpose><simpara>
+ An unordered associative container that stores values. The same key can be stored multiple times.
+ </simpara></purpose>
+ <description>
+ <para>Based on chapter 23 of
+ <ulink url="http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2009/n2960.pdf">the working draft of the C++ standard [n2960]</ulink>.
+ But without the updated rules for allocators.
+ </para>
+ <para><emphasis role="bold">Template Parameters</emphasis>
+ <informaltable>
+ <tgroup cols="2">
+ <tbody>
+ <row>
+ <entry><emphasis>Value</emphasis></entry>
+ <entry>Value must be Assignable and CopyConstructible</entry></row>
+ <row>
+ <entry><emphasis>Hash</emphasis></entry>
+ <entry>A unary function object type that acts a hash function for a <code>Value</code>. It takes a single argument of type <code>Value</code> and returns a value of type std::size_t.</entry></row>
+ <row>
+ <entry><emphasis>Pred</emphasis></entry>
+ <entry>A binary function object that implements an equivalence relation on values of type <code>Value</code>.
+ A binary function object that induces an equivalence relation on values of type Key.
+ It takes two arguments of type Key and returns a value of type bool.</entry></row>
+ <row>
+ <entry><emphasis>Alloc</emphasis></entry>
+ <entry>An allocator whose value type is the same as the container's value type.</entry></row></tbody></tgroup></informaltable></para>
+ <para>The elements are organized into buckets. Keys with the same hash code are stored in the same bucket and elements with equivalent keys are stored next to each other.</para>
+ <para>The number of buckets can be automatically increased by a call to insert, or as the result of calling rehash.</para>
+ </description>
+ <typedef name="key_type">
+ <type>Value</type>
+ </typedef>
+ <typedef name="value_type">
+ <type>Value</type>
+ </typedef>
+ <typedef name="hasher">
+ <type>Hash</type>
+ </typedef>
+ <typedef name="key_equal">
+ <type>Pred</type>
+ </typedef>
+ <typedef name="allocator_type">
+ <type>Alloc</type>
+ </typedef>
+ <typedef name="pointer">
+ <type>typename allocator_type::pointer</type>
+ </typedef>
+ <typedef name="const_pointer">
+ <type>typename allocator_type::const_pointer</type>
+ </typedef>
+ <typedef name="reference">
+ <type>typename allocator_type::reference</type>
+ <purpose><simpara>lvalue of <type>value_type</type>.</simpara></purpose>
+ </typedef>
+ <typedef name="const_reference">
+ <type>typename allocator_type::const_reference</type>
+ <purpose><simpara>const lvalue of <type>value_type</type>.</simpara></purpose>
+ </typedef>
+ <typedef name="size_type">
+ <type><emphasis>implementation-defined</emphasis></type>
+ <description>
+ <para>An unsigned integral type.</para>
+ <para><type>size_type</type> can represent any non-negative value of <type>difference_type</type>.</para>
+ </description>
+ </typedef>
+ <typedef name="difference_type">
+ <type><emphasis>implementation-defined</emphasis></type>
+ <description>
+ <para>A signed integral type.</para>
+ <para>Is identical to the difference type of <type>iterator</type> and <type>const_iterator</type>.</para>
+ </description>
+ </typedef>
+ <typedef name="iterator">
+ <type><emphasis>implementation-defined</emphasis></type>
+ <description>
+ <para>A constant iterator whose value type is <type>value_type</type>. </para>
+ <para>The iterator category is at least a forward iterator.</para>
+ <para>Convertible to <type>const_iterator</type>.</para>
+ </description>
+ </typedef>
+ <typedef name="const_iterator">
+ <type><emphasis>implementation-defined</emphasis></type>
+ <description>
+ <para>A constant iterator whose value type is <type>value_type</type>. </para>
+ <para>The iterator category is at least a forward iterator.</para>
+ </description>
+ </typedef>
+ <typedef name="local_iterator">
+ <type><emphasis>implementation-defined</emphasis></type>
+ <description>
+ <para>An iterator with the same value type, difference type and pointer and reference type as <type>iterator</type>.</para>
+ <para>A local_iterator object can be used to iterate through a single bucket.</para>
+ </description>
+ </typedef>
+ <typedef name="const_local_iterator">
+ <type><emphasis>implementation-defined</emphasis></type>
+ <description>
+ <para>A constant iterator with the same value type, difference type and pointer and reference type as <type>const_iterator</type>.</para>
+ <para>A const_local_iterator object can be used to iterate through a single bucket.</para>
+ </description>
+ </typedef>
+ <constructor specifiers="explicit">
+ <parameter name="n">
+ <paramtype>size_type</paramtype>
+ <default><emphasis>implementation-defined</emphasis></default>
+ </parameter>
+ <parameter name="hf">
+ <paramtype>hasher const&</paramtype>
+ <default>hasher()</default>
+ </parameter>
+ <parameter name="eq">
+ <paramtype>key_equal const&</paramtype>
+ <default>key_equal()</default>
+ </parameter>
+ <parameter name="a">
+ <paramtype>allocator_type const&</paramtype>
+ <default>allocator_type()</default>
+ </parameter>
+ <postconditions>
+ <code><methodname>size</methodname>() == 0</code>
+ </postconditions>
+ <description>
+ <para>Constructs an empty container with at least n buckets, using hf as the hash function, eq as the key equality predicate, a as the allocator and a maximum load factor of 1.0.</para>
+ </description>
+ </constructor>
+ <constructor>
+ <template>
+ <template-type-parameter name="InputIterator">
+ </template-type-parameter>
+ </template>
+ <parameter name="f">
+ <paramtype>InputIterator</paramtype>
+ </parameter>
+ <parameter name="l">
+ <paramtype>InputIterator</paramtype>
+ </parameter>
+ <parameter name="n">
+ <paramtype>size_type</paramtype>
+ <default><emphasis>implementation-defined</emphasis></default>
+ </parameter>
+ <parameter name="hf">
+ <paramtype>hasher const&</paramtype>
+ <default>hasher()</default>
+ </parameter>
+ <parameter name="eq">
+ <paramtype>key_equal const&</paramtype>
+ <default>key_equal()</default>
+ </parameter>
+ <parameter name="a">
+ <paramtype>allocator_type const&</paramtype>
+ <default>allocator_type()</default>
+ </parameter>
+ <description>
+ <para>Constructs an empty container with at least n buckets, using hf as the hash function, eq as the key equality predicate, a as the allocator and a maximum load factor of 1.0 and inserts the elements from [f, l) into it.</para>
+ </description>
+ </constructor>
+ <constructor>
+ <parameter>
+ <paramtype>unordered_multiset const&</paramtype>
+ </parameter>
+ <description>
+ <para>The copy constructor. Copies the contained elements, hash function, predicate, maximum load factor and allocator.</para>
+ </description>
+ <requires>
+ <para><code>value_type</code> is copy constructible</para>
+ </requires>
+ </constructor>
+ <constructor>
+ <parameter>
+ <paramtype>unordered_multiset &&</paramtype>
+ </parameter>
+ <description>
+ <para>The move constructor.</para>
+ </description>
+ <notes>
+ <para>This is emulated on compilers without rvalue references.</para>
+ </notes>
+ <requires>
+ <para>
+ <code>value_type</code> is move constructible.
+ (TODO: This is not actually required in this implementation).
+ </para>
+ </requires>
+ </constructor>
+ <constructor specifiers="explicit">
+ <parameter name="a">
+ <paramtype>Allocator const&</paramtype>
+ </parameter>
+ <description>
+ <para>Constructs an empty container, using allocator <code>a</code>.</para>
+ </description>
+ </constructor>
+ <constructor>
+ <parameter name="x">
+ <paramtype>unordered_multiset const&</paramtype>
+ </parameter>
+ <parameter name="a">
+ <paramtype>Allocator const&</paramtype>
+ </parameter>
+ <description>
+ <para>Constructs an container, copying <code>x</code>'s contained elements, hash function, predicate, maximum load factor, but using allocator <code>a</code>.</para>
+ </description>
+ </constructor>
+ <destructor>
+ <notes>
+ <para>The destructor is applied to every element, and all memory is deallocated</para>
+ </notes>
+ </destructor>
+ <method name="operator=">
+ <parameter>
+ <paramtype>unordered_multiset const&</paramtype>
+ </parameter>
+ <type>unordered_multiset&</type>
+ <description>
+ <para>The assignment operator. Copies the contained elements, hash function, predicate and maximum load factor but not the allocator.</para>
+ </description>
+ <notes>
+ <para>
+ On compilers without rvalue references, there is a single assignment
+ operator with the signature <code>operator=(unordered_multiset)</code>
+ in order to emulate move semantics.
+ </para>
+ </notes>
+ <requires>
+ <para><code>value_type</code> is copy constructible</para>
+ </requires>
+ </method>
+ <method name="operator=">
+ <parameter>
+ <paramtype>unordered_multiset &&</paramtype>
+ </parameter>
+ <type>unordered_multiset&</type>
+ <description>
+ <para>The move assignment operator.</para>
+ </description>
+ <notes>
+ <para>
+ On compilers without rvalue references, there is a single assignment
+ operator with the signature <code>operator=(unordered_multiset)</code>
+ in order to emulate move semantics.
+ </para>
+ </notes>
+ <requires>
+ <para>
+ <code>value_type</code> is move constructible.
+ (TODO: This is not actually required in this implementation).
+ </para>
+ </requires>
+ </method>
+ <method name="get_allocator" cv="const">
+ <type>allocator_type</type>
+ </method>
+ <method-group name="size and capacity">
+ <method name="empty" cv="const">
+ <type>bool</type>
+ <returns>
+ <code><methodname>size</methodname>() == 0</code>
+ </returns>
+ </method>
+ <method name="size" cv="const">
+ <type>size_type</type>
+ <returns>
+ <code>std::distance(<methodname>begin</methodname>(), <methodname>end</methodname>())</code>
+ </returns>
+ </method>
+ <method name="max_size" cv="const">
+ <type>size_type</type>
+ <returns><code><methodname>size</methodname>()</code> of the largest possible container.
+ </returns>
+ </method>
+ </method-group>
+ <method-group name="iterators">
+ <overloaded-method name="begin">
+ <signature><type>iterator</type></signature>
+ <signature cv="const"><type>const_iterator</type></signature>
+ <returns>An iterator referring to the first element of the container, or if the container is empty the past-the-end value for the container.
+ </returns>
+ </overloaded-method>
+ <overloaded-method name="end">
+ <signature>
+ <type>iterator</type>
+ </signature>
+ <signature cv="const">
+ <type>const_iterator</type>
+ </signature>
+ <returns>An iterator which refers to the past-the-end value for the container.
+ </returns>
+ </overloaded-method>
+ <method name="cbegin" cv="const">
+ <type>const_iterator</type>
+ <returns>A constant iterator referring to the first element of the container, or if the container is empty the past-the-end value for the container.
+ </returns>
+ </method>
+ <method name="cend" cv="const">
+ <type>const_iterator</type>
+ <returns>A constant iterator which refers to the past-the-end value for the container.
+ </returns>
+ </method>
+ </method-group>
+ <method-group name="modifiers">
+ <method name="emplace">
+ <template>
+ <template-type-parameter name="Args" pack="1">
+ </template-type-parameter>
+ </template>
+ <parameter name="args" pack="1">
+ <paramtype>Args&&</paramtype>
+ </parameter>
+ <type>iterator</type>
+ <description>
+ <para>Inserts an object, constructed with the arguments <code>args</code>, in the container.</para>
+ </description>
+ <returns>
+ <para>An iterator pointing to the inserted element.</para>
+ </returns>
+ <throws>
+ <para>If an exception is thrown by an operation other than a call to <code>hasher</code> the function has no effect.</para>
+ </throws>
+ <notes>
+ <para>Can invalidate iterators, but only if the insert causes the load factor to be greater to or equal to the maximum load factor.</para>
+ <para>Pointers and references to elements are never invalidated.</para>
+ <para>If the compiler doesn't support variadic template arguments or rvalue
+ references, this is emulated for up to 10 arguments, with no support
+ for rvalue references or move semantics.</para>
+ </notes>
+ </method>
+ <method name="emplace_hint">
+ <template>
+ <template-type-parameter name="Args" pack="1">
+ </template-type-parameter>
+ </template>
+ <parameter name="hint">
+ <paramtype>const_iterator</paramtype>
+ </parameter>
+ <parameter name="args" pack="1">
+ <paramtype>Args&&</paramtype>
+ </parameter>
+ <type>iterator</type>
+ <description>
+ <para>Inserts an object, constructed with the arguments <code>args</code>, in the container.</para>
+ <para>hint is a suggestion to where the element should be inserted.</para>
+ </description>
+ <returns>
+ <para>An iterator pointing to the inserted element.</para>
+ </returns>
+ <throws>
+ <para>If an exception is thrown by an operation other than a call to <code>hasher</code> the function has no effect.</para>
+ </throws>
+ <notes>
+ <para>The standard is fairly vague on the meaning of the hint. But the only practical way to use it, and the only way that Boost.Unordered supports is to point to an existing element with the same value. </para>
+ <para>Can invalidate iterators, but only if the insert causes the load factor to be greater to or equal to the maximum load factor.</para>
+ <para>Pointers and references to elements are never invalidated.</para>
+ <para>If the compiler doesn't support variadic template arguments or rvalue
+ references, this is emulated for up to 10 arguments, with no support
+ for rvalue references or move semantics.</para>
+ </notes>
+ </method>
+ <method name="insert">
+ <parameter name="obj">
+ <paramtype>value_type const&</paramtype>
+ </parameter>
+ <type>iterator</type>
+ <description>
+ <para>Inserts obj in the container.</para>
+ </description>
+ <returns>
+ <para>An iterator pointing to the inserted element.</para>
+ </returns>
+ <throws>
+ <para>If an exception is thrown by an operation other than a call to <code>hasher</code> the function has no effect.</para>
+ </throws>
+ <notes>
+ <para>Can invalidate iterators, but only if the insert causes the load factor to be greater to or equal to the maximum load factor.</para>
+ <para>Pointers and references to elements are never invalidated.</para>
+ </notes>
+ </method>
+ <method name="insert">
+ <parameter name="hint">
+ <paramtype>const_iterator</paramtype>
+ </parameter>
+ <parameter name="obj">
+ <paramtype>value_type const&</paramtype>
+ </parameter>
+ <type>iterator</type>
+ <description>
+ <para>Inserts obj in the container.</para>
+ <para>hint is a suggestion to where the element should be inserted.</para>
+ </description>
+ <returns>
+ <para>An iterator pointing to the inserted element.</para>
+ </returns>
+ <throws>
+ <para>If an exception is thrown by an operation other than a call to <code>hasher</code> the function has no effect.</para>
+ </throws>
+ <notes>
+ <para>The standard is fairly vague on the meaning of the hint. But the only practical way to use it, and the only way that Boost.Unordered supports is to point to an existing element with the same value. </para>
+ <para>Can invalidate iterators, but only if the insert causes the load factor to be greater to or equal to the maximum load factor.</para>
+ <para>Pointers and references to elements are never invalidated.</para>
+ </notes>
+ </method>
+ <method name="insert">
+ <template>
+ <template-type-parameter name="InputIterator">
+ </template-type-parameter>
+ </template>
+ <parameter name="first">
+ <paramtype>InputIterator</paramtype>
+ </parameter>
+ <parameter name="last">
+ <paramtype>InputIterator</paramtype>
+ </parameter>
+ <type>void</type>
+ <description>
+ <para>Inserts a range of elements into the container.</para>
+ </description>
+ <throws>
+ <para>When inserting a single element, if an exception is thrown by an operation other than a call to <code>hasher</code> the function has no effect.</para>
+ </throws>
+ <notes>
+ <para>Can invalidate iterators, but only if the insert causes the load factor to be greater to or equal to the maximum load factor.</para>
+ <para>Pointers and references to elements are never invalidated.</para>
+ </notes>
+ </method>
+ <method name="erase">
+ <parameter name="position">
+ <paramtype>const_iterator</paramtype>
+ </parameter>
+ <type>iterator</type>
+ <description>
+ <para>Erase the element pointed to by <code>position</code>.</para>
+ </description>
+ <returns>
+ <para>The iterator following <code>position</code> before the erasure.</para>
+ </returns>
+ <throws>
+ <para>Only throws an exception if it is thrown by <code>hasher</code> or <code>key_equal</code>.</para>
+ <para>In this implementation, this overload doesn't call either function object's methods so it is no throw, but this might not be true in other implementations.</para>
+ </throws>
+ <notes>
+ <para>
+ When the number of elements is a lot smaller than the number of buckets
+ this function can be very inefficient as it has to search through empty
+ buckets for the next element, in order to return the iterator.
+ The method <methodname>quick_erase</methodname> is faster, but has yet
+ to be standardized.
+ </para>
+ </notes>
+ </method>
+ <method name="erase">
+ <parameter name="k">
+ <paramtype>key_type const&</paramtype>
+ </parameter>
+ <type>size_type</type>
+ <description>
+ <para>Erase all elements with key equivalent to <code>k</code>.</para>
+ </description>
+ <returns>
+ <para>The number of elements erased.</para>
+ </returns>
+ <throws>
+ <para>Only throws an exception if it is thrown by <code>hasher</code> or <code>key_equal</code>.</para>
+ </throws>
+ </method>
+ <method name="erase">
+ <parameter name="first">
+ <paramtype>const_iterator</paramtype>
+ </parameter>
+ <parameter name="last">
+ <paramtype>const_iterator</paramtype>
+ </parameter>
+ <type>iterator</type>
+ <description>
+ <para>Erases the elements in the range from <code>first</code> to <code>last</code>.</para>
+ </description>
+ <returns>
+ <para>The iterator following the erased elements - i.e. <code>last</code>.</para>
+ </returns>
+ <throws>
+ <para>Only throws an exception if it is thrown by <code>hasher</code> or <code>key_equal</code>.</para>
+ <para>In this implementation, this overload doesn't call either function object's methods so it is no throw, but this might not be true in other implementations.</para>
+ </throws>
+ </method>
+ <method name="quick_erase">
+ <parameter name="position">
+ <paramtype>const_iterator</paramtype>
+ </parameter>
+ <type>void</type>
+ <description>
+ <para>Erase the element pointed to by <code>position</code>.</para>
+ </description>
+ <throws>
+ <para>Only throws an exception if it is thrown by <code>hasher</code> or <code>key_equal</code>.</para>
+ <para>In this implementation, this overload doesn't call either function object's methods so it is no throw, but this might not be true in other implementations.</para>
+ </throws>
+ <notes>
+ <para>
+ This method is faster than <methodname>erase</methodname> as
+ it doesn't have to find the next element in the container -
+ a potentially costly operation.
+ </para>
+ <para>
+ As it hasn't been standardized, it's likely that this may
+ change in the future.
+ </para>
+ </notes>
+ </method>
+ <method name="erase_return_void">
+ <parameter name="position">
+ <paramtype>const_iterator</paramtype>
+ </parameter>
+ <type>void</type>
+ <description>
+ <para>Erase the element pointed to by <code>position</code>.</para>
+ </description>
+ <throws>
+ <para>Only throws an exception if it is thrown by <code>hasher</code> or <code>key_equal</code>.</para>
+ <para>In this implementation, this overload doesn't call either function object's methods so it is no throw, but this might not be true in other implementations.</para>
+ </throws>
+ <notes>
+ <para>
+ This method is now deprecated, use
+ <methodname>quick_return</methodname> instead. Although be
+ warned that as that isn't standardized yet, it could also
+ change.
+ </para>
+ </notes>
+ </method>
+ <method name="clear">
+ <type>void</type>
+ <description>
+ <para>Erases all elements in the container.</para>
+ </description>
+ <postconditions>
+ <para><code><methodname>size</methodname>() == 0</code></para>
+ </postconditions>
+ <throws>
+ <para>Never throws an exception.</para>
+ </throws>
+ </method>
+ <method name="swap">
+ <parameter>
+ <paramtype>unordered_multiset&</paramtype>
+ </parameter>
+ <type>void</type>
+ <throws>
+ <para>If the allocators are equal, doesn't throw an exception unless it is thrown by the copy constructor or copy assignment operator of <code>key_equal</code> or <code>hasher</code>.</para>
+ </throws>
+ <notes>
+ <para>For a discussion of the behavior when allocators aren't equal see
+ <link linkend="unordered.rationale.swapping_containers_with_unequal_allocators">the implementation details</link>.</para>
+ </notes>
+ </method>
+ </method-group>
+ <method-group name="observers">
+ <method name="hash_function" cv="const">
+ <type>hasher</type>
+ <returns>The container's hash function.
+ </returns>
+ </method>
+ <method name="key_eq" cv="const">
+ <type>key_equal</type>
+ <returns>The container's key equality predicate.
+ </returns>
+ </method>
+ </method-group>
+ <method-group name="lookup">
+ <overloaded-method name="find">
+ <signature>
+ <parameter name="k">
+ <paramtype>key_type const&</paramtype>
+ </parameter>
+ <type>iterator</type>
+ </signature>
+ <signature cv="const">
+ <parameter name="k">
+ <paramtype>key_type const&</paramtype>
+ </parameter>
+ <type>const_iterator</type>
+ </signature>
+ <signature>
+ <template>
+ <template-type-parameter name="CompatibleKey"/>
+ <template-type-parameter name="CompatibleHash"/>
+ <template-type-parameter name="CompatiblePredicate"/>
+ </template>
+ <parameter name="k">
+ <paramtype>CompatibleKey const&</paramtype>
+ </parameter>
+ <parameter name="hash">
+ <paramtype>CompatibleHash const&</paramtype>
+ </parameter>
+ <parameter name="eq">
+ <paramtype>CompatiblePredicate const&</paramtype>
+ </parameter>
+ <type>iterator</type>
+ </signature>
+ <signature cv="const">
+ <template>
+ <template-type-parameter name="CompatibleKey"/>
+ <template-type-parameter name="CompatibleHash"/>
+ <template-type-parameter name="CompatiblePredicate"/>
+ </template>
+ <parameter name="k">
+ <paramtype>CompatibleKey const&</paramtype>
+ </parameter>
+ <parameter name="hash">
+ <paramtype>CompatibleHash const&</paramtype>
+ </parameter>
+ <parameter name="eq">
+ <paramtype>CompatiblePredicate const&</paramtype>
+ </parameter>
+ <type>const_iterator</type>
+ </signature>
+ <returns>
+ <para>An iterator pointing to an element with key equivalent to <code>k</code>, or <code>b.end()</code> if no such element exists.</para>
+ </returns>
+ <notes><para>
+ The templated overloads are a non-standard extensions which
+ allows you to use a compatible hash function and equality
+ predicate for a key of a different type in order to avoid
+ an expensive type cast. In general, its use is not encouraged.
+ </para></notes>
+ </overloaded-method>
+ <method name="count" cv="const">
+ <parameter name="k">
+ <paramtype>key_type const&</paramtype>
+ </parameter>
+ <type>size_type</type>
+ <returns>
+ <para>The number of elements with key equivalent to <code>k</code>.</para>
+ </returns>
+ </method>
+ <overloaded-method name="equal_range">
+ <signature>
+ <parameter name="k">
+ <paramtype>key_type const&</paramtype>
+ </parameter>
+ <type>std::pair<iterator, iterator></type>
+ </signature>
+ <signature cv="const">
+ <parameter name="k">
+ <paramtype>key_type const&</paramtype>
+ </parameter>
+ <type>std::pair<const_iterator, const_iterator></type>
+ </signature>
+ <returns>
+ <para>A range containing all elements with key equivalent to <code>k</code>.
+ If the container doesn't container any such elements, returns
+ <code><functionname>std::make_pair</functionname>(<methodname>b.end</methodname>(),<methodname>b.end</methodname>())</code>.
+ </para>
+ </returns>
+ </overloaded-method>
+ </method-group>
+ <method-group name="bucket interface">
+ <method name="bucket_count" cv="const">
+ <type>size_type</type>
+ <returns>
+ <para>The number of buckets.</para>
+ </returns>
+ </method>
+ <method name="max_bucket_count" cv="const">
+ <type>size_type</type>
+ <returns>
+ <para>An upper bound on the number of buckets.</para>
+ </returns>
+ </method>
+ <method name="bucket_size" cv="const">
+ <parameter name="n">
+ <paramtype>size_type</paramtype>
+ </parameter>
+ <type>size_type</type>
+ <requires>
+ <para><code>n < <methodname>bucket_count</methodname>()</code></para>
+ </requires>
+ <returns>
+ <para>The number of elements in bucket <code>n</code>.</para>
+ </returns>
+ </method>
+ <method name="bucket" cv="const">
+ <parameter name="k">
+ <paramtype>key_type const&</paramtype>
+ </parameter>
+ <type>size_type</type>
+ <returns>
+ <para>The index of the bucket which would contain an element with key <code>k</code>.</para>
+ </returns>
+ <postconditions>
+ <para>The return value is less than <code>bucket_count()</code></para>
+ </postconditions>
+ </method>
+ <overloaded-method name="begin">
+ <signature>
+ <parameter name="n">
+ <paramtype>size_type</paramtype>
+ </parameter>
+ <type>local_iterator</type>
+ </signature>
+ <signature cv="const">
+ <parameter name="n">
+ <paramtype>size_type</paramtype>
+ </parameter>
+ <type>const_local_iterator</type>
+ </signature>
+ <requires>
+ <para><code>n</code> shall be in the range <code>[0, bucket_count())</code>.</para>
+ </requires>
+ <returns>
+ <para>A local iterator pointing the first element in the bucket with index <code>n</code>.</para>
+ </returns>
+ </overloaded-method>
+ <overloaded-method name="end">
+ <signature>
+ <parameter name="n">
+ <paramtype>size_type</paramtype>
+ </parameter>
+ <type>local_iterator</type>
+ </signature>
+ <signature cv="const">
+ <parameter name="n">
+ <paramtype>size_type</paramtype>
+ </parameter>
+ <type>const_local_iterator</type>
+ </signature>
+ <requires>
+ <para><code>n</code> shall be in the range <code>[0, bucket_count())</code>.</para>
+ </requires>
+ <returns>
+ <para>A local iterator pointing the 'one past the end' element in the bucket with index <code>n</code>.</para>
+ </returns>
+ </overloaded-method>
+ <method name="cbegin" cv="const">
+ <parameter name="n">
+ <paramtype>size_type</paramtype>
+ </parameter>
+ <type>const_local_iterator</type>
+ <requires>
+ <para><code>n</code> shall be in the range <code>[0, bucket_count())</code>.</para>
+ </requires>
+ <returns>
+ <para>A constant local iterator pointing the first element in the bucket with index <code>n</code>.</para>
+ </returns>
+ </method>
+ <method name="cend">
+ <parameter name="n">
+ <paramtype>size_type</paramtype>
+ </parameter>
+ <type>const_local_iterator</type>
+ <requires>
+ <para><code>n</code> shall be in the range <code>[0, bucket_count())</code>.</para>
+ </requires>
+ <returns>
+ <para>A constant local iterator pointing the 'one past the end' element in the bucket with index <code>n</code>.</para>
+ </returns>
+ </method>
+ </method-group>
+ <method-group name="hash policy">
+ <method name="load_factor" cv="const">
+ <type>float</type>
+ <returns>
+ <para>The average number of elements per bucket.</para>
+ </returns>
+ </method>
+ <method name="max_load_factor" cv="const">
+ <type>float</type>
+ <returns>
+ <para>Returns the current maximum load factor.</para>
+ </returns>
+ </method>
+ <method name="max_load_factor">
+ <parameter name="z">
+ <paramtype>float</paramtype>
+ </parameter>
+ <type>void</type>
+ <effects>
+ <para>Changes the container's maximum load factor, using <code>z</code> as a hint.</para>
+ </effects>
+ </method>
+ <method name="rehash">
+ <parameter name="n">
+ <paramtype>size_type</paramtype>
+ </parameter>
+ <type>void</type>
+ <description>
+ <para>Changes the number of buckets so that there at least <code>n</code> buckets, and so that the load factor is less than the maximum load factor.</para>
+ <para>Invalidates iterators, and changes the order of elements. Pointers and references to elements are not invalidated.</para>
+ </description>
+ <throws>
+ <para>The function has no effect if an exception is thrown, unless it is thrown by the container's hash function or comparison function.</para>
+ </throws>
+ </method>
+ </method-group>
+ <free-function-group name="Equality Comparisons">
+ <function name="operator==">
+ <template>
+ <template-type-parameter name="Value">
+ </template-type-parameter>
+ <template-type-parameter name="Hash">
+ </template-type-parameter>
+ <template-type-parameter name="Pred">
+ </template-type-parameter>
+ <template-type-parameter name="Alloc">
+ </template-type-parameter>
+ </template>
+ <parameter name="x">
+ <paramtype>unordered_multiset<Value, Hash, Pred, Alloc> const&</paramtype>
+ </parameter>
+ <parameter name="y">
+ <paramtype>unordered_multiset<Value, Hash, Pred, Alloc> const&</paramtype>
+ </parameter>
+ <type>bool</type>
+ <notes>
+ <para>This is a boost extension.</para>
+ <para>Behavior is undefined if the two containers don't have
+ equivalent equality predicates.</para>
+ </notes>
+ </function>
+ <function name="operator!=">
+ <template>
+ <template-type-parameter name="Value">
+ </template-type-parameter>
+ <template-type-parameter name="Hash">
+ </template-type-parameter>
+ <template-type-parameter name="Pred">
+ </template-type-parameter>
+ <template-type-parameter name="Alloc">
+ </template-type-parameter>
+ </template>
+ <parameter name="x">
+ <paramtype>unordered_multiset<Value, Hash, Pred, Alloc> const&</paramtype>
+ </parameter>
+ <parameter name="y">
+ <paramtype>unordered_multiset<Value, Hash, Pred, Alloc> const&</paramtype>
+ </parameter>
+ <type>bool</type>
+ <notes>
+ <para>This is a boost extension.</para>
+ <para>Behavior is undefined if the two containers don't have
+ equivalent equality predicates.</para>
+ </notes>
+ </function>
+ </free-function-group>
+ <free-function-group name="swap">
+ <function name="swap">
+ <template>
+ <template-type-parameter name="Value">
+ </template-type-parameter>
+ <template-type-parameter name="Hash">
+ </template-type-parameter>
+ <template-type-parameter name="Pred">
+ </template-type-parameter>
+ <template-type-parameter name="Alloc">
+ </template-type-parameter>
+ </template>
+ <parameter name="x">
+ <paramtype>unordered_multiset<Value, Hash, Pred, Alloc>&</paramtype>
+ </parameter>
+ <parameter name="y">
+ <paramtype>unordered_multiset<Value, Hash, Pred, Alloc>&</paramtype>
+ </parameter>
+ <type>void</type>
+ <effects>
+ <para><code>x.swap(y)</code></para>
+ </effects>
+ <throws>
+ <para>If the allocators are equal, doesn't throw an exception unless it is thrown by the copy constructor or copy assignment operator of <code>Hash</code> or <code>Pred</code>.</para>
+ </throws>
+ <notes>
+ <para>For a discussion of the behavior when allocators aren't equal see
+ <link linkend="unordered.rationale.swapping_containers_with_unequal_allocators">the implementation details</link>.</para>
+ </notes>
+ </function>
+ </free-function-group>
+ </class>
+ </namespace>
+ </header>
+ <header name="boost/unordered_map.hpp">
+ <namespace name="boost">
+ <class name="unordered_map">
+ <template>
+ <template-type-parameter name="Key">
+ </template-type-parameter>
+ <template-type-parameter name="Mapped">
+ </template-type-parameter>
+ <template-type-parameter name="Hash">
+ <default><type>boost::hash<Key></type></default>
+ </template-type-parameter>
+ <template-type-parameter name="Pred">
+ <default><type>std::equal_to<Key></type></default>
+ </template-type-parameter>
+ <template-type-parameter name="Alloc">
+ <default><type>std::allocator<std::pair<Key const, Mapped> ></type></default>
+ </template-type-parameter>
+ </template>
+ <purpose><simpara>
+ An unordered associative container that associates unique keys with another value.
+ </simpara></purpose>
+ <description>
+ <para>Based on chapter 23 of
+ <ulink url="http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2009/n2960.pdf">the working draft of the C++ standard [n2960]</ulink>.
+ But without the updated rules for allocators.
+ </para>
+ <para><emphasis role="bold">Template Parameters</emphasis>
+ <informaltable>
+ <tgroup cols="2">
+ <tbody>
+ <row>
+ <entry><emphasis>Key</emphasis></entry>
+ <entry>Key must be Assignable and CopyConstructible.</entry></row>
+ <row>
+ <entry><emphasis>Mapped</emphasis></entry>
+ <entry>Mapped must be CopyConstructible</entry></row>
+ <row>
+ <entry><emphasis>Hash</emphasis></entry>
+ <entry>A unary function object type that acts a hash function for a <code>Key</code>. It takes a single argument of type <code>Key</code> and returns a value of type std::size_t.</entry></row>
+ <row>
+ <entry><emphasis>Pred</emphasis></entry>
+ <entry>A binary function object that implements an equivalence relation on values of type <code>Key</code>.
+ A binary function object that induces an equivalence relation on values of type Key.
+ It takes two arguments of type Key and returns a value of type bool.</entry></row>
+ <row>
+ <entry><emphasis>Alloc</emphasis></entry>
+ <entry>An allocator whose value type is the same as the container's value type.</entry></row></tbody></tgroup></informaltable></para>
+ <para>The elements are organized into buckets. Keys with the same hash code are stored in the same bucket.</para>
+ <para>The number of buckets can be automatically increased by a call to insert, or as the result of calling rehash.</para>
+ </description>
+ <typedef name="key_type">
+ <type>Key</type>
+ </typedef>
+ <typedef name="value_type">
+ <type>std::pair<Key const, Mapped></type>
+ </typedef>
+ <typedef name="mapped_type">
+ <type>Mapped</type>
+ </typedef>
+ <typedef name="hasher">
+ <type>Hash</type>
+ </typedef>
+ <typedef name="key_equal">
+ <type>Pred</type>
+ </typedef>
+ <typedef name="allocator_type">
+ <type>Alloc</type>
+ </typedef>
+ <typedef name="pointer">
+ <type>typename allocator_type::pointer</type>
+ </typedef>
+ <typedef name="const_pointer">
+ <type>typename allocator_type::const_pointer</type>
+ </typedef>
+ <typedef name="reference">
+ <type>typename allocator_type::reference</type>
+ <purpose><simpara>lvalue of <type>value_type</type>.</simpara></purpose>
+ </typedef>
+ <typedef name="const_reference">
+ <type>typename allocator_type::const_reference</type>
+ <purpose><simpara>const lvalue of <type>value_type</type>.</simpara></purpose>
+ </typedef>
+ <typedef name="size_type">
+ <type><emphasis>implementation-defined</emphasis></type>
+ <description>
+ <para>An unsigned integral type.</para>
+ <para><type>size_type</type> can represent any non-negative value of <type>difference_type</type>.</para>
+ </description>
+ </typedef>
+ <typedef name="difference_type">
+ <type><emphasis>implementation-defined</emphasis></type>
+ <description>
+ <para>A signed integral type.</para>
+ <para>Is identical to the difference type of <type>iterator</type> and <type>const_iterator</type>.</para>
+ </description>
+ </typedef>
+ <typedef name="iterator">
+ <type><emphasis>implementation-defined</emphasis></type>
+ <description>
+ <para>A iterator whose value type is <type>value_type</type>. </para>
+ <para>The iterator category is at least a forward iterator.</para>
+ <para>Convertible to <type>const_iterator</type>.</para>
+ </description>
+ </typedef>
+ <typedef name="const_iterator">
+ <type><emphasis>implementation-defined</emphasis></type>
+ <description>
+ <para>A constant iterator whose value type is <type>value_type</type>. </para>
+ <para>The iterator category is at least a forward iterator.</para>
+ </description>
+ </typedef>
+ <typedef name="local_iterator">
+ <type><emphasis>implementation-defined</emphasis></type>
+ <description>
+ <para>An iterator with the same value type, difference type and pointer and reference type as <type>iterator</type>.</para>
+ <para>A local_iterator object can be used to iterate through a single bucket.</para>
+ </description>
+ </typedef>
+ <typedef name="const_local_iterator">
+ <type><emphasis>implementation-defined</emphasis></type>
+ <description>
+ <para>A constant iterator with the same value type, difference type and pointer and reference type as <type>const_iterator</type>.</para>
+ <para>A const_local_iterator object can be used to iterate through a single bucket.</para>
+ </description>
+ </typedef>
+ <constructor specifiers="explicit">
+ <parameter name="n">
+ <paramtype>size_type</paramtype>
+ <default><emphasis>implementation-defined</emphasis></default>
+ </parameter>
+ <parameter name="hf">
+ <paramtype>hasher const&</paramtype>
+ <default>hasher()</default>
+ </parameter>
+ <parameter name="eq">
+ <paramtype>key_equal const&</paramtype>
+ <default>key_equal()</default>
+ </parameter>
+ <parameter name="a">
+ <paramtype>allocator_type const&</paramtype>
+ <default>allocator_type()</default>
+ </parameter>
+ <postconditions>
+ <code><methodname>size</methodname>() == 0</code>
+ </postconditions>
+ <description>
+ <para>Constructs an empty container with at least n buckets, using hf as the hash function, eq as the key equality predicate, a as the allocator and a maximum load factor of 1.0.</para>
+ </description>
+ </constructor>
+ <constructor>
+ <template>
+ <template-type-parameter name="InputIterator">
+ </template-type-parameter>
+ </template>
+ <parameter name="f">
+ <paramtype>InputIterator</paramtype>
+ </parameter>
+ <parameter name="l">
+ <paramtype>InputIterator</paramtype>
+ </parameter>
+ <parameter name="n">
+ <paramtype>size_type</paramtype>
+ <default><emphasis>implementation-defined</emphasis></default>
+ </parameter>
+ <parameter name="hf">
+ <paramtype>hasher const&</paramtype>
+ <default>hasher()</default>
+ </parameter>
+ <parameter name="eq">
+ <paramtype>key_equal const&</paramtype>
+ <default>key_equal()</default>
+ </parameter>
+ <parameter name="a">
+ <paramtype>allocator_type const&</paramtype>
+ <default>allocator_type()</default>
+ </parameter>
+ <description>
+ <para>Constructs an empty container with at least n buckets, using hf as the hash function, eq as the key equality predicate, a as the allocator and a maximum load factor of 1.0 and inserts the elements from [f, l) into it.</para>
+ </description>
+ </constructor>
+ <constructor>
+ <parameter>
+ <paramtype>unordered_map const&</paramtype>
+ </parameter>
+ <description>
+ <para>The copy constructor. Copies the contained elements, hash function, predicate, maximum load factor and allocator.</para>
+ </description>
+ <requires>
+ <para><code>value_type</code> is copy constructible</para>
+ </requires>
+ </constructor>
+ <constructor>
+ <parameter>
+ <paramtype>unordered_map &&</paramtype>
+ </parameter>
+ <description>
+ <para>The move constructor.</para>
+ </description>
+ <notes>
+ <para>This is emulated on compilers without rvalue references.</para>
+ </notes>
+ <requires>
+ <para>
+ <code>value_type</code> is move constructible.
+ (TODO: This is not actually required in this implementation).
+ </para>
+ </requires>
+ </constructor>
+ <constructor specifiers="explicit">
+ <parameter name="a">
+ <paramtype>Allocator const&</paramtype>
+ </parameter>
+ <description>
+ <para>Constructs an empty container, using allocator <code>a</code>.</para>
+ </description>
+ </constructor>
+ <constructor>
+ <parameter name="x">
+ <paramtype>unordered_map const&</paramtype>
+ </parameter>
+ <parameter name="a">
+ <paramtype>Allocator const&</paramtype>
+ </parameter>
+ <description>
+ <para>Constructs an container, copying <code>x</code>'s contained elements, hash function, predicate, maximum load factor, but using allocator <code>a</code>.</para>
+ </description>
+ </constructor>
+ <destructor>
+ <notes>
+ <para>The destructor is applied to every element, and all memory is deallocated</para>
+ </notes>
+ </destructor>
+ <method name="operator=">
+ <parameter>
+ <paramtype>unordered_map const&</paramtype>
+ </parameter>
+ <type>unordered_map&</type>
+ <description>
+ <para>The assignment operator. Copies the contained elements, hash function, predicate and maximum load factor but not the allocator.</para>
+ </description>
+ <notes>
+ <para>
+ On compilers without rvalue references, there is a single assignment
+ operator with the signature <code>operator=(unordered_map)</code>
+ in order to emulate move semantics.
+ </para>
+ </notes>
+ <requires>
+ <para><code>value_type</code> is copy constructible</para>
+ </requires>
+ </method>
+ <method name="operator=">
+ <parameter>
+ <paramtype>unordered_map &&</paramtype>
+ </parameter>
+ <type>unordered_map&</type>
+ <description>
+ <para>The move assignment operator.</para>
+ </description>
+ <notes>
+ <para>
+ On compilers without rvalue references, there is a single assignment
+ operator with the signature <code>operator=(unordered_map)</code>
+ in order to emulate move semantics.
+ </para>
+ </notes>
+ <requires>
+ <para>
+ <code>value_type</code> is move constructible.
+ (TODO: This is not actually required in this implementation).
+ </para>
+ </requires>
+ </method>
+ <method name="get_allocator" cv="const">
+ <type>allocator_type</type>
+ </method>
+ <method-group name="size and capacity">
+ <method name="empty" cv="const">
+ <type>bool</type>
+ <returns>
+ <code><methodname>size</methodname>() == 0</code>
+ </returns>
+ </method>
+ <method name="size" cv="const">
+ <type>size_type</type>
+ <returns>
+ <code>std::distance(<methodname>begin</methodname>(), <methodname>end</methodname>())</code>
+ </returns>
+ </method>
+ <method name="max_size" cv="const">
+ <type>size_type</type>
+ <returns><code><methodname>size</methodname>()</code> of the largest possible container.
+ </returns>
+ </method>
+ </method-group>
+ <method-group name="iterators">
+ <overloaded-method name="begin">
+ <signature><type>iterator</type></signature>
+ <signature cv="const"><type>const_iterator</type></signature>
+ <returns>An iterator referring to the first element of the container, or if the container is empty the past-the-end value for the container.
+ </returns>
+ </overloaded-method>
+ <overloaded-method name="end">
+ <signature>
+ <type>iterator</type>
+ </signature>
+ <signature cv="const">
+ <type>const_iterator</type>
+ </signature>
+ <returns>An iterator which refers to the past-the-end value for the container.
+ </returns>
+ </overloaded-method>
+ <method name="cbegin" cv="const">
+ <type>const_iterator</type>
+ <returns>A constant iterator referring to the first element of the container, or if the container is empty the past-the-end value for the container.
+ </returns>
+ </method>
+ <method name="cend" cv="const">
+ <type>const_iterator</type>
+ <returns>A constant iterator which refers to the past-the-end value for the container.
+ </returns>
+ </method>
+ </method-group>
+ <method-group name="modifiers">
+ <method name="emplace">
+ <template>
+ <template-type-parameter name="Args" pack="1">
+ </template-type-parameter>
+ </template>
+ <parameter name="args" pack="1">
+ <paramtype>Args&&</paramtype>
+ </parameter>
+ <type>std::pair<iterator, bool></type>
+ <description>
+ <para>Inserts an object, constructed with the arguments <code>args</code>, in the container if and only if there is no element in the container with an equivalent key.</para>
+ </description>
+ <returns>
+ <para>The bool component of the return type is true if an insert took place.</para>
+ <para>If an insert took place, then the iterator points to the newly inserted element. Otherwise, it points to the element with equivalent key.</para>
+ </returns>
+ <throws>
+ <para>If an exception is thrown by an operation other than a call to <code>hasher</code> the function has no effect.</para>
+ </throws>
+ <notes>
+ <para>Can invalidate iterators, but only if the insert causes the load factor to be greater to or equal to the maximum load factor.</para>
+ <para>Pointers and references to elements are never invalidated.</para>
+ <para>If the compiler doesn't support variadic template arguments or rvalue
+ references, this is emulated for up to 10 arguments, with no support
+ for rvalue references or move semantics.</para>
+ </notes>
+ </method>
+ <method name="emplace_hint">
+ <template>
+ <template-type-parameter name="Args" pack="1">
+ </template-type-parameter>
+ </template>
+ <parameter name="hint">
+ <paramtype>const_iterator</paramtype>
+ </parameter>
+ <parameter name="args" pack="1">
+ <paramtype>Args&&</paramtype>
+ </parameter>
+ <type>iterator</type>
+ <description>
+ <para>Inserts an object, constructed with the arguments <code>args</code>, in the container if and only if there is no element in the container with an equivalent key.</para>
+ <para>hint is a suggestion to where the element should be inserted.</para>
+ </description>
+ <returns>
+ <para>If an insert took place, then the iterator points to the newly inserted element. Otherwise, it points to the element with equivalent key.</para>
+ </returns>
+ <throws>
+ <para>If an exception is thrown by an operation other than a call to <code>hasher</code> the function has no effect.</para>
+ </throws>
+ <notes>
+ <para>The standard is fairly vague on the meaning of the hint. But the only practical way to use it, and the only way that Boost.Unordered supports is to point to an existing element with the same key. </para>
+ <para>Can invalidate iterators, but only if the insert causes the load factor to be greater to or equal to the maximum load factor.</para>
+ <para>Pointers and references to elements are never invalidated.</para>
+ <para>If the compiler doesn't support variadic template arguments or rvalue
+ references, this is emulated for up to 10 arguments, with no support
+ for rvalue references or move semantics.</para>
+ </notes>
+ </method>
+ <method name="insert">
+ <parameter name="obj">
+ <paramtype>value_type const&</paramtype>
+ </parameter>
+ <type>std::pair<iterator, bool></type>
+ <description>
+ <para>Inserts obj in the container if and only if there is no element in the container with an equivalent key.</para>
+ </description>
+ <returns>
+ <para>The bool component of the return type is true if an insert took place.</para>
+ <para>If an insert took place, then the iterator points to the newly inserted element. Otherwise, it points to the element with equivalent key.</para>
+ </returns>
+ <throws>
+ <para>If an exception is thrown by an operation other than a call to <code>hasher</code> the function has no effect.</para>
+ </throws>
+ <notes>
+ <para>Can invalidate iterators, but only if the insert causes the load factor to be greater to or equal to the maximum load factor.</para>
+ <para>Pointers and references to elements are never invalidated.</para>
+ </notes>
+ </method>
+ <method name="insert">
+ <parameter name="hint">
+ <paramtype>const_iterator</paramtype>
+ </parameter>
+ <parameter name="obj">
+ <paramtype>value_type const&</paramtype>
+ </parameter>
+ <type>iterator</type>
+ <description>
+ <para>Inserts obj in the container if and only if there is no element in the container with an equivalent key.</para>
+ <para>hint is a suggestion to where the element should be inserted.</para>
+ </description>
+ <returns>
+ <para>If an insert took place, then the iterator points to the newly inserted element. Otherwise, it points to the element with equivalent key.</para>
+ </returns>
+ <throws>
+ <para>If an exception is thrown by an operation other than a call to <code>hasher</code> the function has no effect.</para>
+ </throws>
+ <notes>
+ <para>The standard is fairly vague on the meaning of the hint. But the only practical way to use it, and the only way that Boost.Unordered supports is to point to an existing element with the same key. </para>
+ <para>Can invalidate iterators, but only if the insert causes the load factor to be greater to or equal to the maximum load factor.</para>
+ <para>Pointers and references to elements are never invalidated.</para>
+ </notes>
+ </method>
+ <method name="insert">
+ <template>
+ <template-type-parameter name="InputIterator">
+ </template-type-parameter>
+ </template>
+ <parameter name="first">
+ <paramtype>InputIterator</paramtype>
+ </parameter>
+ <parameter name="last">
+ <paramtype>InputIterator</paramtype>
+ </parameter>
+ <type>void</type>
+ <description>
+ <para>Inserts a range of elements into the container. Elements are inserted if and only if there is no element in the container with an equivalent key.</para>
+ </description>
+ <throws>
+ <para>When inserting a single element, if an exception is thrown by an operation other than a call to <code>hasher</code> the function has no effect.</para>
+ </throws>
+ <notes>
+ <para>Can invalidate iterators, but only if the insert causes the load factor to be greater to or equal to the maximum load factor.</para>
+ <para>Pointers and references to elements are never invalidated.</para>
+ </notes>
+ </method>
+ <method name="erase">
+ <parameter name="position">
+ <paramtype>const_iterator</paramtype>
+ </parameter>
+ <type>iterator</type>
+ <description>
+ <para>Erase the element pointed to by <code>position</code>.</para>
+ </description>
+ <returns>
+ <para>The iterator following <code>position</code> before the erasure.</para>
+ </returns>
+ <throws>
+ <para>Only throws an exception if it is thrown by <code>hasher</code> or <code>key_equal</code>.</para>
+ <para>In this implementation, this overload doesn't call either function object's methods so it is no throw, but this might not be true in other implementations.</para>
+ </throws>
+ <notes>
+ <para>
+ When the number of elements is a lot smaller than the number of buckets
+ this function can be very inefficient as it has to search through empty
+ buckets for the next element, in order to return the iterator.
+ The method <methodname>quick_erase</methodname> is faster, but has yet
+ to be standardized.
+ </para>
+ </notes>
+ </method>
+ <method name="erase">
+ <parameter name="k">
+ <paramtype>key_type const&</paramtype>
+ </parameter>
+ <type>size_type</type>
+ <description>
+ <para>Erase all elements with key equivalent to <code>k</code>.</para>
+ </description>
+ <returns>
+ <para>The number of elements erased.</para>
+ </returns>
+ <throws>
+ <para>Only throws an exception if it is thrown by <code>hasher</code> or <code>key_equal</code>.</para>
+ </throws>
+ </method>
+ <method name="erase">
+ <parameter name="first">
+ <paramtype>const_iterator</paramtype>
+ </parameter>
+ <parameter name="last">
+ <paramtype>const_iterator</paramtype>
+ </parameter>
+ <type>iterator</type>
+ <description>
+ <para>Erases the elements in the range from <code>first</code> to <code>last</code>.</para>
+ </description>
+ <returns>
+ <para>The iterator following the erased elements - i.e. <code>last</code>.</para>
+ </returns>
+ <throws>
+ <para>Only throws an exception if it is thrown by <code>hasher</code> or <code>key_equal</code>.</para>
+ <para>In this implementation, this overload doesn't call either function object's methods so it is no throw, but this might not be true in other implementations.</para>
+ </throws>
+ </method>
+ <method name="quick_erase">
+ <parameter name="position">
+ <paramtype>const_iterator</paramtype>
+ </parameter>
+ <type>void</type>
+ <description>
+ <para>Erase the element pointed to by <code>position</code>.</para>
+ </description>
+ <throws>
+ <para>Only throws an exception if it is thrown by <code>hasher</code> or <code>key_equal</code>.</para>
+ <para>In this implementation, this overload doesn't call either function object's methods so it is no throw, but this might not be true in other implementations.</para>
+ </throws>
+ <notes>
+ <para>
+ This method is faster than <methodname>erase</methodname> as
+ it doesn't have to find the next element in the container -
+ a potentially costly operation.
+ </para>
+ <para>
+ As it hasn't been standardized, it's likely that this may
+ change in the future.
+ </para>
+ </notes>
+ </method>
+ <method name="erase_return_void">
+ <parameter name="position">
+ <paramtype>const_iterator</paramtype>
+ </parameter>
+ <type>void</type>
+ <description>
+ <para>Erase the element pointed to by <code>position</code>.</para>
+ </description>
+ <throws>
+ <para>Only throws an exception if it is thrown by <code>hasher</code> or <code>key_equal</code>.</para>
+ <para>In this implementation, this overload doesn't call either function object's methods so it is no throw, but this might not be true in other implementations.</para>
+ </throws>
+ <notes>
+ <para>
+ This method is now deprecated, use
+ <methodname>quick_return</methodname> instead. Although be
+ warned that as that isn't standardized yet, it could also
+ change.
+ </para>
+ </notes>
+ </method>
+ <method name="clear">
+ <type>void</type>
+ <description>
+ <para>Erases all elements in the container.</para>
+ </description>
+ <postconditions>
+ <para><code><methodname>size</methodname>() == 0</code></para>
+ </postconditions>
+ <throws>
+ <para>Never throws an exception.</para>
+ </throws>
+ </method>
+ <method name="swap">
+ <parameter>
+ <paramtype>unordered_map&</paramtype>
+ </parameter>
+ <type>void</type>
+ <throws>
+ <para>If the allocators are equal, doesn't throw an exception unless it is thrown by the copy constructor or copy assignment operator of <code>key_equal</code> or <code>hasher</code>.</para>
+ </throws>
+ <notes>
+ <para>For a discussion of the behavior when allocators aren't equal see
+ <link linkend="unordered.rationale.swapping_containers_with_unequal_allocators">the implementation details</link>.</para>
+ </notes>
+ </method>
+ </method-group>
+ <method-group name="observers">
+ <method name="hash_function" cv="const">
+ <type>hasher</type>
+ <returns>The container's hash function.
+ </returns>
+ </method>
+ <method name="key_eq" cv="const">
+ <type>key_equal</type>
+ <returns>The container's key equality predicate.
+ </returns>
+ </method>
+ </method-group>
+ <method-group name="lookup">
+ <overloaded-method name="find">
+ <signature>
+ <parameter name="k">
+ <paramtype>key_type const&</paramtype>
+ </parameter>
+ <type>iterator</type>
+ </signature>
+ <signature cv="const">
+ <parameter name="k">
+ <paramtype>key_type const&</paramtype>
+ </parameter>
+ <type>const_iterator</type>
+ </signature>
+ <signature>
+ <template>
+ <template-type-parameter name="CompatibleKey"/>
+ <template-type-parameter name="CompatibleHash"/>
+ <template-type-parameter name="CompatiblePredicate"/>
+ </template>
+ <parameter name="k">
+ <paramtype>CompatibleKey const&</paramtype>
+ </parameter>
+ <parameter name="hash">
+ <paramtype>CompatibleHash const&</paramtype>
+ </parameter>
+ <parameter name="eq">
+ <paramtype>CompatiblePredicate const&</paramtype>
+ </parameter>
+ <type>iterator</type>
+ </signature>
+ <signature cv="const">
+ <template>
+ <template-type-parameter name="CompatibleKey"/>
+ <template-type-parameter name="CompatibleHash"/>
+ <template-type-parameter name="CompatiblePredicate"/>
+ </template>
+ <parameter name="k">
+ <paramtype>CompatibleKey const&</paramtype>
+ </parameter>
+ <parameter name="hash">
+ <paramtype>CompatibleHash const&</paramtype>
+ </parameter>
+ <parameter name="eq">
+ <paramtype>CompatiblePredicate const&</paramtype>
+ </parameter>
+ <type>const_iterator</type>
+ </signature>
+ <returns>
+ <para>An iterator pointing to an element with key equivalent to <code>k</code>, or <code>b.end()</code> if no such element exists.</para>
+ </returns>
+ <notes><para>
+ The templated overloads are a non-standard extensions which
+ allows you to use a compatible hash function and equality
+ predicate for a key of a different type in order to avoid
+ an expensive type cast. In general, its use is not encouraged.
+ </para></notes>
+ </overloaded-method>
+ <method name="count" cv="const">
+ <parameter name="k">
+ <paramtype>key_type const&</paramtype>
+ </parameter>
+ <type>size_type</type>
+ <returns>
+ <para>The number of elements with key equivalent to <code>k</code>.</para>
+ </returns>
+ </method>
+ <overloaded-method name="equal_range">
+ <signature>
+ <parameter name="k">
+ <paramtype>key_type const&</paramtype>
+ </parameter>
+ <type>std::pair<iterator, iterator></type>
+ </signature>
+ <signature cv="const">
+ <parameter name="k">
+ <paramtype>key_type const&</paramtype>
+ </parameter>
+ <type>std::pair<const_iterator, const_iterator></type>
+ </signature>
+ <returns>
+ <para>A range containing all elements with key equivalent to <code>k</code>.
+ If the container doesn't container any such elements, returns
+ <code><functionname>std::make_pair</functionname>(<methodname>b.end</methodname>(),<methodname>b.end</methodname>())</code>.
+ </para>
+ </returns>
+ </overloaded-method>
+ <method name="operator[]">
+ <parameter name="k">
+ <paramtype>key_type const&</paramtype>
+ </parameter>
+ <type>mapped_type&</type>
+ <effects>
+ <para>If the container does not already contain an elements with a key equivalent to <code>k</code>, inserts the value <code>std::pair<key_type const, mapped_type>(k, mapped_type())</code></para>
+ </effects>
+ <returns>
+ <para>A reference to <code>x.second</code> where x is the element already in the container, or the newly inserted element with a key equivalent to <code>k</code></para>
+ </returns>
+ <throws>
+ <para>If an exception is thrown by an operation other than a call to <code>hasher</code> the function has no effect.</para>
+ </throws>
+ <notes>
+ <para>Can invalidate iterators, but only if the insert causes the load factor to be greater to or equal to the maximum load factor.</para>
+ <para>Pointers and references to elements are never invalidated.</para>
+ </notes>
+ </method>
+ <overloaded-method name="at">
+ <signature><type>Mapped&</type>
+ <parameter name="k"><paramtype>key_type const&</paramtype></parameter></signature>
+ <signature cv="const"><type>Mapped const&</type>
+ <parameter name="k"><paramtype>key_type const&</paramtype></parameter></signature>
+ <returns>
+ <para>A reference to <code>x.second</code> where <code>x</code> is the (unique) element whose key is equivalent to <code>k</code>.</para>
+ </returns>
+ <throws>
+ <para>An exception object of type <code>std::out_of_range</code> if no such element is present.</para>
+ </throws>
+ <notes>
+ <para>This is not specified in the draft standard, but that is probably an oversight. The issue has been raised in
+ <ulink url="http://groups.google.com/group/comp.std.c++/browse_thread/thread/ab7c22a868fd370b">comp.std.c++</ulink>.</para>
+ </notes>
+ </overloaded-method>
+ </method-group>
+ <method-group name="bucket interface">
+ <method name="bucket_count" cv="const">
+ <type>size_type</type>
+ <returns>
+ <para>The number of buckets.</para>
+ </returns>
+ </method>
+ <method name="max_bucket_count" cv="const">
+ <type>size_type</type>
+ <returns>
+ <para>An upper bound on the number of buckets.</para>
+ </returns>
+ </method>
+ <method name="bucket_size" cv="const">
+ <parameter name="n">
+ <paramtype>size_type</paramtype>
+ </parameter>
+ <type>size_type</type>
+ <requires>
+ <para><code>n < <methodname>bucket_count</methodname>()</code></para>
+ </requires>
+ <returns>
+ <para>The number of elements in bucket <code>n</code>.</para>
+ </returns>
+ </method>
+ <method name="bucket" cv="const">
+ <parameter name="k">
+ <paramtype>key_type const&</paramtype>
+ </parameter>
+ <type>size_type</type>
+ <returns>
+ <para>The index of the bucket which would contain an element with key <code>k</code>.</para>
+ </returns>
+ <postconditions>
+ <para>The return value is less than <code>bucket_count()</code></para>
+ </postconditions>
+ </method>
+ <overloaded-method name="begin">
+ <signature>
+ <parameter name="n">
+ <paramtype>size_type</paramtype>
+ </parameter>
+ <type>local_iterator</type>
+ </signature>
+ <signature cv="const">
+ <parameter name="n">
+ <paramtype>size_type</paramtype>
+ </parameter>
+ <type>const_local_iterator</type>
+ </signature>
+ <requires>
+ <para><code>n</code> shall be in the range <code>[0, bucket_count())</code>.</para>
+ </requires>
+ <returns>
+ <para>A local iterator pointing the first element in the bucket with index <code>n</code>.</para>
+ </returns>
+ </overloaded-method>
+ <overloaded-method name="end">
+ <signature>
+ <parameter name="n">
+ <paramtype>size_type</paramtype>
+ </parameter>
+ <type>local_iterator</type>
+ </signature>
+ <signature cv="const">
+ <parameter name="n">
+ <paramtype>size_type</paramtype>
+ </parameter>
+ <type>const_local_iterator</type>
+ </signature>
+ <requires>
+ <para><code>n</code> shall be in the range <code>[0, bucket_count())</code>.</para>
+ </requires>
+ <returns>
+ <para>A local iterator pointing the 'one past the end' element in the bucket with index <code>n</code>.</para>
+ </returns>
+ </overloaded-method>
+ <method name="cbegin" cv="const">
+ <parameter name="n">
+ <paramtype>size_type</paramtype>
+ </parameter>
+ <type>const_local_iterator</type>
+ <requires>
+ <para><code>n</code> shall be in the range <code>[0, bucket_count())</code>.</para>
+ </requires>
+ <returns>
+ <para>A constant local iterator pointing the first element in the bucket with index <code>n</code>.</para>
+ </returns>
+ </method>
+ <method name="cend">
+ <parameter name="n">
+ <paramtype>size_type</paramtype>
+ </parameter>
+ <type>const_local_iterator</type>
+ <requires>
+ <para><code>n</code> shall be in the range <code>[0, bucket_count())</code>.</para>
+ </requires>
+ <returns>
+ <para>A constant local iterator pointing the 'one past the end' element in the bucket with index <code>n</code>.</para>
+ </returns>
+ </method>
+ </method-group>
+ <method-group name="hash policy">
+ <method name="load_factor" cv="const">
+ <type>float</type>
+ <returns>
+ <para>The average number of elements per bucket.</para>
+ </returns>
+ </method>
+ <method name="max_load_factor" cv="const">
+ <type>float</type>
+ <returns>
+ <para>Returns the current maximum load factor.</para>
+ </returns>
+ </method>
+ <method name="max_load_factor">
+ <parameter name="z">
+ <paramtype>float</paramtype>
+ </parameter>
+ <type>void</type>
+ <effects>
+ <para>Changes the container's maximum load factor, using <code>z</code> as a hint.</para>
+ </effects>
+ </method>
+ <method name="rehash">
+ <parameter name="n">
+ <paramtype>size_type</paramtype>
+ </parameter>
+ <type>void</type>
+ <description>
+ <para>Changes the number of buckets so that there at least <code>n</code> buckets, and so that the load factor is less than the maximum load factor.</para>
+ <para>Invalidates iterators, and changes the order of elements. Pointers and references to elements are not invalidated.</para>
+ </description>
+ <throws>
+ <para>The function has no effect if an exception is thrown, unless it is thrown by the container's hash function or comparison function.</para>
+ </throws>
+ </method>
+ </method-group>
+ <free-function-group name="Equality Comparisons">
+ <function name="operator==">
+ <template>
+ <template-type-parameter name="Key">
+ </template-type-parameter>
+ <template-type-parameter name="Mapped">
+ </template-type-parameter>
+ <template-type-parameter name="Hash">
+ </template-type-parameter>
+ <template-type-parameter name="Pred">
+ </template-type-parameter>
+ <template-type-parameter name="Alloc">
+ </template-type-parameter>
+ </template>
+ <parameter name="x">
+ <paramtype>unordered_map<Key, Mapped, Hash, Pred, Alloc> const&</paramtype>
+ </parameter>
+ <parameter name="y">
+ <paramtype>unordered_map<Key, Mapped, Hash, Pred, Alloc> const&</paramtype>
+ </parameter>
+ <type>bool</type>
+ <notes>
+ <para>This is a boost extension.</para>
+ <para>Behavior is undefined if the two containers don't have
+ equivalent equality predicates.</para>
+ </notes>
+ </function>
+ <function name="operator!=">
+ <template>
+ <template-type-parameter name="Key">
+ </template-type-parameter>
+ <template-type-parameter name="Mapped">
+ </template-type-parameter>
+ <template-type-parameter name="Hash">
+ </template-type-parameter>
+ <template-type-parameter name="Pred">
+ </template-type-parameter>
+ <template-type-parameter name="Alloc">
+ </template-type-parameter>
+ </template>
+ <parameter name="x">
+ <paramtype>unordered_map<Key, Mapped, Hash, Pred, Alloc> const&</paramtype>
+ </parameter>
+ <parameter name="y">
+ <paramtype>unordered_map<Key, Mapped, Hash, Pred, Alloc> const&</paramtype>
+ </parameter>
+ <type>bool</type>
+ <notes>
+ <para>This is a boost extension.</para>
+ <para>Behavior is undefined if the two containers don't have
+ equivalent equality predicates.</para>
+ </notes>
+ </function>
+ </free-function-group>
+ <free-function-group name="swap">
+ <function name="swap">
+ <template>
+ <template-type-parameter name="Key">
+ </template-type-parameter>
+ <template-type-parameter name="Mapped">
+ </template-type-parameter>
+ <template-type-parameter name="Hash">
+ </template-type-parameter>
+ <template-type-parameter name="Pred">
+ </template-type-parameter>
+ <template-type-parameter name="Alloc">
+ </template-type-parameter>
+ </template>
+ <parameter name="x">
+ <paramtype>unordered_map<Key, Mapped, Hash, Pred, Alloc>&</paramtype>
+ </parameter>
+ <parameter name="y">
+ <paramtype>unordered_map<Key, Mapped, Hash, Pred, Alloc>&</paramtype>
+ </parameter>
+ <type>void</type>
+ <effects>
+ <para><code>x.swap(y)</code></para>
+ </effects>
+ <throws>
+ <para>If the allocators are equal, doesn't throw an exception unless it is thrown by the copy constructor or copy assignment operator of <code>Hash</code> or <code>Pred</code>.</para>
+ </throws>
+ <notes>
+ <para>For a discussion of the behavior when allocators aren't equal see
+ <link linkend="unordered.rationale.swapping_containers_with_unequal_allocators">the implementation details</link>.</para>
+ </notes>
+ </function>
+ </free-function-group>
+ </class>
+ <class name="unordered_multimap">
+ <template>
+ <template-type-parameter name="Key">
+ </template-type-parameter>
+ <template-type-parameter name="Mapped">
+ </template-type-parameter>
+ <template-type-parameter name="Hash">
+ <default><type>boost::hash<Key></type></default>
+ </template-type-parameter>
+ <template-type-parameter name="Pred">
+ <default><type>std::equal_to<Key></type></default>
+ </template-type-parameter>
+ <template-type-parameter name="Alloc">
+ <default><type>std::allocator<std::pair<Key const, Mapped> ></type></default>
+ </template-type-parameter>
+ </template>
+ <purpose><simpara>
+ An unordered associative container that associates keys with another value. The same key can be stored multiple times.
+ </simpara></purpose>
+ <description>
+ <para>Based on chapter 23 of
+ <ulink url="http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2009/n2960.pdf">the working draft of the C++ standard [n2960]</ulink>.
+ But without the updated rules for allocators.
+ </para>
+ <para><emphasis role="bold">Template Parameters</emphasis>
+ <informaltable>
+ <tgroup cols="2">
+ <tbody>
+ <row>
+ <entry><emphasis>Key</emphasis></entry>
+ <entry>Key must be Assignable and CopyConstructible.</entry></row>
+ <row>
+ <entry><emphasis>Mapped</emphasis></entry>
+ <entry>Mapped must be CopyConstructible</entry></row>
+ <row>
+ <entry><emphasis>Hash</emphasis></entry>
+ <entry>A unary function object type that acts a hash function for a <code>Key</code>. It takes a single argument of type <code>Key</code> and returns a value of type std::size_t.</entry></row>
+ <row>
+ <entry><emphasis>Pred</emphasis></entry>
+ <entry>A binary function object that implements an equivalence relation on values of type <code>Key</code>.
+ A binary function object that induces an equivalence relation on values of type Key.
+ It takes two arguments of type Key and returns a value of type bool.</entry></row>
+ <row>
+ <entry><emphasis>Alloc</emphasis></entry>
+ <entry>An allocator whose value type is the same as the container's value type.</entry></row></tbody></tgroup></informaltable></para>
+ <para>The elements are organized into buckets. Keys with the same hash code are stored in the same bucket and elements with equivalent keys are stored next to each other.</para>
+ <para>The number of buckets can be automatically increased by a call to insert, or as the result of calling rehash.</para>
+ </description>
+ <typedef name="key_type">
+ <type>Key</type>
+ </typedef>
+ <typedef name="value_type">
+ <type>std::pair<Key const, Mapped></type>
+ </typedef>
+ <typedef name="mapped_type">
+ <type>Mapped</type>
+ </typedef>
+ <typedef name="hasher">
+ <type>Hash</type>
+ </typedef>
+ <typedef name="key_equal">
+ <type>Pred</type>
+ </typedef>
+ <typedef name="allocator_type">
+ <type>Alloc</type>
+ </typedef>
+ <typedef name="pointer">
+ <type>typename allocator_type::pointer</type>
+ </typedef>
+ <typedef name="const_pointer">
+ <type>typename allocator_type::const_pointer</type>
+ </typedef>
+ <typedef name="reference">
+ <type>typename allocator_type::reference</type>
+ <purpose><simpara>lvalue of <type>value_type</type>.</simpara></purpose>
+ </typedef>
+ <typedef name="const_reference">
+ <type>typename allocator_type::const_reference</type>
+ <purpose><simpara>const lvalue of <type>value_type</type>.</simpara></purpose>
+ </typedef>
+ <typedef name="size_type">
+ <type><emphasis>implementation-defined</emphasis></type>
+ <description>
+ <para>An unsigned integral type.</para>
+ <para><type>size_type</type> can represent any non-negative value of <type>difference_type</type>.</para>
+ </description>
+ </typedef>
+ <typedef name="difference_type">
+ <type><emphasis>implementation-defined</emphasis></type>
+ <description>
+ <para>A signed integral type.</para>
+ <para>Is identical to the difference type of <type>iterator</type> and <type>const_iterator</type>.</para>
+ </description>
+ </typedef>
+ <typedef name="iterator">
+ <type><emphasis>implementation-defined</emphasis></type>
+ <description>
+ <para>A iterator whose value type is <type>value_type</type>. </para>
+ <para>The iterator category is at least a forward iterator.</para>
+ <para>Convertible to <type>const_iterator</type>.</para>
+ </description>
+ </typedef>
+ <typedef name="const_iterator">
+ <type><emphasis>implementation-defined</emphasis></type>
+ <description>
+ <para>A constant iterator whose value type is <type>value_type</type>. </para>
+ <para>The iterator category is at least a forward iterator.</para>
+ </description>
+ </typedef>
+ <typedef name="local_iterator">
+ <type><emphasis>implementation-defined</emphasis></type>
+ <description>
+ <para>An iterator with the same value type, difference type and pointer and reference type as <type>iterator</type>.</para>
+ <para>A local_iterator object can be used to iterate through a single bucket.</para>
+ </description>
+ </typedef>
+ <typedef name="const_local_iterator">
+ <type><emphasis>implementation-defined</emphasis></type>
+ <description>
+ <para>A constant iterator with the same value type, difference type and pointer and reference type as <type>const_iterator</type>.</para>
+ <para>A const_local_iterator object can be used to iterate through a single bucket.</para>
+ </description>
+ </typedef>
+ <constructor specifiers="explicit">
+ <parameter name="n">
+ <paramtype>size_type</paramtype>
+ <default><emphasis>implementation-defined</emphasis></default>
+ </parameter>
+ <parameter name="hf">
+ <paramtype>hasher const&</paramtype>
+ <default>hasher()</default>
+ </parameter>
+ <parameter name="eq">
+ <paramtype>key_equal const&</paramtype>
+ <default>key_equal()</default>
+ </parameter>
+ <parameter name="a">
+ <paramtype>allocator_type const&</paramtype>
+ <default>allocator_type()</default>
+ </parameter>
+ <postconditions>
+ <code><methodname>size</methodname>() == 0</code>
+ </postconditions>
+ <description>
+ <para>Constructs an empty container with at least n buckets, using hf as the hash function, eq as the key equality predicate, a as the allocator and a maximum load factor of 1.0.</para>
+ </description>
+ </constructor>
+ <constructor>
+ <template>
+ <template-type-parameter name="InputIterator">
+ </template-type-parameter>
+ </template>
+ <parameter name="f">
+ <paramtype>InputIterator</paramtype>
+ </parameter>
+ <parameter name="l">
+ <paramtype>InputIterator</paramtype>
+ </parameter>
+ <parameter name="n">
+ <paramtype>size_type</paramtype>
+ <default><emphasis>implementation-defined</emphasis></default>
+ </parameter>
+ <parameter name="hf">
+ <paramtype>hasher const&</paramtype>
+ <default>hasher()</default>
+ </parameter>
+ <parameter name="eq">
+ <paramtype>key_equal const&</paramtype>
+ <default>key_equal()</default>
+ </parameter>
+ <parameter name="a">
+ <paramtype>allocator_type const&</paramtype>
+ <default>allocator_type()</default>
+ </parameter>
+ <description>
+ <para>Constructs an empty container with at least n buckets, using hf as the hash function, eq as the key equality predicate, a as the allocator and a maximum load factor of 1.0 and inserts the elements from [f, l) into it.</para>
+ </description>
+ </constructor>
+ <constructor>
+ <parameter>
+ <paramtype>unordered_multimap const&</paramtype>
+ </parameter>
+ <description>
+ <para>The copy constructor. Copies the contained elements, hash function, predicate, maximum load factor and allocator.</para>
+ </description>
+ <requires>
+ <para><code>value_type</code> is copy constructible</para>
+ </requires>
+ </constructor>
+ <constructor>
+ <parameter>
+ <paramtype>unordered_multimap &&</paramtype>
+ </parameter>
+ <description>
+ <para>The move constructor.</para>
+ </description>
+ <notes>
+ <para>This is emulated on compilers without rvalue references.</para>
+ </notes>
+ <requires>
+ <para>
+ <code>value_type</code> is move constructible.
+ (TODO: This is not actually required in this implementation).
+ </para>
+ </requires>
+ </constructor>
+ <constructor specifiers="explicit">
+ <parameter name="a">
+ <paramtype>Allocator const&</paramtype>
+ </parameter>
+ <description>
+ <para>Constructs an empty container, using allocator <code>a</code>.</para>
+ </description>
+ </constructor>
+ <constructor>
+ <parameter name="x">
+ <paramtype>unordered_multimap const&</paramtype>
+ </parameter>
+ <parameter name="a">
+ <paramtype>Allocator const&</paramtype>
+ </parameter>
+ <description>
+ <para>Constructs an container, copying <code>x</code>'s contained elements, hash function, predicate, maximum load factor, but using allocator <code>a</code>.</para>
+ </description>
+ </constructor>
+ <destructor>
+ <notes>
+ <para>The destructor is applied to every element, and all memory is deallocated</para>
+ </notes>
+ </destructor>
+ <method name="operator=">
+ <parameter>
+ <paramtype>unordered_multimap const&</paramtype>
+ </parameter>
+ <type>unordered_multimap&</type>
+ <description>
+ <para>The assignment operator. Copies the contained elements, hash function, predicate and maximum load factor but not the allocator.</para>
+ </description>
+ <notes>
+ <para>
+ On compilers without rvalue references, there is a single assignment
+ operator with the signature <code>operator=(unordered_multimap)</code>
+ in order to emulate move semantics.
+ </para>
+ </notes>
+ <requires>
+ <para><code>value_type</code> is copy constructible</para>
+ </requires>
+ </method>
+ <method name="operator=">
+ <parameter>
+ <paramtype>unordered_multimap &&</paramtype>
+ </parameter>
+ <type>unordered_multimap&</type>
+ <description>
+ <para>The move assignment operator.</para>
+ </description>
+ <notes>
+ <para>
+ On compilers without rvalue references, there is a single assignment
+ operator with the signature <code>operator=(unordered_multimap)</code>
+ in order to emulate move semantics.
+ </para>
+ </notes>
+ <requires>
+ <para>
+ <code>value_type</code> is move constructible.
+ (TODO: This is not actually required in this implementation).
+ </para>
+ </requires>
+ </method>
+ <method name="get_allocator" cv="const">
+ <type>allocator_type</type>
+ </method>
+ <method-group name="size and capacity">
+ <method name="empty" cv="const">
+ <type>bool</type>
+ <returns>
+ <code><methodname>size</methodname>() == 0</code>
+ </returns>
+ </method>
+ <method name="size" cv="const">
+ <type>size_type</type>
+ <returns>
+ <code>std::distance(<methodname>begin</methodname>(), <methodname>end</methodname>())</code>
+ </returns>
+ </method>
+ <method name="max_size" cv="const">
+ <type>size_type</type>
+ <returns><code><methodname>size</methodname>()</code> of the largest possible container.
+ </returns>
+ </method>
+ </method-group>
+ <method-group name="iterators">
+ <overloaded-method name="begin">
+ <signature><type>iterator</type></signature>
+ <signature cv="const"><type>const_iterator</type></signature>
+ <returns>An iterator referring to the first element of the container, or if the container is empty the past-the-end value for the container.
+ </returns>
+ </overloaded-method>
+ <overloaded-method name="end">
+ <signature>
+ <type>iterator</type>
+ </signature>
+ <signature cv="const">
+ <type>const_iterator</type>
+ </signature>
+ <returns>An iterator which refers to the past-the-end value for the container.
+ </returns>
+ </overloaded-method>
+ <method name="cbegin" cv="const">
+ <type>const_iterator</type>
+ <returns>A constant iterator referring to the first element of the container, or if the container is empty the past-the-end value for the container.
+ </returns>
+ </method>
+ <method name="cend" cv="const">
+ <type>const_iterator</type>
+ <returns>A constant iterator which refers to the past-the-end value for the container.
+ </returns>
+ </method>
+ </method-group>
+ <method-group name="modifiers">
+ <method name="emplace">
+ <template>
+ <template-type-parameter name="Args" pack="1">
+ </template-type-parameter>
+ </template>
+ <parameter name="args" pack="1">
+ <paramtype>Args&&</paramtype>
+ </parameter>
+ <type>iterator</type>
+ <description>
+ <para>Inserts an object, constructed with the arguments <code>args</code>, in the container.</para>
+ </description>
+ <returns>
+ <para>An iterator pointing to the inserted element.</para>
+ </returns>
+ <throws>
+ <para>If an exception is thrown by an operation other than a call to <code>hasher</code> the function has no effect.</para>
+ </throws>
+ <notes>
+ <para>Can invalidate iterators, but only if the insert causes the load factor to be greater to or equal to the maximum load factor.</para>
+ <para>Pointers and references to elements are never invalidated.</para>
+ <para>If the compiler doesn't support variadic template arguments or rvalue
+ references, this is emulated for up to 10 arguments, with no support
+ for rvalue references or move semantics.</para>
+ </notes>
+ </method>
+ <method name="emplace_hint">
+ <template>
+ <template-type-parameter name="Args" pack="1">
+ </template-type-parameter>
+ </template>
+ <parameter name="hint">
+ <paramtype>const_iterator</paramtype>
+ </parameter>
+ <parameter name="args" pack="1">
+ <paramtype>Args&&</paramtype>
+ </parameter>
+ <type>iterator</type>
+ <description>
+ <para>Inserts an object, constructed with the arguments <code>args</code>, in the container.</para>
+ <para>hint is a suggestion to where the element should be inserted.</para>
+ </description>
+ <returns>
+ <para>An iterator pointing to the inserted element.</para>
+ </returns>
+ <throws>
+ <para>If an exception is thrown by an operation other than a call to <code>hasher</code> the function has no effect.</para>
+ </throws>
+ <notes>
+ <para>The standard is fairly vague on the meaning of the hint. But the only practical way to use it, and the only way that Boost.Unordered supports is to point to an existing element with the same key. </para>
+ <para>Can invalidate iterators, but only if the insert causes the load factor to be greater to or equal to the maximum load factor.</para>
+ <para>Pointers and references to elements are never invalidated.</para>
+ <para>If the compiler doesn't support variadic template arguments or rvalue
+ references, this is emulated for up to 10 arguments, with no support
+ for rvalue references or move semantics.</para>
+ </notes>
+ </method>
+ <method name="insert">
+ <parameter name="obj">
+ <paramtype>value_type const&</paramtype>
+ </parameter>
+ <type>iterator</type>
+ <description>
+ <para>Inserts obj in the container.</para>
+ </description>
+ <returns>
+ <para>An iterator pointing to the inserted element.</para>
+ </returns>
+ <throws>
+ <para>If an exception is thrown by an operation other than a call to <code>hasher</code> the function has no effect.</para>
+ </throws>
+ <notes>
+ <para>Can invalidate iterators, but only if the insert causes the load factor to be greater to or equal to the maximum load factor.</para>
+ <para>Pointers and references to elements are never invalidated.</para>
+ </notes>
+ </method>
+ <method name="insert">
+ <parameter name="hint">
+ <paramtype>const_iterator</paramtype>
+ </parameter>
+ <parameter name="obj">
+ <paramtype>value_type const&</paramtype>
+ </parameter>
+ <type>iterator</type>
+ <description>
+ <para>Inserts obj in the container.</para>
+ <para>hint is a suggestion to where the element should be inserted.</para>
+ </description>
+ <returns>
+ <para>An iterator pointing to the inserted element.</para>
+ </returns>
+ <throws>
+ <para>If an exception is thrown by an operation other than a call to <code>hasher</code> the function has no effect.</para>
+ </throws>
+ <notes>
+ <para>The standard is fairly vague on the meaning of the hint. But the only practical way to use it, and the only way that Boost.Unordered supports is to point to an existing element with the same key. </para>
+ <para>Can invalidate iterators, but only if the insert causes the load factor to be greater to or equal to the maximum load factor.</para>
+ <para>Pointers and references to elements are never invalidated.</para>
+ </notes>
+ </method>
+ <method name="insert">
+ <template>
+ <template-type-parameter name="InputIterator">
+ </template-type-parameter>
+ </template>
+ <parameter name="first">
+ <paramtype>InputIterator</paramtype>
+ </parameter>
+ <parameter name="last">
+ <paramtype>InputIterator</paramtype>
+ </parameter>
+ <type>void</type>
+ <description>
+ <para>Inserts a range of elements into the container.</para>
+ </description>
+ <throws>
+ <para>When inserting a single element, if an exception is thrown by an operation other than a call to <code>hasher</code> the function has no effect.</para>
+ </throws>
+ <notes>
+ <para>Can invalidate iterators, but only if the insert causes the load factor to be greater to or equal to the maximum load factor.</para>
+ <para>Pointers and references to elements are never invalidated.</para>
+ </notes>
+ </method>
+ <method name="erase">
+ <parameter name="position">
+ <paramtype>const_iterator</paramtype>
+ </parameter>
+ <type>iterator</type>
+ <description>
+ <para>Erase the element pointed to by <code>position</code>.</para>
+ </description>
+ <returns>
+ <para>The iterator following <code>position</code> before the erasure.</para>
+ </returns>
+ <throws>
+ <para>Only throws an exception if it is thrown by <code>hasher</code> or <code>key_equal</code>.</para>
+ <para>In this implementation, this overload doesn't call either function object's methods so it is no throw, but this might not be true in other implementations.</para>
+ </throws>
+ <notes>
+ <para>
+ When the number of elements is a lot smaller than the number of buckets
+ this function can be very inefficient as it has to search through empty
+ buckets for the next element, in order to return the iterator.
+ The method <methodname>quick_erase</methodname> is faster, but has yet
+ to be standardized.
+ </para>
+ </notes>
+ </method>
+ <method name="erase">
+ <parameter name="k">
+ <paramtype>key_type const&</paramtype>
+ </parameter>
+ <type>size_type</type>
+ <description>
+ <para>Erase all elements with key equivalent to <code>k</code>.</para>
+ </description>
+ <returns>
+ <para>The number of elements erased.</para>
+ </returns>
+ <throws>
+ <para>Only throws an exception if it is thrown by <code>hasher</code> or <code>key_equal</code>.</para>
+ </throws>
+ </method>
+ <method name="erase">
+ <parameter name="first">
+ <paramtype>const_iterator</paramtype>
+ </parameter>
+ <parameter name="last">
+ <paramtype>const_iterator</paramtype>
+ </parameter>
+ <type>iterator</type>
+ <description>
+ <para>Erases the elements in the range from <code>first</code> to <code>last</code>.</para>
+ </description>
+ <returns>
+ <para>The iterator following the erased elements - i.e. <code>last</code>.</para>
+ </returns>
+ <throws>
+ <para>Only throws an exception if it is thrown by <code>hasher</code> or <code>key_equal</code>.</para>
+ <para>In this implementation, this overload doesn't call either function object's methods so it is no throw, but this might not be true in other implementations.</para>
+ </throws>
+ </method>
+ <method name="quick_erase">
+ <parameter name="position">
+ <paramtype>const_iterator</paramtype>
+ </parameter>
+ <type>void</type>
+ <description>
+ <para>Erase the element pointed to by <code>position</code>.</para>
+ </description>
+ <throws>
+ <para>Only throws an exception if it is thrown by <code>hasher</code> or <code>key_equal</code>.</para>
+ <para>In this implementation, this overload doesn't call either function object's methods so it is no throw, but this might not be true in other implementations.</para>
+ </throws>
+ <notes>
+ <para>
+ This method is faster than <methodname>erase</methodname> as
+ it doesn't have to find the next element in the container -
+ a potentially costly operation.
+ </para>
+ <para>
+ As it hasn't been standardized, it's likely that this may
+ change in the future.
+ </para>
+ </notes>
+ </method>
+ <method name="erase_return_void">
+ <parameter name="position">
+ <paramtype>const_iterator</paramtype>
+ </parameter>
+ <type>void</type>
+ <description>
+ <para>Erase the element pointed to by <code>position</code>.</para>
+ </description>
+ <throws>
+ <para>Only throws an exception if it is thrown by <code>hasher</code> or <code>key_equal</code>.</para>
+ <para>In this implementation, this overload doesn't call either function object's methods so it is no throw, but this might not be true in other implementations.</para>
+ </throws>
+ <notes>
+ <para>
+ This method is now deprecated, use
+ <methodname>quick_return</methodname> instead. Although be
+ warned that as that isn't standardized yet, it could also
+ change.
+ </para>
+ </notes>
+ </method>
+ <method name="clear">
+ <type>void</type>
+ <description>
+ <para>Erases all elements in the container.</para>
+ </description>
+ <postconditions>
+ <para><code><methodname>size</methodname>() == 0</code></para>
+ </postconditions>
+ <throws>
+ <para>Never throws an exception.</para>
+ </throws>
+ </method>
+ <method name="swap">
+ <parameter>
+ <paramtype>unordered_multimap&</paramtype>
+ </parameter>
+ <type>void</type>
+ <throws>
+ <para>If the allocators are equal, doesn't throw an exception unless it is thrown by the copy constructor or copy assignment operator of <code>key_equal</code> or <code>hasher</code>.</para>
+ </throws>
+ <notes>
+ <para>For a discussion of the behavior when allocators aren't equal see
+ <link linkend="unordered.rationale.swapping_containers_with_unequal_allocators">the implementation details</link>.</para>
+ </notes>
+ </method>
+ </method-group>
+ <method-group name="observers">
+ <method name="hash_function" cv="const">
+ <type>hasher</type>
+ <returns>The container's hash function.
+ </returns>
+ </method>
+ <method name="key_eq" cv="const">
+ <type>key_equal</type>
+ <returns>The container's key equality predicate.
+ </returns>
+ </method>
+ </method-group>
+ <method-group name="lookup">
+ <overloaded-method name="find">
+ <signature>
+ <parameter name="k">
+ <paramtype>key_type const&</paramtype>
+ </parameter>
+ <type>iterator</type>
+ </signature>
+ <signature cv="const">
+ <parameter name="k">
+ <paramtype>key_type const&</paramtype>
+ </parameter>
+ <type>const_iterator</type>
+ </signature>
+ <signature>
+ <template>
+ <template-type-parameter name="CompatibleKey"/>
+ <template-type-parameter name="CompatibleHash"/>
+ <template-type-parameter name="CompatiblePredicate"/>
+ </template>
+ <parameter name="k">
+ <paramtype>CompatibleKey const&</paramtype>
+ </parameter>
+ <parameter name="hash">
+ <paramtype>CompatibleHash const&</paramtype>
+ </parameter>
+ <parameter name="eq">
+ <paramtype>CompatiblePredicate const&</paramtype>
+ </parameter>
+ <type>iterator</type>
+ </signature>
+ <signature cv="const">
+ <template>
+ <template-type-parameter name="CompatibleKey"/>
+ <template-type-parameter name="CompatibleHash"/>
+ <template-type-parameter name="CompatiblePredicate"/>
+ </template>
+ <parameter name="k">
+ <paramtype>CompatibleKey const&</paramtype>
+ </parameter>
+ <parameter name="hash">
+ <paramtype>CompatibleHash const&</paramtype>
+ </parameter>
+ <parameter name="eq">
+ <paramtype>CompatiblePredicate const&</paramtype>
+ </parameter>
+ <type>const_iterator</type>
+ </signature>
+ <returns>
+ <para>An iterator pointing to an element with key equivalent to <code>k</code>, or <code>b.end()</code> if no such element exists.</para>
+ </returns>
+ <notes><para>
+ The templated overloads are a non-standard extensions which
+ allows you to use a compatible hash function and equality
+ predicate for a key of a different type in order to avoid
+ an expensive type cast. In general, its use is not encouraged.
+ </para></notes>
+ </overloaded-method>
+ <method name="count" cv="const">
+ <parameter name="k">
+ <paramtype>key_type const&</paramtype>
+ </parameter>
+ <type>size_type</type>
+ <returns>
+ <para>The number of elements with key equivalent to <code>k</code>.</para>
+ </returns>
+ </method>
+ <overloaded-method name="equal_range">
+ <signature>
+ <parameter name="k">
+ <paramtype>key_type const&</paramtype>
+ </parameter>
+ <type>std::pair<iterator, iterator></type>
+ </signature>
+ <signature cv="const">
+ <parameter name="k">
+ <paramtype>key_type const&</paramtype>
+ </parameter>
+ <type>std::pair<const_iterator, const_iterator></type>
+ </signature>
+ <returns>
+ <para>A range containing all elements with key equivalent to <code>k</code>.
+ If the container doesn't container any such elements, returns
+ <code><functionname>std::make_pair</functionname>(<methodname>b.end</methodname>(),<methodname>b.end</methodname>())</code>.
+ </para>
+ </returns>
+ </overloaded-method>
+ </method-group>
+ <method-group name="bucket interface">
+ <method name="bucket_count" cv="const">
+ <type>size_type</type>
+ <returns>
+ <para>The number of buckets.</para>
+ </returns>
+ </method>
+ <method name="max_bucket_count" cv="const">
+ <type>size_type</type>
+ <returns>
+ <para>An upper bound on the number of buckets.</para>
+ </returns>
+ </method>
+ <method name="bucket_size" cv="const">
+ <parameter name="n">
+ <paramtype>size_type</paramtype>
+ </parameter>
+ <type>size_type</type>
+ <requires>
+ <para><code>n < <methodname>bucket_count</methodname>()</code></para>
+ </requires>
+ <returns>
+ <para>The number of elements in bucket <code>n</code>.</para>
+ </returns>
+ </method>
+ <method name="bucket" cv="const">
+ <parameter name="k">
+ <paramtype>key_type const&</paramtype>
+ </parameter>
+ <type>size_type</type>
+ <returns>
+ <para>The index of the bucket which would contain an element with key <code>k</code>.</para>
+ </returns>
+ <postconditions>
+ <para>The return value is less than <code>bucket_count()</code></para>
+ </postconditions>
+ </method>
+ <overloaded-method name="begin">
+ <signature>
+ <parameter name="n">
+ <paramtype>size_type</paramtype>
+ </parameter>
+ <type>local_iterator</type>
+ </signature>
+ <signature cv="const">
+ <parameter name="n">
+ <paramtype>size_type</paramtype>
+ </parameter>
+ <type>const_local_iterator</type>
+ </signature>
+ <requires>
+ <para><code>n</code> shall be in the range <code>[0, bucket_count())</code>.</para>
+ </requires>
+ <returns>
+ <para>A local iterator pointing the first element in the bucket with index <code>n</code>.</para>
+ </returns>
+ </overloaded-method>
+ <overloaded-method name="end">
+ <signature>
+ <parameter name="n">
+ <paramtype>size_type</paramtype>
+ </parameter>
+ <type>local_iterator</type>
+ </signature>
+ <signature cv="const">
+ <parameter name="n">
+ <paramtype>size_type</paramtype>
+ </parameter>
+ <type>const_local_iterator</type>
+ </signature>
+ <requires>
+ <para><code>n</code> shall be in the range <code>[0, bucket_count())</code>.</para>
+ </requires>
+ <returns>
+ <para>A local iterator pointing the 'one past the end' element in the bucket with index <code>n</code>.</para>
+ </returns>
+ </overloaded-method>
+ <method name="cbegin" cv="const">
+ <parameter name="n">
+ <paramtype>size_type</paramtype>
+ </parameter>
+ <type>const_local_iterator</type>
+ <requires>
+ <para><code>n</code> shall be in the range <code>[0, bucket_count())</code>.</para>
+ </requires>
+ <returns>
+ <para>A constant local iterator pointing the first element in the bucket with index <code>n</code>.</para>
+ </returns>
+ </method>
+ <method name="cend">
+ <parameter name="n">
+ <paramtype>size_type</paramtype>
+ </parameter>
+ <type>const_local_iterator</type>
+ <requires>
+ <para><code>n</code> shall be in the range <code>[0, bucket_count())</code>.</para>
+ </requires>
+ <returns>
+ <para>A constant local iterator pointing the 'one past the end' element in the bucket with index <code>n</code>.</para>
+ </returns>
+ </method>
+ </method-group>
+ <method-group name="hash policy">
+ <method name="load_factor" cv="const">
+ <type>float</type>
+ <returns>
+ <para>The average number of elements per bucket.</para>
+ </returns>
+ </method>
+ <method name="max_load_factor" cv="const">
+ <type>float</type>
+ <returns>
+ <para>Returns the current maximum load factor.</para>
+ </returns>
+ </method>
+ <method name="max_load_factor">
+ <parameter name="z">
+ <paramtype>float</paramtype>
+ </parameter>
+ <type>void</type>
+ <effects>
+ <para>Changes the container's maximum load factor, using <code>z</code> as a hint.</para>
+ </effects>
+ </method>
+ <method name="rehash">
+ <parameter name="n">
+ <paramtype>size_type</paramtype>
+ </parameter>
+ <type>void</type>
+ <description>
+ <para>Changes the number of buckets so that there at least <code>n</code> buckets, and so that the load factor is less than the maximum load factor.</para>
+ <para>Invalidates iterators, and changes the order of elements. Pointers and references to elements are not invalidated.</para>
+ </description>
+ <throws>
+ <para>The function has no effect if an exception is thrown, unless it is thrown by the container's hash function or comparison function.</para>
+ </throws>
+ </method>
+ </method-group>
+ <free-function-group name="Equality Comparisons">
+ <function name="operator==">
+ <template>
+ <template-type-parameter name="Key">
+ </template-type-parameter>
+ <template-type-parameter name="Mapped">
+ </template-type-parameter>
+ <template-type-parameter name="Hash">
+ </template-type-parameter>
+ <template-type-parameter name="Pred">
+ </template-type-parameter>
+ <template-type-parameter name="Alloc">
+ </template-type-parameter>
+ </template>
+ <parameter name="x">
+ <paramtype>unordered_multimap<Key, Mapped, Hash, Pred, Alloc> const&</paramtype>
+ </parameter>
+ <parameter name="y">
+ <paramtype>unordered_multimap<Key, Mapped, Hash, Pred, Alloc> const&</paramtype>
+ </parameter>
+ <type>bool</type>
+ <notes>
+ <para>This is a boost extension.</para>
+ <para>Behavior is undefined if the two containers don't have
+ equivalent equality predicates.</para>
+ </notes>
+ </function>
+ <function name="operator!=">
+ <template>
+ <template-type-parameter name="Key">
+ </template-type-parameter>
+ <template-type-parameter name="Mapped">
+ </template-type-parameter>
+ <template-type-parameter name="Hash">
+ </template-type-parameter>
+ <template-type-parameter name="Pred">
+ </template-type-parameter>
+ <template-type-parameter name="Alloc">
+ </template-type-parameter>
+ </template>
+ <parameter name="x">
+ <paramtype>unordered_multimap<Key, Mapped, Hash, Pred, Alloc> const&</paramtype>
+ </parameter>
+ <parameter name="y">
+ <paramtype>unordered_multimap<Key, Mapped, Hash, Pred, Alloc> const&</paramtype>
+ </parameter>
+ <type>bool</type>
+ <notes>
+ <para>This is a boost extension.</para>
+ <para>Behavior is undefined if the two containers don't have
+ equivalent equality predicates.</para>
+ </notes>
+ </function>
+ </free-function-group>
+ <free-function-group name="swap">
+ <function name="swap">
+ <template>
+ <template-type-parameter name="Key">
+ </template-type-parameter>
+ <template-type-parameter name="Mapped">
+ </template-type-parameter>
+ <template-type-parameter name="Hash">
+ </template-type-parameter>
+ <template-type-parameter name="Pred">
+ </template-type-parameter>
+ <template-type-parameter name="Alloc">
+ </template-type-parameter>
+ </template>
+ <parameter name="x">
+ <paramtype>unordered_multimap<Key, Mapped, Hash, Pred, Alloc>&</paramtype>
+ </parameter>
+ <parameter name="y">
+ <paramtype>unordered_multimap<Key, Mapped, Hash, Pred, Alloc>&</paramtype>
+ </parameter>
+ <type>void</type>
+ <effects>
+ <para><code>x.swap(y)</code></para>
+ </effects>
+ <throws>
+ <para>If the allocators are equal, doesn't throw an exception unless it is thrown by the copy constructor or copy assignment operator of <code>Hash</code> or <code>Pred</code>.</para>
+ </throws>
+ <notes>
+ <para>For a discussion of the behavior when allocators aren't equal see
+ <link linkend="unordered.rationale.swapping_containers_with_unequal_allocators">the implementation details</link>.</para>
+ </notes>
+ </function>
+ </free-function-group>
+ </class>
+ </namespace>
+ </header>
+ </library-reference>
Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk