Files
entt/classentt_1_1basic__hashed__string.html
2021-04-10 16:09:25 +02:00

557 lines
33 KiB
HTML

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<meta name="generator" content="Doxygen 1.8.20"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>EnTT: entt::basic_hashed_string&lt; Char &gt; Class Template Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
<tbody>
<tr style="height: 56px;">
<td id="projectalign" style="padding-left: 0.5em;">
<div id="projectname">EnTT
&#160;<span id="projectnumber">3.7.0</span>
</div>
</td>
</tr>
</tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.20 -->
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
var searchBox = new SearchBox("searchBox", "search",false,'Search');
/* @license-end */
</script>
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&amp;dn=gpl-2.0.txt GPL-v2 */
$(function() {
initMenu('',true,false,'search.php','Search');
$(document).ready(function() { init_search(); });
});
/* @license-end */</script>
<div id="main-nav"></div>
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
onmouseover="return searchBox.OnSearchSelectShow()"
onmouseout="return searchBox.OnSearchSelectHide()"
onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>
<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0"
name="MSearchResults" id="MSearchResults">
</iframe>
</div>
<div id="nav-path" class="navpath">
<ul>
<li class="navelem"><a class="el" href="namespaceentt.html">entt</a></li><li class="navelem"><a class="el" href="classentt_1_1basic__hashed__string.html">basic_hashed_string</a></li> </ul>
</div>
</div><!-- top -->
<div class="header">
<div class="summary">
<a href="#nested-classes">Classes</a> &#124;
<a href="#pub-types">Public Types</a> &#124;
<a href="#pub-methods">Public Member Functions</a> &#124;
<a href="#pub-static-methods">Static Public Member Functions</a> &#124;
<a href="classentt_1_1basic__hashed__string-members.html">List of all members</a> </div>
<div class="headertitle">
<div class="title">entt::basic_hashed_string&lt; Char &gt; Class Template Reference</div> </div>
</div><!--header-->
<div class="contents">
<p>Zero overhead unique identifier.
<a href="classentt_1_1basic__hashed__string.html#details">More...</a></p>
<p><code>#include &lt;<a class="el" href="hashed__string_8hpp_source.html">hashed_string.hpp</a>&gt;</code></p>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-types"></a>
Public Types</h2></td></tr>
<tr class="memitem:ad4e8f181e92b9218747ac43fe24c4cbc"><td class="memItemLeft" align="right" valign="top"><a id="ad4e8f181e92b9218747ac43fe24c4cbc"></a>
using&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classentt_1_1basic__hashed__string.html#ad4e8f181e92b9218747ac43fe24c4cbc">value_type</a> = Char</td></tr>
<tr class="memdesc:ad4e8f181e92b9218747ac43fe24c4cbc"><td class="mdescLeft">&#160;</td><td class="mdescRight">Character type. <br /></td></tr>
<tr class="separator:ad4e8f181e92b9218747ac43fe24c4cbc"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a1631b1f6ecd56a451366eeb228a6ffb9"><td class="memItemLeft" align="right" valign="top"><a id="a1631b1f6ecd56a451366eeb228a6ffb9"></a>
using&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classentt_1_1basic__hashed__string.html#a1631b1f6ecd56a451366eeb228a6ffb9">hash_type</a> = <a class="el" href="namespaceentt.html#a13e040e7b38a8f86d1ab2f096f37b627">id_type</a></td></tr>
<tr class="memdesc:a1631b1f6ecd56a451366eeb228a6ffb9"><td class="mdescLeft">&#160;</td><td class="mdescRight">Unsigned integer type. <br /></td></tr>
<tr class="separator:a1631b1f6ecd56a451366eeb228a6ffb9"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-methods"></a>
Public Member Functions</h2></td></tr>
<tr class="memitem:ad293de7f68f028a3e5bd8c5928cd2595"><td class="memItemLeft" align="right" valign="top"><a id="ad293de7f68f028a3e5bd8c5928cd2595"></a>
constexpr&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classentt_1_1basic__hashed__string.html#ad293de7f68f028a3e5bd8c5928cd2595">basic_hashed_string</a> () noexcept</td></tr>
<tr class="memdesc:ad293de7f68f028a3e5bd8c5928cd2595"><td class="mdescLeft">&#160;</td><td class="mdescRight">Constructs an empty hashed string. <br /></td></tr>
<tr class="separator:ad293de7f68f028a3e5bd8c5928cd2595"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a8ec8a507ee512e130842834ac57a20b1"><td class="memTemplParams" colspan="2">template&lt;std::size_t N&gt; </td></tr>
<tr class="memitem:a8ec8a507ee512e130842834ac57a20b1"><td class="memTemplItemLeft" align="right" valign="top">constexpr&#160;</td><td class="memTemplItemRight" valign="bottom"><a class="el" href="classentt_1_1basic__hashed__string.html#a8ec8a507ee512e130842834ac57a20b1">basic_hashed_string</a> (const <a class="el" href="classentt_1_1basic__hashed__string.html#ad4e8f181e92b9218747ac43fe24c4cbc">value_type</a>(&amp;curr)[N]) noexcept</td></tr>
<tr class="memdesc:a8ec8a507ee512e130842834ac57a20b1"><td class="mdescLeft">&#160;</td><td class="mdescRight">Constructs a hashed string from an array of const characters. <a href="classentt_1_1basic__hashed__string.html#a8ec8a507ee512e130842834ac57a20b1">More...</a><br /></td></tr>
<tr class="separator:a8ec8a507ee512e130842834ac57a20b1"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:af73ccc8ea097392a5ca14d1d8dfc13f0"><td class="memItemLeft" align="right" valign="top">constexpr&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classentt_1_1basic__hashed__string.html#af73ccc8ea097392a5ca14d1d8dfc13f0">basic_hashed_string</a> (const_wrapper wrapper) noexcept</td></tr>
<tr class="memdesc:af73ccc8ea097392a5ca14d1d8dfc13f0"><td class="mdescLeft">&#160;</td><td class="mdescRight">Explicit constructor on purpose to avoid constructing a hashed string directly from a <code>const value_type *</code>. <a href="classentt_1_1basic__hashed__string.html#af73ccc8ea097392a5ca14d1d8dfc13f0">More...</a><br /></td></tr>
<tr class="separator:af73ccc8ea097392a5ca14d1d8dfc13f0"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a51ae08b41d0cab42005dfda4ab6ede4a"><td class="memItemLeft" align="right" valign="top">constexpr const <a class="el" href="classentt_1_1basic__hashed__string.html#ad4e8f181e92b9218747ac43fe24c4cbc">value_type</a> *&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classentt_1_1basic__hashed__string.html#a51ae08b41d0cab42005dfda4ab6ede4a">data</a> () const noexcept</td></tr>
<tr class="memdesc:a51ae08b41d0cab42005dfda4ab6ede4a"><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns the human-readable representation of a hashed string. <a href="classentt_1_1basic__hashed__string.html#a51ae08b41d0cab42005dfda4ab6ede4a">More...</a><br /></td></tr>
<tr class="separator:a51ae08b41d0cab42005dfda4ab6ede4a"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a3dfc8c9301c62d82add17de1cb4ffc7c"><td class="memItemLeft" align="right" valign="top">constexpr <a class="el" href="classentt_1_1basic__hashed__string.html#a1631b1f6ecd56a451366eeb228a6ffb9">hash_type</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classentt_1_1basic__hashed__string.html#a3dfc8c9301c62d82add17de1cb4ffc7c">value</a> () const noexcept</td></tr>
<tr class="memdesc:a3dfc8c9301c62d82add17de1cb4ffc7c"><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns the numeric representation of a hashed string. <a href="classentt_1_1basic__hashed__string.html#a3dfc8c9301c62d82add17de1cb4ffc7c">More...</a><br /></td></tr>
<tr class="separator:a3dfc8c9301c62d82add17de1cb4ffc7c"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aea866875a9b05e5c01c9642766a5857f"><td class="memItemLeft" align="right" valign="top">constexpr&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classentt_1_1basic__hashed__string.html#aea866875a9b05e5c01c9642766a5857f">operator const value_type *</a> () const noexcept</td></tr>
<tr class="memdesc:aea866875a9b05e5c01c9642766a5857f"><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns the human-readable representation of a hashed string. <a href="classentt_1_1basic__hashed__string.html#aea866875a9b05e5c01c9642766a5857f">More...</a><br /></td></tr>
<tr class="separator:aea866875a9b05e5c01c9642766a5857f"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:af0018b378b254991675acc20ba2c600d"><td class="memItemLeft" align="right" valign="top">constexpr&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classentt_1_1basic__hashed__string.html#af0018b378b254991675acc20ba2c600d">operator hash_type</a> () const noexcept</td></tr>
<tr class="memdesc:af0018b378b254991675acc20ba2c600d"><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns the numeric representation of a hashed string. <a href="classentt_1_1basic__hashed__string.html#af0018b378b254991675acc20ba2c600d">More...</a><br /></td></tr>
<tr class="separator:af0018b378b254991675acc20ba2c600d"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a168ddcf724ba17c60b38093ea520aa20"><td class="memItemLeft" align="right" valign="top">constexpr bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classentt_1_1basic__hashed__string.html#a168ddcf724ba17c60b38093ea520aa20">operator==</a> (const <a class="el" href="classentt_1_1basic__hashed__string.html">basic_hashed_string</a> &amp;other) const noexcept</td></tr>
<tr class="memdesc:a168ddcf724ba17c60b38093ea520aa20"><td class="mdescLeft">&#160;</td><td class="mdescRight">Compares two hashed strings. <a href="classentt_1_1basic__hashed__string.html#a168ddcf724ba17c60b38093ea520aa20">More...</a><br /></td></tr>
<tr class="separator:a168ddcf724ba17c60b38093ea520aa20"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="pub-static-methods"></a>
Static Public Member Functions</h2></td></tr>
<tr class="memitem:ae7393fb721ff48b0060e10bd7ea9b935"><td class="memItemLeft" align="right" valign="top">static constexpr <a class="el" href="classentt_1_1basic__hashed__string.html#a1631b1f6ecd56a451366eeb228a6ffb9">hash_type</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classentt_1_1basic__hashed__string.html#ae7393fb721ff48b0060e10bd7ea9b935">value</a> (const <a class="el" href="classentt_1_1basic__hashed__string.html#ad4e8f181e92b9218747ac43fe24c4cbc">value_type</a> *str, std::size_t size) noexcept</td></tr>
<tr class="memdesc:ae7393fb721ff48b0060e10bd7ea9b935"><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns directly the numeric representation of a string view. <a href="classentt_1_1basic__hashed__string.html#ae7393fb721ff48b0060e10bd7ea9b935">More...</a><br /></td></tr>
<tr class="separator:ae7393fb721ff48b0060e10bd7ea9b935"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a4e3866531b504f05e804273188f1c0c0"><td class="memTemplParams" colspan="2">template&lt;std::size_t N&gt; </td></tr>
<tr class="memitem:a4e3866531b504f05e804273188f1c0c0"><td class="memTemplItemLeft" align="right" valign="top">static constexpr <a class="el" href="classentt_1_1basic__hashed__string.html#a1631b1f6ecd56a451366eeb228a6ffb9">hash_type</a>&#160;</td><td class="memTemplItemRight" valign="bottom"><a class="el" href="classentt_1_1basic__hashed__string.html#a4e3866531b504f05e804273188f1c0c0">value</a> (const <a class="el" href="classentt_1_1basic__hashed__string.html#ad4e8f181e92b9218747ac43fe24c4cbc">value_type</a>(&amp;str)[N]) noexcept</td></tr>
<tr class="memdesc:a4e3866531b504f05e804273188f1c0c0"><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns directly the numeric representation of a string. <a href="classentt_1_1basic__hashed__string.html#a4e3866531b504f05e804273188f1c0c0">More...</a><br /></td></tr>
<tr class="separator:a4e3866531b504f05e804273188f1c0c0"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a67cd9ffab58a312064e59dbaa09f7efa"><td class="memItemLeft" align="right" valign="top">static <a class="el" href="classentt_1_1basic__hashed__string.html#a1631b1f6ecd56a451366eeb228a6ffb9">hash_type</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classentt_1_1basic__hashed__string.html#a67cd9ffab58a312064e59dbaa09f7efa">value</a> (const_wrapper wrapper) noexcept</td></tr>
<tr class="memdesc:a67cd9ffab58a312064e59dbaa09f7efa"><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns directly the numeric representation of a string. <a href="classentt_1_1basic__hashed__string.html#a67cd9ffab58a312064e59dbaa09f7efa">More...</a><br /></td></tr>
<tr class="separator:a67cd9ffab58a312064e59dbaa09f7efa"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<div class="textblock"><h3>template&lt;typename Char&gt;<br />
class entt::basic_hashed_string&lt; Char &gt;</h3>
<p>Zero overhead unique identifier. </p>
<p>A hashed string is a compile-time tool that allows users to use human-readable identifers in the codebase while using their numeric counterparts at runtime.<br />
Because of that, a hashed string can also be used in constant expressions if required.</p>
<dl class="tparams"><dt>Template Parameters</dt><dd>
<table class="tparams">
<tr><td class="paramname">Char</td><td>Character type. </td></tr>
</table>
</dd>
</dl>
<p class="definition">Definition at line <a class="el" href="hashed__string_8hpp_source.html#l00064">64</a> of file <a class="el" href="hashed__string_8hpp_source.html">hashed_string.hpp</a>.</p>
</div><h2 class="groupheader">Constructor &amp; Destructor Documentation</h2>
<a id="a8ec8a507ee512e130842834ac57a20b1"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a8ec8a507ee512e130842834ac57a20b1">&#9670;&nbsp;</a></span>basic_hashed_string() <span class="overload">[1/2]</span></h2>
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename Char &gt; </div>
<div class="memtemplate">
template&lt;std::size_t N&gt; </div>
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">constexpr <a class="el" href="classentt_1_1basic__hashed__string.html">entt::basic_hashed_string</a>&lt; Char &gt;::<a class="el" href="classentt_1_1basic__hashed__string.html">basic_hashed_string</a> </td>
<td>(</td>
<td class="paramtype">const <a class="el" href="classentt_1_1basic__hashed__string.html#ad4e8f181e92b9218747ac43fe24c4cbc">value_type</a>(&amp;)&#160;</td>
<td class="paramname"><em>curr</em>[N]</td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">constexpr</span><span class="mlabel">noexcept</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Constructs a hashed string from an array of const characters. </p>
<p>Forcing template resolution avoids implicit conversions. An human-readable identifier can be anything but a plain, old bunch of characters.<br />
Example of use: </p><div class="fragment"><div class="line">basic_hashed_string&lt;char&gt; hs{<span class="stringliteral">&quot;my.png&quot;</span>};</div>
</div><!-- fragment --><dl class="tparams"><dt>Template Parameters</dt><dd>
<table class="tparams">
<tr><td class="paramname">N</td><td>Number of characters of the identifier. </td></tr>
</table>
</dd>
</dl>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">curr</td><td>Human-readable identifer. </td></tr>
</table>
</dd>
</dl>
<p class="definition">Definition at line <a class="el" href="hashed__string_8hpp_source.html#l00151">151</a> of file <a class="el" href="hashed__string_8hpp_source.html">hashed_string.hpp</a>.</p>
</div>
</div>
<a id="af73ccc8ea097392a5ca14d1d8dfc13f0"></a>
<h2 class="memtitle"><span class="permalink"><a href="#af73ccc8ea097392a5ca14d1d8dfc13f0">&#9670;&nbsp;</a></span>basic_hashed_string() <span class="overload">[2/2]</span></h2>
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename Char &gt; </div>
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">constexpr <a class="el" href="classentt_1_1basic__hashed__string.html">entt::basic_hashed_string</a>&lt; Char &gt;::<a class="el" href="classentt_1_1basic__hashed__string.html">basic_hashed_string</a> </td>
<td>(</td>
<td class="paramtype">const_wrapper&#160;</td>
<td class="paramname"><em>wrapper</em></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">explicit</span><span class="mlabel">constexpr</span><span class="mlabel">noexcept</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Explicit constructor on purpose to avoid constructing a hashed string directly from a <code>const value_type *</code>. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">wrapper</td><td>Helps achieving the purpose by relying on overloading. </td></tr>
</table>
</dd>
</dl>
<p class="definition">Definition at line <a class="el" href="hashed__string_8hpp_source.html#l00160">160</a> of file <a class="el" href="hashed__string_8hpp_source.html">hashed_string.hpp</a>.</p>
</div>
</div>
<h2 class="groupheader">Member Function Documentation</h2>
<a id="a51ae08b41d0cab42005dfda4ab6ede4a"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a51ae08b41d0cab42005dfda4ab6ede4a">&#9670;&nbsp;</a></span>data()</h2>
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename Char &gt; </div>
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">constexpr const <a class="el" href="classentt_1_1basic__hashed__string.html#ad4e8f181e92b9218747ac43fe24c4cbc">value_type</a>* <a class="el" href="classentt_1_1basic__hashed__string.html">entt::basic_hashed_string</a>&lt; Char &gt;::data </td>
<td>(</td>
<td class="paramname"></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">constexpr</span><span class="mlabel">noexcept</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Returns the human-readable representation of a hashed string. </p>
<dl class="section return"><dt>Returns</dt><dd>The string used to initialize the instance. </dd></dl>
<p class="definition">Definition at line <a class="el" href="hashed__string_8hpp_source.html#l00168">168</a> of file <a class="el" href="hashed__string_8hpp_source.html">hashed_string.hpp</a>.</p>
</div>
</div>
<a id="aea866875a9b05e5c01c9642766a5857f"></a>
<h2 class="memtitle"><span class="permalink"><a href="#aea866875a9b05e5c01c9642766a5857f">&#9670;&nbsp;</a></span>operator const value_type *()</h2>
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename Char &gt; </div>
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">constexpr <a class="el" href="classentt_1_1basic__hashed__string.html">entt::basic_hashed_string</a>&lt; Char &gt;::operator const <a class="el" href="classentt_1_1basic__hashed__string.html#ad4e8f181e92b9218747ac43fe24c4cbc">value_type</a> * </td>
<td>(</td>
<td class="paramname"></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">constexpr</span><span class="mlabel">noexcept</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Returns the human-readable representation of a hashed string. </p>
<dl class="section return"><dt>Returns</dt><dd>The string used to initialize the instance. </dd></dl>
<p class="definition">Definition at line <a class="el" href="hashed__string_8hpp_source.html#l00181">181</a> of file <a class="el" href="hashed__string_8hpp_source.html">hashed_string.hpp</a>.</p>
</div>
</div>
<a id="af0018b378b254991675acc20ba2c600d"></a>
<h2 class="memtitle"><span class="permalink"><a href="#af0018b378b254991675acc20ba2c600d">&#9670;&nbsp;</a></span>operator hash_type()</h2>
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename Char &gt; </div>
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">constexpr <a class="el" href="classentt_1_1basic__hashed__string.html">entt::basic_hashed_string</a>&lt; Char &gt;::operator <a class="el" href="classentt_1_1basic__hashed__string.html#a1631b1f6ecd56a451366eeb228a6ffb9">hash_type</a> </td>
<td>(</td>
<td class="paramname"></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">constexpr</span><span class="mlabel">noexcept</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Returns the numeric representation of a hashed string. </p>
<dl class="section return"><dt>Returns</dt><dd>The numeric representation of the instance. </dd></dl>
<p class="definition">Definition at line <a class="el" href="hashed__string_8hpp_source.html#l00187">187</a> of file <a class="el" href="hashed__string_8hpp_source.html">hashed_string.hpp</a>.</p>
</div>
</div>
<a id="a168ddcf724ba17c60b38093ea520aa20"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a168ddcf724ba17c60b38093ea520aa20">&#9670;&nbsp;</a></span>operator==()</h2>
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename Char &gt; </div>
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">constexpr bool <a class="el" href="classentt_1_1basic__hashed__string.html">entt::basic_hashed_string</a>&lt; Char &gt;::operator== </td>
<td>(</td>
<td class="paramtype">const <a class="el" href="classentt_1_1basic__hashed__string.html">basic_hashed_string</a>&lt; Char &gt; &amp;&#160;</td>
<td class="paramname"><em>other</em></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">constexpr</span><span class="mlabel">noexcept</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Compares two hashed strings. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">other</td><td>Hashed string with which to compare. </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>True if the two hashed strings are identical, false otherwise. </dd></dl>
<p class="definition">Definition at line <a class="el" href="hashed__string_8hpp_source.html#l00194">194</a> of file <a class="el" href="hashed__string_8hpp_source.html">hashed_string.hpp</a>.</p>
</div>
</div>
<a id="a3dfc8c9301c62d82add17de1cb4ffc7c"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a3dfc8c9301c62d82add17de1cb4ffc7c">&#9670;&nbsp;</a></span>value() <span class="overload">[1/4]</span></h2>
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename Char &gt; </div>
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">constexpr <a class="el" href="classentt_1_1basic__hashed__string.html#a1631b1f6ecd56a451366eeb228a6ffb9">hash_type</a> <a class="el" href="classentt_1_1basic__hashed__string.html">entt::basic_hashed_string</a>&lt; Char &gt;::value </td>
<td>(</td>
<td class="paramname"></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">constexpr</span><span class="mlabel">noexcept</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Returns the numeric representation of a hashed string. </p>
<dl class="section return"><dt>Returns</dt><dd>The numeric representation of the instance. </dd></dl>
<p class="definition">Definition at line <a class="el" href="hashed__string_8hpp_source.html#l00176">176</a> of file <a class="el" href="hashed__string_8hpp_source.html">hashed_string.hpp</a>.</p>
</div>
</div>
<a id="ae7393fb721ff48b0060e10bd7ea9b935"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ae7393fb721ff48b0060e10bd7ea9b935">&#9670;&nbsp;</a></span>value() <span class="overload">[2/4]</span></h2>
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename Char &gt; </div>
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">static constexpr <a class="el" href="classentt_1_1basic__hashed__string.html#a1631b1f6ecd56a451366eeb228a6ffb9">hash_type</a> <a class="el" href="classentt_1_1basic__hashed__string.html">entt::basic_hashed_string</a>&lt; Char &gt;::value </td>
<td>(</td>
<td class="paramtype">const <a class="el" href="classentt_1_1basic__hashed__string.html#ad4e8f181e92b9218747ac43fe24c4cbc">value_type</a> *&#160;</td>
<td class="paramname"><em>str</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">std::size_t&#160;</td>
<td class="paramname"><em>size</em>&#160;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">static</span><span class="mlabel">constexpr</span><span class="mlabel">noexcept</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Returns directly the numeric representation of a string view. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">str</td><td>Human-readable identifer. </td></tr>
<tr><td class="paramname">size</td><td>Length of the string to hash. </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>The numeric representation of the string. </dd></dl>
<p class="definition">Definition at line <a class="el" href="hashed__string_8hpp_source.html#l00096">96</a> of file <a class="el" href="hashed__string_8hpp_source.html">hashed_string.hpp</a>.</p>
</div>
</div>
<a id="a4e3866531b504f05e804273188f1c0c0"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a4e3866531b504f05e804273188f1c0c0">&#9670;&nbsp;</a></span>value() <span class="overload">[3/4]</span></h2>
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename Char &gt; </div>
<div class="memtemplate">
template&lt;std::size_t N&gt; </div>
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">static constexpr <a class="el" href="classentt_1_1basic__hashed__string.html#a1631b1f6ecd56a451366eeb228a6ffb9">hash_type</a> <a class="el" href="classentt_1_1basic__hashed__string.html">entt::basic_hashed_string</a>&lt; Char &gt;::value </td>
<td>(</td>
<td class="paramtype">const <a class="el" href="classentt_1_1basic__hashed__string.html#ad4e8f181e92b9218747ac43fe24c4cbc">value_type</a>(&amp;)&#160;</td>
<td class="paramname"><em>str</em>[N]</td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">static</span><span class="mlabel">constexpr</span><span class="mlabel">noexcept</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Returns directly the numeric representation of a string. </p>
<p>Forcing template resolution avoids implicit conversions. An human-readable identifier can be anything but a plain, old bunch of characters.<br />
Example of use: </p><div class="fragment"><div class="line"><span class="keyword">const</span> <span class="keyword">auto</span> <a class="code" href="classentt_1_1basic__hashed__string.html#a3dfc8c9301c62d82add17de1cb4ffc7c">value</a> = basic_hashed_string&lt;char&gt;::to_value(<span class="stringliteral">&quot;my.png&quot;</span>);</div>
</div><!-- fragment --><dl class="tparams"><dt>Template Parameters</dt><dd>
<table class="tparams">
<tr><td class="paramname">N</td><td>Number of characters of the identifier. </td></tr>
</table>
</dd>
</dl>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">str</td><td>Human-readable identifer. </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>The numeric representation of the string. </dd></dl>
<p class="definition">Definition at line <a class="el" href="hashed__string_8hpp_source.html#l00118">118</a> of file <a class="el" href="hashed__string_8hpp_source.html">hashed_string.hpp</a>.</p>
</div>
</div>
<a id="a67cd9ffab58a312064e59dbaa09f7efa"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a67cd9ffab58a312064e59dbaa09f7efa">&#9670;&nbsp;</a></span>value() <span class="overload">[4/4]</span></h2>
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename Char &gt; </div>
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">static <a class="el" href="classentt_1_1basic__hashed__string.html#a1631b1f6ecd56a451366eeb228a6ffb9">hash_type</a> <a class="el" href="classentt_1_1basic__hashed__string.html">entt::basic_hashed_string</a>&lt; Char &gt;::value </td>
<td>(</td>
<td class="paramtype">const_wrapper&#160;</td>
<td class="paramname"><em>wrapper</em></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span><span class="mlabel">static</span><span class="mlabel">noexcept</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Returns directly the numeric representation of a string. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">wrapper</td><td>Helps achieving the purpose by relying on overloading. </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>The numeric representation of the string. </dd></dl>
<p class="definition">Definition at line <a class="el" href="hashed__string_8hpp_source.html#l00127">127</a> of file <a class="el" href="hashed__string_8hpp_source.html">hashed_string.hpp</a>.</p>
</div>
</div>
<hr/>The documentation for this class was generated from the following file:<ul>
<li>src/entt/core/<a class="el" href="hashed__string_8hpp_source.html">hashed_string.hpp</a></li>
</ul>
</div><!-- contents -->
<div class="ttc" id="aclassentt_1_1basic__hashed__string_html_a3dfc8c9301c62d82add17de1cb4ffc7c"><div class="ttname"><a href="classentt_1_1basic__hashed__string.html#a3dfc8c9301c62d82add17de1cb4ffc7c">entt::basic_hashed_string::value</a></div><div class="ttdeci">constexpr hash_type value() const noexcept</div><div class="ttdoc">Returns the numeric representation of a hashed string.</div><div class="ttdef"><b>Definition:</b> <a href="hashed__string_8hpp_source.html#l00176">hashed_string.hpp:176</a></div></div>
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
Generated by&#160;<a href="http://www.doxygen.org/index.html"><img class="footer" src="doxygen.svg" width="104" height="31" alt="doxygen"/></a> 1.8.20
</small></address>
</body>
</html>