diff options
author | DongHun Kwak <dh0128.kwak@samsung.com> | 2017-09-13 11:24:46 +0900 |
---|---|---|
committer | DongHun Kwak <dh0128.kwak@samsung.com> | 2017-09-13 11:25:39 +0900 |
commit | 4fadd968fa12130524c8380f33fcfe25d4de79e5 (patch) | |
tree | fd26a490cd15388d42fc6652b3c5c13012e7f93e /doc/html/hash/combine.html | |
parent | b5c87084afaef42b2d058f68091be31988a6a874 (diff) | |
download | boost-4fadd968fa12130524c8380f33fcfe25d4de79e5.tar.gz boost-4fadd968fa12130524c8380f33fcfe25d4de79e5.tar.bz2 boost-4fadd968fa12130524c8380f33fcfe25d4de79e5.zip |
Imported Upstream version 1.65.0upstream/1.65.0
Change-Id: Icf8400b375482cb11bcf77440a6934ba360d6ba4
Signed-off-by: DongHun Kwak <dh0128.kwak@samsung.com>
Diffstat (limited to 'doc/html/hash/combine.html')
-rw-r--r-- | doc/html/hash/combine.html | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/doc/html/hash/combine.html b/doc/html/hash/combine.html index 8c2325b7df..11cd6cbfa2 100644 --- a/doc/html/hash/combine.html +++ b/doc/html/hash/combine.html @@ -6,7 +6,7 @@ <link rel="stylesheet" href="../../../doc/src/boostbook.css" type="text/css"> <meta name="generator" content="DocBook XSL Stylesheets V1.79.1"> <link rel="home" href="../index.html" title="The Boost C++ Libraries BoostBook Documentation Subset"> -<link rel="up" href="../hash.html" title="Chapter 16. Boost.Functional/Hash"> +<link rel="up" href="../hash.html" title="Chapter 15. Boost.Functional/Hash"> <link rel="prev" href="custom.html" title="Extending boost::hash for a custom data type"> <link rel="next" href="portability.html" title="Portability"> </head> @@ -70,7 +70,7 @@ <p> Calls to hash_combine incrementally build the hash from the different members of point, it can be repeatedly called for any number of elements. It calls - <code class="computeroutput"><a class="link" href="reference.html#boost.hash_value_idp509058208">hash_value</a></code> on the supplied + <code class="computeroutput"><a class="link" href="reference.html#boost.hash_value_idp528258032">hash_value</a></code> on the supplied element, and combines it with the seed. </p> <p> @@ -106,17 +106,17 @@ If you are calculating a hash value for data </td></tr> </table></div> <p> - To calculate the hash of an iterator range you can use <code class="computeroutput"><a class="link" href="reference.html#boost.hash_range_idp509038256">boost::hash_range</a></code>: + To calculate the hash of an iterator range you can use <code class="computeroutput"><a class="link" href="reference.html#boost.hash_range_idp528238080">boost::hash_range</a></code>: </p> <pre class="programlisting"><span class="identifier">std</span><span class="special">::</span><span class="identifier">vector</span><span class="special"><</span><span class="identifier">std</span><span class="special">::</span><span class="identifier">string</span><span class="special">></span> <span class="identifier">some_strings</span><span class="special">;</span> -<span class="identifier">std</span><span class="special">::</span><span class="identifier">size_t</span> <span class="identifier">hash</span> <span class="special">=</span> <code class="computeroutput"><a class="link" href="reference.html#boost.hash_range_idp509038256">boost::hash_range</a></code><span class="special">(</span><span class="identifier">some_strings</span><span class="special">.</span><span class="identifier">begin</span><span class="special">(),</span> <span class="identifier">some_strings</span><span class="special">.</span><span class="identifier">end</span><span class="special">());</span> +<span class="identifier">std</span><span class="special">::</span><span class="identifier">size_t</span> <span class="identifier">hash</span> <span class="special">=</span> <code class="computeroutput"><a class="link" href="reference.html#boost.hash_range_idp528238080">boost::hash_range</a></code><span class="special">(</span><span class="identifier">some_strings</span><span class="special">.</span><span class="identifier">begin</span><span class="special">(),</span> <span class="identifier">some_strings</span><span class="special">.</span><span class="identifier">end</span><span class="special">());</span> </pre> <p> Note that when writing template classes, you might not want to include the main hash header as it's quite an expensive include that brings in a lot of other headers, so instead you can include the <code class="computeroutput"><span class="special"><</span><span class="identifier">boost</span><span class="special">/</span><span class="identifier">functional</span><span class="special">/</span><span class="identifier">hash_fwd</span><span class="special">.</span><span class="identifier">hpp</span><span class="special">></span></code> header which forward declares <code class="computeroutput"><a class="link" href="../boost/hash.html" title="Struct template hash">boost::hash</a></code>, - <code class="computeroutput"><a class="link" href="reference.html#boost.hash_range_idp509038256">boost::hash_range</a></code> and + <code class="computeroutput"><a class="link" href="reference.html#boost.hash_range_idp528238080">boost::hash_range</a></code> and <code class="computeroutput"><a class="link" href="reference.html#boost.hash_combine">boost::hash_combine</a></code>. You'll need to include the main header before instantiating <code class="computeroutput"><a class="link" href="../boost/hash.html" title="Struct template hash">boost::hash</a></code>. When using a container that uses <code class="computeroutput"><a class="link" href="../boost/hash.html" title="Struct template hash">boost::hash</a></code> |