Files
entt/classentt_1_1Prototype.html
2018-07-10 16:36:42 +02:00

1090 lines
63 KiB
HTML

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://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.13"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>entt: entt::Prototype&lt; Entity &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">2.6.1</span>
</div>
</td>
</tr>
</tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.13 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "search",false,'Search');
</script>
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
$(function() {
initMenu('',true,false,'search.php','Search');
$(document).ready(function() { init_search(); });
});
</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_1Prototype.html">Prototype</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="classentt_1_1Prototype-members.html">List of all members</a> </div>
<div class="headertitle">
<div class="title">entt::Prototype&lt; Entity &gt; Class Template Reference<span class="mlabels"><span class="mlabel">final</span></span></div> </div>
</div><!--header-->
<div class="contents">
<p><a class="el" href="classentt_1_1Prototype.html" title="Prototype container for concepts. ">Prototype</a> container for <em>concepts</em>.
<a href="classentt_1_1Prototype.html#details">More...</a></p>
<p><code>#include &lt;<a class="el" href="prototype_8hpp_source.html">prototype.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:a8e4a91009c1cbb0bfaadf4e95178eaec"><td class="memItemLeft" align="right" valign="top"><a id="a8e4a91009c1cbb0bfaadf4e95178eaec"></a>
using&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classentt_1_1Prototype.html#a8e4a91009c1cbb0bfaadf4e95178eaec">registry_type</a> = <a class="el" href="classentt_1_1Registry.html">Registry</a>&lt; Entity &gt;</td></tr>
<tr class="memdesc:a8e4a91009c1cbb0bfaadf4e95178eaec"><td class="mdescLeft">&#160;</td><td class="mdescRight"><a class="el" href="classentt_1_1Registry.html" title="Fast and reliable entity-component system. ">Registry</a> type. <br /></td></tr>
<tr class="separator:a8e4a91009c1cbb0bfaadf4e95178eaec"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ab4542df6834170b6f0d96828d094269d"><td class="memItemLeft" align="right" valign="top"><a id="ab4542df6834170b6f0d96828d094269d"></a>
using&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classentt_1_1Prototype.html#ab4542df6834170b6f0d96828d094269d">entity_type</a> = Entity</td></tr>
<tr class="memdesc:ab4542df6834170b6f0d96828d094269d"><td class="mdescLeft">&#160;</td><td class="mdescRight">Underlying entity identifier. <br /></td></tr>
<tr class="separator:ab4542df6834170b6f0d96828d094269d"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a2a593566474356ad2a03fea9b122de93"><td class="memItemLeft" align="right" valign="top"><a id="a2a593566474356ad2a03fea9b122de93"></a>
using&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classentt_1_1Prototype.html#a2a593566474356ad2a03fea9b122de93">size_type</a> = std::size_t</td></tr>
<tr class="memdesc:a2a593566474356ad2a03fea9b122de93"><td class="mdescLeft">&#160;</td><td class="mdescRight">Unsigned integer type. <br /></td></tr>
<tr class="separator:a2a593566474356ad2a03fea9b122de93"><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:aa6033be234aad4d287d740c40db17fec"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classentt_1_1Prototype.html#aa6033be234aad4d287d740c40db17fec">Prototype</a> (<a class="el" href="classentt_1_1Registry.html">Registry</a>&lt; Entity &gt; &amp;registry)</td></tr>
<tr class="memdesc:aa6033be234aad4d287d740c40db17fec"><td class="mdescLeft">&#160;</td><td class="mdescRight">Constructs a prototype that is bound to a given registry. <a href="#aa6033be234aad4d287d740c40db17fec">More...</a><br /></td></tr>
<tr class="separator:aa6033be234aad4d287d740c40db17fec"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:acb70104c3d32fcf22fbe37afa7602ed5"><td class="memItemLeft" align="right" valign="top"><a id="acb70104c3d32fcf22fbe37afa7602ed5"></a>
&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classentt_1_1Prototype.html#acb70104c3d32fcf22fbe37afa7602ed5">~Prototype</a> ()</td></tr>
<tr class="memdesc:acb70104c3d32fcf22fbe37afa7602ed5"><td class="mdescLeft">&#160;</td><td class="mdescRight">Releases all its resources. <br /></td></tr>
<tr class="separator:acb70104c3d32fcf22fbe37afa7602ed5"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a6f3d7431f85160da0e255b279c4b5291"><td class="memItemLeft" align="right" valign="top"><a id="a6f3d7431f85160da0e255b279c4b5291"></a>
&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classentt_1_1Prototype.html#a6f3d7431f85160da0e255b279c4b5291">Prototype</a> (const <a class="el" href="classentt_1_1Prototype.html">Prototype</a> &amp;)=delete</td></tr>
<tr class="memdesc:a6f3d7431f85160da0e255b279c4b5291"><td class="mdescLeft">&#160;</td><td class="mdescRight">Copying a prototype isn't allowed. <br /></td></tr>
<tr class="separator:a6f3d7431f85160da0e255b279c4b5291"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ad4900c4a27f506b5d2b9db54aba9d224"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classentt_1_1Prototype.html#ad4900c4a27f506b5d2b9db54aba9d224">Prototype</a> (<a class="el" href="classentt_1_1Prototype.html">Prototype</a> &amp;&amp;other)</td></tr>
<tr class="memdesc:ad4900c4a27f506b5d2b9db54aba9d224"><td class="mdescLeft">&#160;</td><td class="mdescRight">Move constructor. <a href="#ad4900c4a27f506b5d2b9db54aba9d224">More...</a><br /></td></tr>
<tr class="separator:ad4900c4a27f506b5d2b9db54aba9d224"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a65529171240b1b7c348445c7ba4f319e"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classentt_1_1Prototype.html">Prototype</a> &amp;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classentt_1_1Prototype.html#a65529171240b1b7c348445c7ba4f319e">operator=</a> (const <a class="el" href="classentt_1_1Prototype.html">Prototype</a> &amp;)=delete</td></tr>
<tr class="memdesc:a65529171240b1b7c348445c7ba4f319e"><td class="mdescLeft">&#160;</td><td class="mdescRight">Copying a prototype isn't allowed. <a href="#a65529171240b1b7c348445c7ba4f319e">More...</a><br /></td></tr>
<tr class="separator:a65529171240b1b7c348445c7ba4f319e"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a9faf0b8878925090431a9e6acaed06c5"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classentt_1_1Prototype.html">Prototype</a> &amp;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classentt_1_1Prototype.html#a9faf0b8878925090431a9e6acaed06c5">operator=</a> (<a class="el" href="classentt_1_1Prototype.html">Prototype</a> &amp;&amp;other)</td></tr>
<tr class="memdesc:a9faf0b8878925090431a9e6acaed06c5"><td class="mdescLeft">&#160;</td><td class="mdescRight">Move assignment operator. <a href="#a9faf0b8878925090431a9e6acaed06c5">More...</a><br /></td></tr>
<tr class="separator:a9faf0b8878925090431a9e6acaed06c5"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:abf665ce59c8f43c4eff3ce77a21c5cfb"><td class="memTemplParams" colspan="2">template&lt;typename Component , typename... Args&gt; </td></tr>
<tr class="memitem:abf665ce59c8f43c4eff3ce77a21c5cfb"><td class="memTemplItemLeft" align="right" valign="top">Component &amp;&#160;</td><td class="memTemplItemRight" valign="bottom"><a class="el" href="classentt_1_1Prototype.html#abf665ce59c8f43c4eff3ce77a21c5cfb">set</a> (Args &amp;&amp;... args)</td></tr>
<tr class="memdesc:abf665ce59c8f43c4eff3ce77a21c5cfb"><td class="mdescLeft">&#160;</td><td class="mdescRight">Assigns to or replaces the given component of a prototype. <a href="#abf665ce59c8f43c4eff3ce77a21c5cfb">More...</a><br /></td></tr>
<tr class="separator:abf665ce59c8f43c4eff3ce77a21c5cfb"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ac75f485a3afa9dada4574269be50166d"><td class="memTemplParams" colspan="2">template&lt;typename Component &gt; </td></tr>
<tr class="memitem:ac75f485a3afa9dada4574269be50166d"><td class="memTemplItemLeft" align="right" valign="top">void&#160;</td><td class="memTemplItemRight" valign="bottom"><a class="el" href="classentt_1_1Prototype.html#ac75f485a3afa9dada4574269be50166d">unset</a> () ENTT_NOEXCEPT</td></tr>
<tr class="memdesc:ac75f485a3afa9dada4574269be50166d"><td class="mdescLeft">&#160;</td><td class="mdescRight">Removes the given component from a prototype. <a href="#ac75f485a3afa9dada4574269be50166d">More...</a><br /></td></tr>
<tr class="separator:ac75f485a3afa9dada4574269be50166d"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a3f156472cc6a07016eadf51082b8f2f8"><td class="memTemplParams" colspan="2">template&lt;typename... Component&gt; </td></tr>
<tr class="memitem:a3f156472cc6a07016eadf51082b8f2f8"><td class="memTemplItemLeft" align="right" valign="top">bool&#160;</td><td class="memTemplItemRight" valign="bottom"><a class="el" href="classentt_1_1Prototype.html#a3f156472cc6a07016eadf51082b8f2f8">has</a> () const ENTT_NOEXCEPT</td></tr>
<tr class="memdesc:a3f156472cc6a07016eadf51082b8f2f8"><td class="mdescLeft">&#160;</td><td class="mdescRight">Checks if a prototype owns all the given components. <a href="#a3f156472cc6a07016eadf51082b8f2f8">More...</a><br /></td></tr>
<tr class="separator:a3f156472cc6a07016eadf51082b8f2f8"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a0d23c82dcf122123ee29ffd3254b4b84"><td class="memTemplParams" colspan="2">template&lt;typename Component &gt; </td></tr>
<tr class="memitem:a0d23c82dcf122123ee29ffd3254b4b84"><td class="memTemplItemLeft" align="right" valign="top">const Component &amp;&#160;</td><td class="memTemplItemRight" valign="bottom"><a class="el" href="classentt_1_1Prototype.html#a0d23c82dcf122123ee29ffd3254b4b84">get</a> () const ENTT_NOEXCEPT</td></tr>
<tr class="memdesc:a0d23c82dcf122123ee29ffd3254b4b84"><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns a reference to the given component. <a href="#a0d23c82dcf122123ee29ffd3254b4b84">More...</a><br /></td></tr>
<tr class="separator:a0d23c82dcf122123ee29ffd3254b4b84"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a4069701eaf29716ed9bbb404da5f1b59"><td class="memTemplParams" colspan="2">template&lt;typename Component &gt; </td></tr>
<tr class="memitem:a4069701eaf29716ed9bbb404da5f1b59"><td class="memTemplItemLeft" align="right" valign="top">Component &amp;&#160;</td><td class="memTemplItemRight" valign="bottom"><a class="el" href="classentt_1_1Prototype.html#a4069701eaf29716ed9bbb404da5f1b59">get</a> () ENTT_NOEXCEPT</td></tr>
<tr class="memdesc:a4069701eaf29716ed9bbb404da5f1b59"><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns a reference to the given component. <a href="#a4069701eaf29716ed9bbb404da5f1b59">More...</a><br /></td></tr>
<tr class="separator:a4069701eaf29716ed9bbb404da5f1b59"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ae52596223d2a61e52c41979b1e76d68f"><td class="memTemplParams" colspan="2">template&lt;typename... Component&gt; </td></tr>
<tr class="memitem:ae52596223d2a61e52c41979b1e76d68f"><td class="memTemplItemLeft" align="right" valign="top">std::enable_if_t&lt;(sizeof...(Component) &gt; 1), std::tuple&lt; const Component &amp;... &gt; &gt;&#160;</td><td class="memTemplItemRight" valign="bottom"><a class="el" href="classentt_1_1Prototype.html#ae52596223d2a61e52c41979b1e76d68f">get</a> () const ENTT_NOEXCEPT</td></tr>
<tr class="memdesc:ae52596223d2a61e52c41979b1e76d68f"><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns a reference to the given components. <a href="#ae52596223d2a61e52c41979b1e76d68f">More...</a><br /></td></tr>
<tr class="separator:ae52596223d2a61e52c41979b1e76d68f"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a35fcf29a4c01caa611cffa9f73cbe535"><td class="memTemplParams" colspan="2">template&lt;typename... Component&gt; </td></tr>
<tr class="memitem:a35fcf29a4c01caa611cffa9f73cbe535"><td class="memTemplItemLeft" align="right" valign="top">std::enable_if_t&lt;(sizeof...(Component) &gt; 1), std::tuple&lt; Component &amp;... &gt; &gt;&#160;</td><td class="memTemplItemRight" valign="bottom"><a class="el" href="classentt_1_1Prototype.html#a35fcf29a4c01caa611cffa9f73cbe535">get</a> () ENTT_NOEXCEPT</td></tr>
<tr class="memdesc:a35fcf29a4c01caa611cffa9f73cbe535"><td class="mdescLeft">&#160;</td><td class="mdescRight">Returns a reference to the given components. <a href="#a35fcf29a4c01caa611cffa9f73cbe535">More...</a><br /></td></tr>
<tr class="separator:a35fcf29a4c01caa611cffa9f73cbe535"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a434b43ae5f761093a0c9e74da0802523"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classentt_1_1Prototype.html#ab4542df6834170b6f0d96828d094269d">entity_type</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classentt_1_1Prototype.html#a434b43ae5f761093a0c9e74da0802523">create</a> (<a class="el" href="classentt_1_1Prototype.html#a8e4a91009c1cbb0bfaadf4e95178eaec">registry_type</a> &amp;other) const</td></tr>
<tr class="memdesc:a434b43ae5f761093a0c9e74da0802523"><td class="mdescLeft">&#160;</td><td class="mdescRight">Creates a new entity using a given prototype. <a href="#a434b43ae5f761093a0c9e74da0802523">More...</a><br /></td></tr>
<tr class="separator:a434b43ae5f761093a0c9e74da0802523"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a5a659d7582d8fb52c5be59b0a319e2ec"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classentt_1_1Prototype.html#ab4542df6834170b6f0d96828d094269d">entity_type</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classentt_1_1Prototype.html#a5a659d7582d8fb52c5be59b0a319e2ec">create</a> () const</td></tr>
<tr class="memdesc:a5a659d7582d8fb52c5be59b0a319e2ec"><td class="mdescLeft">&#160;</td><td class="mdescRight">Creates a new entity using a given prototype. <a href="#a5a659d7582d8fb52c5be59b0a319e2ec">More...</a><br /></td></tr>
<tr class="separator:a5a659d7582d8fb52c5be59b0a319e2ec"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a0a52cda550a678ee14272cff7b2fcf35"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classentt_1_1Prototype.html#a0a52cda550a678ee14272cff7b2fcf35">assign</a> (<a class="el" href="classentt_1_1Prototype.html#a8e4a91009c1cbb0bfaadf4e95178eaec">registry_type</a> &amp;other, const <a class="el" href="classentt_1_1Prototype.html#ab4542df6834170b6f0d96828d094269d">entity_type</a> dst) const</td></tr>
<tr class="memdesc:a0a52cda550a678ee14272cff7b2fcf35"><td class="mdescLeft">&#160;</td><td class="mdescRight">Assigns the components of a prototype to a given entity. <a href="#a0a52cda550a678ee14272cff7b2fcf35">More...</a><br /></td></tr>
<tr class="separator:a0a52cda550a678ee14272cff7b2fcf35"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ab7bf733f40f1071d73d4f3245526c038"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classentt_1_1Prototype.html#ab7bf733f40f1071d73d4f3245526c038">assign</a> (const <a class="el" href="classentt_1_1Prototype.html#ab4542df6834170b6f0d96828d094269d">entity_type</a> dst) const</td></tr>
<tr class="memdesc:ab7bf733f40f1071d73d4f3245526c038"><td class="mdescLeft">&#160;</td><td class="mdescRight">Assigns the components of a prototype to a given entity. <a href="#ab7bf733f40f1071d73d4f3245526c038">More...</a><br /></td></tr>
<tr class="separator:ab7bf733f40f1071d73d4f3245526c038"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:adaec9cc16436af85ef938fc9686cd02d"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classentt_1_1Prototype.html#adaec9cc16436af85ef938fc9686cd02d">accommodate</a> (<a class="el" href="classentt_1_1Prototype.html#a8e4a91009c1cbb0bfaadf4e95178eaec">registry_type</a> &amp;other, const <a class="el" href="classentt_1_1Prototype.html#ab4542df6834170b6f0d96828d094269d">entity_type</a> dst) const</td></tr>
<tr class="memdesc:adaec9cc16436af85ef938fc9686cd02d"><td class="mdescLeft">&#160;</td><td class="mdescRight">Assigns or replaces the components of a prototype for an entity. <a href="#adaec9cc16436af85ef938fc9686cd02d">More...</a><br /></td></tr>
<tr class="separator:adaec9cc16436af85ef938fc9686cd02d"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a37299298c61bb06a75b697296e328477"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classentt_1_1Prototype.html#a37299298c61bb06a75b697296e328477">accommodate</a> (const <a class="el" href="classentt_1_1Prototype.html#ab4542df6834170b6f0d96828d094269d">entity_type</a> dst) const</td></tr>
<tr class="memdesc:a37299298c61bb06a75b697296e328477"><td class="mdescLeft">&#160;</td><td class="mdescRight">Assigns or replaces the components of a prototype for an entity. <a href="#a37299298c61bb06a75b697296e328477">More...</a><br /></td></tr>
<tr class="separator:a37299298c61bb06a75b697296e328477"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ac7cb69aad2015e94f3a0a9ad42b82f1b"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classentt_1_1Prototype.html#ac7cb69aad2015e94f3a0a9ad42b82f1b">operator()</a> (<a class="el" href="classentt_1_1Prototype.html#a8e4a91009c1cbb0bfaadf4e95178eaec">registry_type</a> &amp;other, const <a class="el" href="classentt_1_1Prototype.html#ab4542df6834170b6f0d96828d094269d">entity_type</a> dst) const ENTT_NOEXCEPT</td></tr>
<tr class="memdesc:ac7cb69aad2015e94f3a0a9ad42b82f1b"><td class="mdescLeft">&#160;</td><td class="mdescRight">Assigns the components of a prototype to an entity. <a href="#ac7cb69aad2015e94f3a0a9ad42b82f1b">More...</a><br /></td></tr>
<tr class="separator:ac7cb69aad2015e94f3a0a9ad42b82f1b"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a6b0560c31432fb6591a772ce9a322728"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classentt_1_1Prototype.html#a6b0560c31432fb6591a772ce9a322728">operator()</a> (const <a class="el" href="classentt_1_1Prototype.html#ab4542df6834170b6f0d96828d094269d">entity_type</a> dst) const ENTT_NOEXCEPT</td></tr>
<tr class="memdesc:a6b0560c31432fb6591a772ce9a322728"><td class="mdescLeft">&#160;</td><td class="mdescRight">Assigns the components of a prototype to an entity. <a href="#a6b0560c31432fb6591a772ce9a322728">More...</a><br /></td></tr>
<tr class="separator:a6b0560c31432fb6591a772ce9a322728"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a7c401ecc89b0c88ab15ed2dd7686b54e"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classentt_1_1Prototype.html#ab4542df6834170b6f0d96828d094269d">entity_type</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classentt_1_1Prototype.html#a7c401ecc89b0c88ab15ed2dd7686b54e">operator()</a> (<a class="el" href="classentt_1_1Prototype.html#a8e4a91009c1cbb0bfaadf4e95178eaec">registry_type</a> &amp;other) const ENTT_NOEXCEPT</td></tr>
<tr class="memdesc:a7c401ecc89b0c88ab15ed2dd7686b54e"><td class="mdescLeft">&#160;</td><td class="mdescRight">Creates a new entity using a given prototype. <a href="#a7c401ecc89b0c88ab15ed2dd7686b54e">More...</a><br /></td></tr>
<tr class="separator:a7c401ecc89b0c88ab15ed2dd7686b54e"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ad39dd5c5449cc647a1402543ebe411fe"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classentt_1_1Prototype.html#ab4542df6834170b6f0d96828d094269d">entity_type</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classentt_1_1Prototype.html#ad39dd5c5449cc647a1402543ebe411fe">operator()</a> () const ENTT_NOEXCEPT</td></tr>
<tr class="memdesc:ad39dd5c5449cc647a1402543ebe411fe"><td class="mdescLeft">&#160;</td><td class="mdescRight">Creates a new entity using a given prototype. <a href="#ad39dd5c5449cc647a1402543ebe411fe">More...</a><br /></td></tr>
<tr class="separator:ad39dd5c5449cc647a1402543ebe411fe"><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 Entity&gt;<br />
class entt::Prototype&lt; Entity &gt;</h3>
<p><a class="el" href="classentt_1_1Prototype.html" title="Prototype container for concepts. ">Prototype</a> container for <em>concepts</em>. </p>
<p>A prototype is used to define a <em>concept</em> in terms of components.<br />
Prototypes act as templates for those specific types of an application which users would otherwise define through a series of component assignments to entities. In other words, prototypes can be used to assign components to entities of a registry at once.</p>
<dl class="section note"><dt>Note</dt><dd>Components used along with prototypes must be copy constructible. Prototypes wrap component types with custom types, so they do not interfere with other users of the registry they were built with.</dd></dl>
<dl class="section warning"><dt>Warning</dt><dd>Prototypes directly use their underlying registries to store entities and components for their purposes. Users must ensure that the lifetime of a registry and its contents exceed that of the prototypes that use it.</dd></dl>
<dl class="tparams"><dt>Template Parameters</dt><dd>
<table class="tparams">
<tr><td class="paramname">Entity</td><td>A valid entity type (see <a class="el" href="structentt_1_1entt__traits.html" title="Entity traits. ">entt_traits</a> for more details). </td></tr>
</table>
</dd>
</dl>
<p class="definition">Definition at line <a class="el" href="prototype_8hpp_source.html#l00039">39</a> of file <a class="el" href="prototype_8hpp_source.html">prototype.hpp</a>.</p>
</div><h2 class="groupheader">Constructor &amp; Destructor Documentation</h2>
<a id="aa6033be234aad4d287d740c40db17fec"></a>
<h2 class="memtitle"><span class="permalink"><a href="#aa6033be234aad4d287d740c40db17fec">&#9670;&nbsp;</a></span>Prototype() <span class="overload">[1/2]</span></h2>
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename Entity &gt; </div>
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="classentt_1_1Prototype.html">entt::Prototype</a>&lt; Entity &gt;::<a class="el" href="classentt_1_1Prototype.html">Prototype</a> </td>
<td>(</td>
<td class="paramtype"><a class="el" href="classentt_1_1Registry.html">Registry</a>&lt; Entity &gt; &amp;&#160;</td>
<td class="paramname"><em>registry</em></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Constructs a prototype that is bound to a given registry. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">registry</td><td>A valid reference to a registry. </td></tr>
</table>
</dd>
</dl>
<p class="definition">Definition at line <a class="el" href="prototype_8hpp_source.html#l00069">69</a> of file <a class="el" href="prototype_8hpp_source.html">prototype.hpp</a>.</p>
</div>
</div>
<a id="ad4900c4a27f506b5d2b9db54aba9d224"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ad4900c4a27f506b5d2b9db54aba9d224">&#9670;&nbsp;</a></span>Prototype() <span class="overload">[2/2]</span></h2>
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename Entity &gt; </div>
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="classentt_1_1Prototype.html">entt::Prototype</a>&lt; Entity &gt;::<a class="el" href="classentt_1_1Prototype.html">Prototype</a> </td>
<td>(</td>
<td class="paramtype"><a class="el" href="classentt_1_1Prototype.html">Prototype</a>&lt; Entity &gt; &amp;&amp;&#160;</td>
<td class="paramname"><em>other</em></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Move constructor. </p>
<p>After prototype move construction, instances that have been moved from are placed in a valid but unspecified state. It's highly discouraged to continue using them.</p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">other</td><td>The instance to move from. </td></tr>
</table>
</dd>
</dl>
<p class="definition">Definition at line <a class="el" href="prototype_8hpp_source.html#l00093">93</a> of file <a class="el" href="prototype_8hpp_source.html">prototype.hpp</a>.</p>
</div>
</div>
<h2 class="groupheader">Member Function Documentation</h2>
<a id="adaec9cc16436af85ef938fc9686cd02d"></a>
<h2 class="memtitle"><span class="permalink"><a href="#adaec9cc16436af85ef938fc9686cd02d">&#9670;&nbsp;</a></span>accommodate() <span class="overload">[1/2]</span></h2>
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename Entity &gt; </div>
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">void <a class="el" href="classentt_1_1Prototype.html">entt::Prototype</a>&lt; Entity &gt;::accommodate </td>
<td>(</td>
<td class="paramtype"><a class="el" href="classentt_1_1Prototype.html#a8e4a91009c1cbb0bfaadf4e95178eaec">registry_type</a> &amp;&#160;</td>
<td class="paramname"><em>other</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const <a class="el" href="classentt_1_1Prototype.html#ab4542df6834170b6f0d96828d094269d">entity_type</a>&#160;</td>
<td class="paramname"><em>dst</em>&#160;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Assigns or replaces the components of a prototype for an entity. </p>
<p>Existing components are overwritten, if any. All the other components will be copied over to the target entity.</p>
<dl class="section note"><dt>Note</dt><dd>The registry may or may not be different from the one already used by the prototype. There is also an overload that directly uses the underlying registry.</dd></dl>
<dl class="section warning"><dt>Warning</dt><dd>Attempting to use an invalid entity results in undefined behavior.<br />
An assertion will abort the execution at runtime in debug mode in case of invalid entity.</dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">other</td><td>A valid reference to a registry. </td></tr>
<tr><td class="paramname">dst</td><td>A valid entity identifier. </td></tr>
</table>
</dd>
</dl>
<p class="definition">Definition at line <a class="el" href="prototype_8hpp_source.html#l00356">356</a> of file <a class="el" href="prototype_8hpp_source.html">prototype.hpp</a>.</p>
</div>
</div>
<a id="a37299298c61bb06a75b697296e328477"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a37299298c61bb06a75b697296e328477">&#9670;&nbsp;</a></span>accommodate() <span class="overload">[2/2]</span></h2>
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename Entity &gt; </div>
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">void <a class="el" href="classentt_1_1Prototype.html">entt::Prototype</a>&lt; Entity &gt;::accommodate </td>
<td>(</td>
<td class="paramtype">const <a class="el" href="classentt_1_1Prototype.html#ab4542df6834170b6f0d96828d094269d">entity_type</a>&#160;</td>
<td class="paramname"><em>dst</em></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Assigns or replaces the components of a prototype for an entity. </p>
<p>Existing components are overwritten, if any. All the other components will be copied over to the target entity.</p>
<dl class="section note"><dt>Note</dt><dd>This overload directly uses the underlying registry as a working space. Therefore, the components of the prototype and of the entity will share the same registry.</dd></dl>
<dl class="section warning"><dt>Warning</dt><dd>Attempting to use an invalid entity results in undefined behavior.<br />
An assertion will abort the execution at runtime in debug mode in case of invalid entity.</dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">dst</td><td>A valid entity identifier. </td></tr>
</table>
</dd>
</dl>
<p class="definition">Definition at line <a class="el" href="prototype_8hpp_source.html#l00380">380</a> of file <a class="el" href="prototype_8hpp_source.html">prototype.hpp</a>.</p>
</div>
</div>
<a id="a0a52cda550a678ee14272cff7b2fcf35"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a0a52cda550a678ee14272cff7b2fcf35">&#9670;&nbsp;</a></span>assign() <span class="overload">[1/2]</span></h2>
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename Entity &gt; </div>
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">void <a class="el" href="classentt_1_1Prototype.html">entt::Prototype</a>&lt; Entity &gt;::assign </td>
<td>(</td>
<td class="paramtype"><a class="el" href="classentt_1_1Prototype.html#a8e4a91009c1cbb0bfaadf4e95178eaec">registry_type</a> &amp;&#160;</td>
<td class="paramname"><em>other</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const <a class="el" href="classentt_1_1Prototype.html#ab4542df6834170b6f0d96828d094269d">entity_type</a>&#160;</td>
<td class="paramname"><em>dst</em>&#160;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Assigns the components of a prototype to a given entity. </p>
<p>Assigning a prototype to an entity won't overwrite existing components under any circumstances.<br />
In other words, only those components that the entity doesn't own yet are copied over. All the other components remain unchanged.</p>
<dl class="section note"><dt>Note</dt><dd>The registry may or may not be different from the one already used by the prototype. There is also an overload that directly uses the underlying registry.</dd></dl>
<dl class="section warning"><dt>Warning</dt><dd>Attempting to use an invalid entity results in undefined behavior.<br />
An assertion will abort the execution at runtime in debug mode in case of invalid entity.</dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">other</td><td>A valid reference to a registry. </td></tr>
<tr><td class="paramname">dst</td><td>A valid entity identifier. </td></tr>
</table>
</dd>
</dl>
<p class="definition">Definition at line <a class="el" href="prototype_8hpp_source.html#l00307">307</a> of file <a class="el" href="prototype_8hpp_source.html">prototype.hpp</a>.</p>
</div>
</div>
<a id="ab7bf733f40f1071d73d4f3245526c038"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ab7bf733f40f1071d73d4f3245526c038">&#9670;&nbsp;</a></span>assign() <span class="overload">[2/2]</span></h2>
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename Entity &gt; </div>
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">void <a class="el" href="classentt_1_1Prototype.html">entt::Prototype</a>&lt; Entity &gt;::assign </td>
<td>(</td>
<td class="paramtype">const <a class="el" href="classentt_1_1Prototype.html#ab4542df6834170b6f0d96828d094269d">entity_type</a>&#160;</td>
<td class="paramname"><em>dst</em></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Assigns the components of a prototype to a given entity. </p>
<p>Assigning a prototype to an entity won't overwrite existing components under any circumstances.<br />
In other words, only those components that the entity doesn't own yet are copied over. All the other components remain unchanged.</p>
<dl class="section note"><dt>Note</dt><dd>This overload directly uses the underlying registry as a working space. Therefore, the components of the prototype and of the entity will share the same registry.</dd></dl>
<dl class="section warning"><dt>Warning</dt><dd>Attempting to use an invalid entity results in undefined behavior.<br />
An assertion will abort the execution at runtime in debug mode in case of invalid entity.</dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">dst</td><td>A valid entity identifier. </td></tr>
</table>
</dd>
</dl>
<p class="definition">Definition at line <a class="el" href="prototype_8hpp_source.html#l00333">333</a> of file <a class="el" href="prototype_8hpp_source.html">prototype.hpp</a>.</p>
</div>
</div>
<a id="a434b43ae5f761093a0c9e74da0802523"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a434b43ae5f761093a0c9e74da0802523">&#9670;&nbsp;</a></span>create() <span class="overload">[1/2]</span></h2>
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename Entity &gt; </div>
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="classentt_1_1Prototype.html#ab4542df6834170b6f0d96828d094269d">entity_type</a> <a class="el" href="classentt_1_1Prototype.html">entt::Prototype</a>&lt; Entity &gt;::create </td>
<td>(</td>
<td class="paramtype"><a class="el" href="classentt_1_1Prototype.html#a8e4a91009c1cbb0bfaadf4e95178eaec">registry_type</a> &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> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Creates a new entity using a given prototype. </p>
<p>Utility shortcut, equivalent to the following snippet:</p>
<div class="fragment"><div class="line"><span class="keyword">const</span> <span class="keyword">auto</span> entity = registry.create();</div><div class="line">prototype(registry, entity);</div></div><!-- fragment --><dl class="section note"><dt>Note</dt><dd>The registry may or may not be different from the one already used by the prototype. There is also an overload that directly uses the underlying registry.</dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">other</td><td>A valid reference to a registry. </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>A valid entity identifier. </dd></dl>
<p class="definition">Definition at line <a class="el" href="prototype_8hpp_source.html#l00259">259</a> of file <a class="el" href="prototype_8hpp_source.html">prototype.hpp</a>.</p>
</div>
</div>
<a id="a5a659d7582d8fb52c5be59b0a319e2ec"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a5a659d7582d8fb52c5be59b0a319e2ec">&#9670;&nbsp;</a></span>create() <span class="overload">[2/2]</span></h2>
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename Entity &gt; </div>
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="classentt_1_1Prototype.html#ab4542df6834170b6f0d96828d094269d">entity_type</a> <a class="el" href="classentt_1_1Prototype.html">entt::Prototype</a>&lt; Entity &gt;::create </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> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Creates a new entity using a given prototype. </p>
<p>Utility shortcut, equivalent to the following snippet:</p>
<div class="fragment"><div class="line"><span class="keyword">const</span> <span class="keyword">auto</span> entity = registry.create();</div><div class="line">prototype(entity);</div></div><!-- fragment --><dl class="section note"><dt>Note</dt><dd>This overload directly uses the underlying registry as a working space. Therefore, the components of the prototype and of the entity will share the same registry.</dd></dl>
<dl class="section return"><dt>Returns</dt><dd>A valid entity identifier. </dd></dl>
<p class="definition">Definition at line <a class="el" href="prototype_8hpp_source.html#l00282">282</a> of file <a class="el" href="prototype_8hpp_source.html">prototype.hpp</a>.</p>
</div>
</div>
<a id="a0d23c82dcf122123ee29ffd3254b4b84"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a0d23c82dcf122123ee29ffd3254b4b84">&#9670;&nbsp;</a></span>get() <span class="overload">[1/4]</span></h2>
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename Entity &gt; </div>
<div class="memtemplate">
template&lt;typename Component &gt; </div>
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">const Component&amp; <a class="el" href="classentt_1_1Prototype.html">entt::Prototype</a>&lt; Entity &gt;::get </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> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Returns a reference to the given component. </p>
<dl class="section warning"><dt>Warning</dt><dd>Attempting to get a component from a prototype that doesn't own it results in undefined behavior.<br />
An assertion will abort the execution at runtime in debug mode if the prototype doesn't own an instance of the given component.</dd></dl>
<dl class="tparams"><dt>Template Parameters</dt><dd>
<table class="tparams">
<tr><td class="paramname">Component</td><td>Type of component to get. </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>A reference to the component owned by the prototype. </dd></dl>
<p class="definition">Definition at line <a class="el" href="prototype_8hpp_source.html#l00184">184</a> of file <a class="el" href="prototype_8hpp_source.html">prototype.hpp</a>.</p>
</div>
</div>
<a id="a4069701eaf29716ed9bbb404da5f1b59"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a4069701eaf29716ed9bbb404da5f1b59">&#9670;&nbsp;</a></span>get() <span class="overload">[2/4]</span></h2>
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename Entity &gt; </div>
<div class="memtemplate">
template&lt;typename Component &gt; </div>
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">Component&amp; <a class="el" href="classentt_1_1Prototype.html">entt::Prototype</a>&lt; Entity &gt;::get </td>
<td>(</td>
<td class="paramname"></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Returns a reference to the given component. </p>
<dl class="section warning"><dt>Warning</dt><dd>Attempting to get a component from a prototype that doesn't own it results in undefined behavior.<br />
An assertion will abort the execution at runtime in debug mode if the prototype doesn't own an instance of the given component.</dd></dl>
<dl class="tparams"><dt>Template Parameters</dt><dd>
<table class="tparams">
<tr><td class="paramname">Component</td><td>Type of component to get. </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>A reference to the component owned by the prototype. </dd></dl>
<p class="definition">Definition at line <a class="el" href="prototype_8hpp_source.html#l00201">201</a> of file <a class="el" href="prototype_8hpp_source.html">prototype.hpp</a>.</p>
</div>
</div>
<a id="ae52596223d2a61e52c41979b1e76d68f"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ae52596223d2a61e52c41979b1e76d68f">&#9670;&nbsp;</a></span>get() <span class="overload">[3/4]</span></h2>
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename Entity &gt; </div>
<div class="memtemplate">
template&lt;typename... Component&gt; </div>
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">std::enable_if_t&lt;(sizeof...(Component) &gt; 1), std::tuple&lt;const Component &amp;...&gt; &gt; <a class="el" href="classentt_1_1Prototype.html">entt::Prototype</a>&lt; Entity &gt;::get </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> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Returns a reference to the given components. </p>
<dl class="section warning"><dt>Warning</dt><dd>Attempting to get components from a prototype that doesn't own them results in undefined behavior.<br />
An assertion will abort the execution at runtime in debug mode if the prototype doesn't own instances of the given components.</dd></dl>
<dl class="tparams"><dt>Template Parameters</dt><dd>
<table class="tparams">
<tr><td class="paramname">Component</td><td>Type of components to get. </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>References to the components owned by the prototype. </dd></dl>
<p class="definition">Definition at line <a class="el" href="prototype_8hpp_source.html#l00219">219</a> of file <a class="el" href="prototype_8hpp_source.html">prototype.hpp</a>.</p>
</div>
</div>
<a id="a35fcf29a4c01caa611cffa9f73cbe535"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a35fcf29a4c01caa611cffa9f73cbe535">&#9670;&nbsp;</a></span>get() <span class="overload">[4/4]</span></h2>
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename Entity &gt; </div>
<div class="memtemplate">
template&lt;typename... Component&gt; </div>
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">std::enable_if_t&lt;(sizeof...(Component) &gt; 1), std::tuple&lt;Component &amp;...&gt; &gt; <a class="el" href="classentt_1_1Prototype.html">entt::Prototype</a>&lt; Entity &gt;::get </td>
<td>(</td>
<td class="paramname"></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Returns a reference to the given components. </p>
<dl class="section warning"><dt>Warning</dt><dd>Attempting to get components from a prototype that doesn't own them results in undefined behavior.<br />
An assertion will abort the execution at runtime in debug mode if the prototype doesn't own instances of the given components.</dd></dl>
<dl class="tparams"><dt>Template Parameters</dt><dd>
<table class="tparams">
<tr><td class="paramname">Component</td><td>Type of components to get. </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>References to the components owned by the prototype. </dd></dl>
<p class="definition">Definition at line <a class="el" href="prototype_8hpp_source.html#l00237">237</a> of file <a class="el" href="prototype_8hpp_source.html">prototype.hpp</a>.</p>
</div>
</div>
<a id="a3f156472cc6a07016eadf51082b8f2f8"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a3f156472cc6a07016eadf51082b8f2f8">&#9670;&nbsp;</a></span>has()</h2>
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename Entity &gt; </div>
<div class="memtemplate">
template&lt;typename... Component&gt; </div>
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">bool <a class="el" href="classentt_1_1Prototype.html">entt::Prototype</a>&lt; Entity &gt;::has </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> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Checks if a prototype owns all the given components. </p>
<dl class="tparams"><dt>Template Parameters</dt><dd>
<table class="tparams">
<tr><td class="paramname">Component</td><td>Components for which to perform the check. </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>True if the prototype owns all the components, false otherwise. </dd></dl>
<p class="definition">Definition at line <a class="el" href="prototype_8hpp_source.html#l00167">167</a> of file <a class="el" href="prototype_8hpp_source.html">prototype.hpp</a>.</p>
</div>
</div>
<a id="ac7cb69aad2015e94f3a0a9ad42b82f1b"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ac7cb69aad2015e94f3a0a9ad42b82f1b">&#9670;&nbsp;</a></span>operator()() <span class="overload">[1/4]</span></h2>
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename Entity &gt; </div>
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">void <a class="el" href="classentt_1_1Prototype.html">entt::Prototype</a>&lt; Entity &gt;::operator() </td>
<td>(</td>
<td class="paramtype"><a class="el" href="classentt_1_1Prototype.html#a8e4a91009c1cbb0bfaadf4e95178eaec">registry_type</a> &amp;&#160;</td>
<td class="paramname"><em>other</em>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const <a class="el" href="classentt_1_1Prototype.html#ab4542df6834170b6f0d96828d094269d">entity_type</a>&#160;</td>
<td class="paramname"><em>dst</em>&#160;</td>
</tr>
<tr>
<td></td>
<td>)</td>
<td></td><td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Assigns the components of a prototype to an entity. </p>
<p>Assigning a prototype to an entity won't overwrite existing components under any circumstances.<br />
In other words, only the components that the entity doesn't own yet are copied over. All the other components remain unchanged.</p>
<dl class="section note"><dt>Note</dt><dd>The registry may or may not be different from the one already used by the prototype. There is also an overload that directly uses the underlying registry.</dd></dl>
<dl class="section warning"><dt>Warning</dt><dd>Attempting to use an invalid entity results in undefined behavior.<br />
An assertion will abort the execution at runtime in debug mode in case of invalid entity.</dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">other</td><td>A valid reference to a registry. </td></tr>
<tr><td class="paramname">dst</td><td>A valid entity identifier. </td></tr>
</table>
</dd>
</dl>
<p class="definition">Definition at line <a class="el" href="prototype_8hpp_source.html#l00405">405</a> of file <a class="el" href="prototype_8hpp_source.html">prototype.hpp</a>.</p>
</div>
</div>
<a id="a6b0560c31432fb6591a772ce9a322728"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a6b0560c31432fb6591a772ce9a322728">&#9670;&nbsp;</a></span>operator()() <span class="overload">[2/4]</span></h2>
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename Entity &gt; </div>
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">void <a class="el" href="classentt_1_1Prototype.html">entt::Prototype</a>&lt; Entity &gt;::operator() </td>
<td>(</td>
<td class="paramtype">const <a class="el" href="classentt_1_1Prototype.html#ab4542df6834170b6f0d96828d094269d">entity_type</a>&#160;</td>
<td class="paramname"><em>dst</em></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Assigns the components of a prototype to an entity. </p>
<p>Assigning a prototype to an entity won't overwrite existing components under any circumstances.<br />
In other words, only the components that the entity doesn't own yet are copied over. All the other components remain unchanged.</p>
<dl class="section note"><dt>Note</dt><dd>This overload directly uses the underlying registry as a working space. Therefore, the components of the prototype and of the entity will share the same registry.</dd></dl>
<dl class="section warning"><dt>Warning</dt><dd>Attempting to use an invalid entity results in undefined behavior.<br />
An assertion will abort the execution at runtime in debug mode in case of invalid entity.</dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">dst</td><td>A valid entity identifier. </td></tr>
</table>
</dd>
</dl>
<p class="definition">Definition at line <a class="el" href="prototype_8hpp_source.html#l00429">429</a> of file <a class="el" href="prototype_8hpp_source.html">prototype.hpp</a>.</p>
</div>
</div>
<a id="a7c401ecc89b0c88ab15ed2dd7686b54e"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a7c401ecc89b0c88ab15ed2dd7686b54e">&#9670;&nbsp;</a></span>operator()() <span class="overload">[3/4]</span></h2>
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename Entity &gt; </div>
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="classentt_1_1Prototype.html#ab4542df6834170b6f0d96828d094269d">entity_type</a> <a class="el" href="classentt_1_1Prototype.html">entt::Prototype</a>&lt; Entity &gt;::operator() </td>
<td>(</td>
<td class="paramtype"><a class="el" href="classentt_1_1Prototype.html#a8e4a91009c1cbb0bfaadf4e95178eaec">registry_type</a> &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> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Creates a new entity using a given prototype. </p>
<p>Utility shortcut, equivalent to the following snippet:</p>
<div class="fragment"><div class="line"><span class="keyword">const</span> <span class="keyword">auto</span> entity = registry.create();</div><div class="line">prototype(registry, entity);</div></div><!-- fragment --><dl class="section note"><dt>Note</dt><dd>The registry may or may not be different from the one already used by the prototype. There is also an overload that directly uses the underlying registry.</dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">other</td><td>A valid reference to a registry. </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>A valid entity identifier. </dd></dl>
<p class="definition">Definition at line <a class="el" href="prototype_8hpp_source.html#l00451">451</a> of file <a class="el" href="prototype_8hpp_source.html">prototype.hpp</a>.</p>
</div>
</div>
<a id="ad39dd5c5449cc647a1402543ebe411fe"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ad39dd5c5449cc647a1402543ebe411fe">&#9670;&nbsp;</a></span>operator()() <span class="overload">[4/4]</span></h2>
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename Entity &gt; </div>
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="classentt_1_1Prototype.html#ab4542df6834170b6f0d96828d094269d">entity_type</a> <a class="el" href="classentt_1_1Prototype.html">entt::Prototype</a>&lt; Entity &gt;::operator() </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> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Creates a new entity using a given prototype. </p>
<p>Utility shortcut, equivalent to the following snippet:</p>
<div class="fragment"><div class="line"><span class="keyword">const</span> <span class="keyword">auto</span> entity = registry.create();</div><div class="line">prototype(entity);</div></div><!-- fragment --><dl class="section note"><dt>Note</dt><dd>This overload directly uses the underlying registry as a working space. Therefore, the components of the prototype and of the entity will share the same registry.</dd></dl>
<dl class="section return"><dt>Returns</dt><dd>A valid entity identifier. </dd></dl>
<p class="definition">Definition at line <a class="el" href="prototype_8hpp_source.html#l00472">472</a> of file <a class="el" href="prototype_8hpp_source.html">prototype.hpp</a>.</p>
</div>
</div>
<a id="a65529171240b1b7c348445c7ba4f319e"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a65529171240b1b7c348445c7ba4f319e">&#9670;&nbsp;</a></span>operator=() <span class="overload">[1/2]</span></h2>
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename Entity &gt; </div>
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="classentt_1_1Prototype.html">Prototype</a>&amp; <a class="el" href="classentt_1_1Prototype.html">entt::Prototype</a>&lt; Entity &gt;::operator= </td>
<td>(</td>
<td class="paramtype">const <a class="el" href="classentt_1_1Prototype.html">Prototype</a>&lt; Entity &gt; &amp;&#160;</td>
<td class="paramname"></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">delete</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Copying a prototype isn't allowed. </p>
<dl class="section return"><dt>Returns</dt><dd>This <a class="el" href="classentt_1_1Prototype.html" title="Prototype container for concepts. ">Prototype</a>. </dd></dl>
</div>
</div>
<a id="a9faf0b8878925090431a9e6acaed06c5"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a9faf0b8878925090431a9e6acaed06c5">&#9670;&nbsp;</a></span>operator=() <span class="overload">[2/2]</span></h2>
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename Entity &gt; </div>
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="classentt_1_1Prototype.html">Prototype</a>&amp; <a class="el" href="classentt_1_1Prototype.html">entt::Prototype</a>&lt; Entity &gt;::operator= </td>
<td>(</td>
<td class="paramtype"><a class="el" href="classentt_1_1Prototype.html">Prototype</a>&lt; Entity &gt; &amp;&amp;&#160;</td>
<td class="paramname"><em>other</em></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Move assignment operator. </p>
<p>After prototype move assignment, instances that have been moved from are placed in a valid but unspecified state. It's highly discouraged to continue using them.</p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">other</td><td>The instance to move from. </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>This <a class="el" href="classentt_1_1Prototype.html" title="Prototype container for concepts. ">Prototype</a>. </dd></dl>
<p class="definition">Definition at line <a class="el" href="prototype_8hpp_source.html#l00114">114</a> of file <a class="el" href="prototype_8hpp_source.html">prototype.hpp</a>.</p>
</div>
</div>
<a id="abf665ce59c8f43c4eff3ce77a21c5cfb"></a>
<h2 class="memtitle"><span class="permalink"><a href="#abf665ce59c8f43c4eff3ce77a21c5cfb">&#9670;&nbsp;</a></span>set()</h2>
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename Entity &gt; </div>
<div class="memtemplate">
template&lt;typename Component , typename... Args&gt; </div>
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">Component&amp; <a class="el" href="classentt_1_1Prototype.html">entt::Prototype</a>&lt; Entity &gt;::set </td>
<td>(</td>
<td class="paramtype">Args &amp;&amp;...&#160;</td>
<td class="paramname"><em>args</em></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Assigns to or replaces the given component of a prototype. </p>
<dl class="tparams"><dt>Template Parameters</dt><dd>
<table class="tparams">
<tr><td class="paramname">Component</td><td>Type of component to assign or replace. </td></tr>
<tr><td class="paramname">Args</td><td>Types of arguments to use to construct the component. </td></tr>
</table>
</dd>
</dl>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">args</td><td>Parameters to use to initialize the component. </td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>A reference to the newly created component. </dd></dl>
<p class="definition">Definition at line <a class="el" href="prototype_8hpp_source.html#l00133">133</a> of file <a class="el" href="prototype_8hpp_source.html">prototype.hpp</a>.</p>
</div>
</div>
<a id="ac75f485a3afa9dada4574269be50166d"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ac75f485a3afa9dada4574269be50166d">&#9670;&nbsp;</a></span>unset()</h2>
<div class="memitem">
<div class="memproto">
<div class="memtemplate">
template&lt;typename Entity &gt; </div>
<div class="memtemplate">
template&lt;typename Component &gt; </div>
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">void <a class="el" href="classentt_1_1Prototype.html">entt::Prototype</a>&lt; Entity &gt;::unset </td>
<td>(</td>
<td class="paramname"></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Removes the given component from a prototype. </p>
<dl class="tparams"><dt>Template Parameters</dt><dd>
<table class="tparams">
<tr><td class="paramname">Component</td><td>Type of component to remove. </td></tr>
</table>
</dd>
</dl>
<p class="definition">Definition at line <a class="el" href="prototype_8hpp_source.html#l00156">156</a> of file <a class="el" href="prototype_8hpp_source.html">prototype.hpp</a>.</p>
</div>
</div>
<hr/>The documentation for this class was generated from the following file:<ul>
<li>src/entt/entity/<a class="el" href="prototype_8hpp_source.html">prototype.hpp</a></li>
</ul>
</div><!-- contents -->
<!-- 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.png" alt="doxygen"/>
</a> 1.8.13
</small></address>
</body>
</html>