108 lines
52 KiB
HTML
108 lines
52 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: src/entt/entity/prototype.hpp Source File</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
|
|
 <span id="projectnumber">3.1.0</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="dir_68267d1309a1af8e8297ef4c3efbcdba.html">src</a></li><li class="navelem"><a class="el" href="dir_66e9674e8206a335795995fa32a03c91.html">entt</a></li><li class="navelem"><a class="el" href="dir_e3a7bb56c55e5c2286e2fe96e197d4f5.html">entity</a></li> </ul>
|
|
</div>
|
|
</div><!-- top -->
|
|
<div class="header">
|
|
<div class="headertitle">
|
|
<div class="title">prototype.hpp</div> </div>
|
|
</div><!--header-->
|
|
<div class="contents">
|
|
<div class="fragment"><div class="line"><a name="l00001"></a><span class="lineno"> 1</span> <span class="preprocessor">#ifndef ENTT_ENTITY_PROTOTYPE_HPP</span></div><div class="line"><a name="l00002"></a><span class="lineno"> 2</span> <span class="preprocessor">#define ENTT_ENTITY_PROTOTYPE_HPP</span></div><div class="line"><a name="l00003"></a><span class="lineno"> 3</span> </div><div class="line"><a name="l00004"></a><span class="lineno"> 4</span> </div><div class="line"><a name="l00005"></a><span class="lineno"> 5</span> <span class="preprocessor">#include <tuple></span></div><div class="line"><a name="l00006"></a><span class="lineno"> 6</span> <span class="preprocessor">#include <utility></span></div><div class="line"><a name="l00007"></a><span class="lineno"> 7</span> <span class="preprocessor">#include <cstddef></span></div><div class="line"><a name="l00008"></a><span class="lineno"> 8</span> <span class="preprocessor">#include <type_traits></span></div><div class="line"><a name="l00009"></a><span class="lineno"> 9</span> <span class="preprocessor">#include <unordered_map></span></div><div class="line"><a name="l00010"></a><span class="lineno"> 10</span> <span class="preprocessor">#include "../config/config.h"</span></div><div class="line"><a name="l00011"></a><span class="lineno"> 11</span> <span class="preprocessor">#include "registry.hpp"</span></div><div class="line"><a name="l00012"></a><span class="lineno"> 12</span> <span class="preprocessor">#include "entity.hpp"</span></div><div class="line"><a name="l00013"></a><span class="lineno"> 13</span> <span class="preprocessor">#include "fwd.hpp"</span></div><div class="line"><a name="l00014"></a><span class="lineno"> 14</span> </div><div class="line"><a name="l00015"></a><span class="lineno"> 15</span> </div><div class="line"><a name="l00016"></a><span class="lineno"> 16</span> <span class="keyword">namespace </span><a class="code" href="namespaceentt.html">entt</a> {</div><div class="line"><a name="l00017"></a><span class="lineno"> 17</span> </div><div class="line"><a name="l00018"></a><span class="lineno"> 18</span> </div><div class="line"><a name="l00040"></a><span class="lineno"> 40</span> <span class="keyword">template</span><<span class="keyword">typename</span> Entity></div><div class="line"><a name="l00041"></a><span class="lineno"> 41</span> <span class="keyword">class </span>basic_prototype {</div><div class="line"><a name="l00042"></a><span class="lineno"> 42</span>  <span class="keyword">using</span> basic_fn_type = void(<span class="keyword">const</span> <a class="code" href="classentt_1_1basic__prototype.html#acffae325962a54170176025d67d38a80">basic_prototype</a> &, basic_registry<Entity> &, <span class="keyword">const</span> Entity);</div><div class="line"><a name="l00043"></a><span class="lineno"> 43</span>  <span class="keyword">using</span> component_type = <span class="keyword">typename</span> <a class="code" href="classentt_1_1basic__registry.html#ace85f74fac787b967100f4186860f226">basic_registry<Entity>::component_type</a>;</div><div class="line"><a name="l00044"></a><span class="lineno"> 44</span> </div><div class="line"><a name="l00045"></a><span class="lineno"> 45</span>  <span class="keyword">template</span><<span class="keyword">typename</span> Component></div><div class="line"><a name="l00046"></a><span class="lineno"> 46</span>  <span class="keyword">struct </span>component_wrapper { Component component; };</div><div class="line"><a name="l00047"></a><span class="lineno"> 47</span> </div><div class="line"><a name="l00048"></a><span class="lineno"> 48</span>  <span class="keyword">struct </span>component_handler {</div><div class="line"><a name="l00049"></a><span class="lineno"> 49</span>  basic_fn_type *<a class="code" href="classentt_1_1basic__prototype.html#ad8cc32084b579a727669e8f0e7b600a9">assign_or_replace</a>;</div><div class="line"><a name="l00050"></a><span class="lineno"> 50</span>  basic_fn_type *<a class="code" href="classentt_1_1basic__prototype.html#a0a5c5313d46f5f52977e7fc3fe93d865">assign</a>;</div><div class="line"><a name="l00051"></a><span class="lineno"> 51</span>  };</div><div class="line"><a name="l00052"></a><span class="lineno"> 52</span> </div><div class="line"><a name="l00053"></a><span class="lineno"> 53</span>  <span class="keywordtype">void</span> release() {</div><div class="line"><a name="l00054"></a><span class="lineno"> 54</span>  <span class="keywordflow">if</span>(reg->valid(entity)) {</div><div class="line"><a name="l00055"></a><span class="lineno"> 55</span>  reg->destroy(entity);</div><div class="line"><a name="l00056"></a><span class="lineno"> 56</span>  }</div><div class="line"><a name="l00057"></a><span class="lineno"> 57</span>  }</div><div class="line"><a name="l00058"></a><span class="lineno"> 58</span> </div><div class="line"><a name="l00059"></a><span class="lineno"> 59</span> <span class="keyword">public</span>:</div><div class="line"><a name="l00061"></a><span class="lineno"><a class="line" href="classentt_1_1basic__prototype.html#aa7b03fff67dee5898849c971bc341962"> 61</a></span>  <span class="keyword">using</span> <a class="code" href="classentt_1_1basic__registry.html">registry_type</a> = <a class="code" href="classentt_1_1basic__registry.html">basic_registry<Entity></a>;</div><div class="line"><a name="l00063"></a><span class="lineno"><a class="line" href="classentt_1_1basic__prototype.html#a0a8606dc36496d42f6188acdad4906f3"> 63</a></span>  <span class="keyword">using</span> <a class="code" href="classentt_1_1basic__prototype.html#a0a8606dc36496d42f6188acdad4906f3">entity_type</a> = Entity;</div><div class="line"><a name="l00065"></a><span class="lineno"><a class="line" href="classentt_1_1basic__prototype.html#a01d3afe0260e80974f24c1d36b5fbccc"> 65</a></span>  <span class="keyword">using</span> <a class="code" href="classentt_1_1basic__prototype.html#a01d3afe0260e80974f24c1d36b5fbccc">size_type</a> = std::size_t;</div><div class="line"><a name="l00066"></a><span class="lineno"> 66</span> </div><div class="line"><a name="l00071"></a><span class="lineno"><a class="line" href="classentt_1_1basic__prototype.html#acffae325962a54170176025d67d38a80"> 71</a></span>  <span class="keyword">explicit</span> <a class="code" href="classentt_1_1basic__prototype.html#acffae325962a54170176025d67d38a80">basic_prototype</a>(<a class="code" href="classentt_1_1basic__registry.html">registry_type</a> &ref)</div><div class="line"><a name="l00072"></a><span class="lineno"> 72</span>  : reg{&ref},</div><div class="line"><a name="l00073"></a><span class="lineno"> 73</span>  entity{ref.<a class="code" href="classentt_1_1basic__registry.html#a1bb5d5d0c5af3bd98de3d902406ff372">create</a>()}</div><div class="line"><a name="l00074"></a><span class="lineno"> 74</span>  {}</div><div class="line"><a name="l00075"></a><span class="lineno"> 75</span> </div><div class="line"><a name="l00079"></a><span class="lineno"><a class="line" href="classentt_1_1basic__prototype.html#a1181e970dc90a33b823210d33af819d5"> 79</a></span>  <a class="code" href="classentt_1_1basic__prototype.html#a1181e970dc90a33b823210d33af819d5">~basic_prototype</a>() {</div><div class="line"><a name="l00080"></a><span class="lineno"> 80</span>  release();</div><div class="line"><a name="l00081"></a><span class="lineno"> 81</span>  }</div><div class="line"><a name="l00082"></a><span class="lineno"> 82</span> </div><div class="line"><a name="l00092"></a><span class="lineno"><a class="line" href="classentt_1_1basic__prototype.html#a1592ff421e77a624830cb965c6f52110"> 92</a></span>  <a class="code" href="classentt_1_1basic__prototype.html#a1592ff421e77a624830cb965c6f52110">basic_prototype</a>(<a class="code" href="classentt_1_1basic__prototype.html">basic_prototype</a> &&other)</div><div class="line"><a name="l00093"></a><span class="lineno"> 93</span>  : handlers{std::move(other.handlers)},</div><div class="line"><a name="l00094"></a><span class="lineno"> 94</span>  reg{other.reg},</div><div class="line"><a name="l00095"></a><span class="lineno"> 95</span>  entity{other.entity}</div><div class="line"><a name="l00096"></a><span class="lineno"> 96</span>  {</div><div class="line"><a name="l00097"></a><span class="lineno"> 97</span>  other.entity = <a class="code" href="namespaceentt.html#a588326af8f6f902a6c0b57d3f9fc6c17">null</a>;</div><div class="line"><a name="l00098"></a><span class="lineno"> 98</span>  }</div><div class="line"><a name="l00099"></a><span class="lineno"> 99</span> </div><div class="line"><a name="l00110"></a><span class="lineno"><a class="line" href="classentt_1_1basic__prototype.html#a24a5c455ba9368897c959f722496fa54"> 110</a></span>  <a class="code" href="classentt_1_1basic__prototype.html">basic_prototype</a> & <a class="code" href="classentt_1_1basic__prototype.html#a24a5c455ba9368897c959f722496fa54">operator=</a>(<a class="code" href="classentt_1_1basic__prototype.html">basic_prototype</a> &&other) {</div><div class="line"><a name="l00111"></a><span class="lineno"> 111</span>  <span class="keywordflow">if</span>(<span class="keyword">this</span> != &other) {</div><div class="line"><a name="l00112"></a><span class="lineno"> 112</span>  <span class="keyword">auto</span> tmp{std::move(other)};</div><div class="line"><a name="l00113"></a><span class="lineno"> 113</span>  handlers.swap(tmp.handlers);</div><div class="line"><a name="l00114"></a><span class="lineno"> 114</span>  std::swap(reg, tmp.reg);</div><div class="line"><a name="l00115"></a><span class="lineno"> 115</span>  std::swap(entity, tmp.entity);</div><div class="line"><a name="l00116"></a><span class="lineno"> 116</span>  }</div><div class="line"><a name="l00117"></a><span class="lineno"> 117</span> </div><div class="line"><a name="l00118"></a><span class="lineno"> 118</span>  <span class="keywordflow">return</span> *<span class="keyword">this</span>;</div><div class="line"><a name="l00119"></a><span class="lineno"> 119</span>  }</div><div class="line"><a name="l00120"></a><span class="lineno"> 120</span> </div><div class="line"><a name="l00128"></a><span class="lineno"> 128</span>  <span class="keyword">template</span><<span class="keyword">typename</span> Component, <span class="keyword">typename</span>... Args></div><div class="line"><a name="l00129"></a><span class="lineno"><a class="line" href="classentt_1_1basic__prototype.html#afb3ed35c2b2edcca53a618116208ca94"> 129</a></span>  Component & <span class="keyword">set</span>(Args &&... args) {</div><div class="line"><a name="l00130"></a><span class="lineno"> 130</span>  component_handler handler;</div><div class="line"><a name="l00131"></a><span class="lineno"> 131</span> </div><div class="line"><a name="l00132"></a><span class="lineno"> 132</span>  handler.assign_or_replace = [](<span class="keyword">const</span> <a class="code" href="classentt_1_1basic__prototype.html">basic_prototype</a> &proto, <a class="code" href="classentt_1_1basic__registry.html">registry_type</a> &other, <span class="keyword">const</span> Entity dst) {</div><div class="line"><a name="l00133"></a><span class="lineno"> 133</span>  <span class="keyword">const</span> <span class="keyword">auto</span> &wrapper = proto.reg->template get<component_wrapper<Component>>(proto.entity);</div><div class="line"><a name="l00134"></a><span class="lineno"> 134</span>  other.template assign_or_replace<Component>(dst, wrapper.component);</div><div class="line"><a name="l00135"></a><span class="lineno"> 135</span>  };</div><div class="line"><a name="l00136"></a><span class="lineno"> 136</span> </div><div class="line"><a name="l00137"></a><span class="lineno"> 137</span>  handler.assign = [](<span class="keyword">const</span> <a class="code" href="classentt_1_1basic__prototype.html">basic_prototype</a> &proto, <a class="code" href="classentt_1_1basic__registry.html">registry_type</a> &other, <span class="keyword">const</span> Entity dst) {</div><div class="line"><a name="l00138"></a><span class="lineno"> 138</span>  <span class="keywordflow">if</span>(!other.template has<Component>(dst)) {</div><div class="line"><a name="l00139"></a><span class="lineno"> 139</span>  <span class="keyword">const</span> <span class="keyword">auto</span> &wrapper = proto.reg->template get<component_wrapper<Component>>(proto.entity);</div><div class="line"><a name="l00140"></a><span class="lineno"> 140</span>  other.template assign<Component>(dst, wrapper.component);</div><div class="line"><a name="l00141"></a><span class="lineno"> 141</span>  }</div><div class="line"><a name="l00142"></a><span class="lineno"> 142</span>  };</div><div class="line"><a name="l00143"></a><span class="lineno"> 143</span> </div><div class="line"><a name="l00144"></a><span class="lineno"> 144</span>  handlers[reg->template type<Component>()] = handler;</div><div class="line"><a name="l00145"></a><span class="lineno"> 145</span>  <span class="keyword">auto</span> &wrapper = reg->template assign_or_replace<component_wrapper<Component>>(entity, Component{std::forward<Args>(args)...});</div><div class="line"><a name="l00146"></a><span class="lineno"> 146</span>  <span class="keywordflow">return</span> wrapper.component;</div><div class="line"><a name="l00147"></a><span class="lineno"> 147</span>  }</div><div class="line"><a name="l00148"></a><span class="lineno"> 148</span> </div><div class="line"><a name="l00153"></a><span class="lineno"> 153</span>  <span class="keyword">template</span><<span class="keyword">typename</span> Component></div><div class="line"><a name="l00154"></a><span class="lineno"><a class="line" href="classentt_1_1basic__prototype.html#a05230038ddbafaca4d5da09dfb247186"> 154</a></span>  <span class="keywordtype">void</span> <a class="code" href="classentt_1_1basic__prototype.html#a05230038ddbafaca4d5da09dfb247186">unset</a>() ENTT_NOEXCEPT {</div><div class="line"><a name="l00155"></a><span class="lineno"> 155</span>  reg->template reset<component_wrapper<Component>>(entity);</div><div class="line"><a name="l00156"></a><span class="lineno"> 156</span>  handlers.erase(reg->template type<Component>());</div><div class="line"><a name="l00157"></a><span class="lineno"> 157</span>  }</div><div class="line"><a name="l00158"></a><span class="lineno"> 158</span> </div><div class="line"><a name="l00164"></a><span class="lineno"> 164</span>  <span class="keyword">template</span><<span class="keyword">typename</span>... Component></div><div class="line"><a name="l00165"></a><span class="lineno"><a class="line" href="classentt_1_1basic__prototype.html#a6d4f9ce06a07f9b40ec714b13428326c"> 165</a></span>  <span class="keywordtype">bool</span> <a class="code" href="classentt_1_1basic__prototype.html#a6d4f9ce06a07f9b40ec714b13428326c">has</a>() const ENTT_NOEXCEPT {</div><div class="line"><a name="l00166"></a><span class="lineno"> 166</span>  <span class="keywordflow">return</span> reg->template has<component_wrapper<Component>...>(entity);</div><div class="line"><a name="l00167"></a><span class="lineno"> 167</span>  }</div><div class="line"><a name="l00168"></a><span class="lineno"> 168</span> </div><div class="line"><a name="l00181"></a><span class="lineno"> 181</span>  <span class="keyword">template</span><<span class="keyword">typename</span>... Component></div><div class="line"><a name="l00182"></a><span class="lineno"><a class="line" href="classentt_1_1basic__prototype.html#ac030e38aaa91c32530493a97a64fe1af"> 182</a></span>  decltype(<span class="keyword">auto</span>) <a class="code" href="classentt_1_1basic__prototype.html#ac030e38aaa91c32530493a97a64fe1af">get</a>() const ENTT_NOEXCEPT {</div><div class="line"><a name="l00183"></a><span class="lineno"> 183</span>  <span class="keywordflow">if</span> constexpr(<span class="keyword">sizeof</span>...(Component) == 1) {</div><div class="line"><a name="l00184"></a><span class="lineno"> 184</span>  <span class="keywordflow">return</span> (std::as_const(*reg).template <span class="keyword">get</span><component_wrapper<Component...>>(entity).component);</div><div class="line"><a name="l00185"></a><span class="lineno"> 185</span>  } <span class="keywordflow">else</span> {</div><div class="line"><a name="l00186"></a><span class="lineno"> 186</span>  <span class="keywordflow">return</span> std::tuple<std::add_const_t<Component> &...>{get<Component>()...};</div><div class="line"><a name="l00187"></a><span class="lineno"> 187</span>  }</div><div class="line"><a name="l00188"></a><span class="lineno"> 188</span>  }</div><div class="line"><a name="l00189"></a><span class="lineno"> 189</span> </div><div class="line"><a name="l00191"></a><span class="lineno"> 191</span>  <span class="keyword">template</span><<span class="keyword">typename</span>... Component></div><div class="line"><a name="l00192"></a><span class="lineno"><a class="line" href="classentt_1_1basic__prototype.html#a803649bd8fde6e3adad5c99dd118186a"> 192</a></span>  decltype(<span class="keyword">auto</span>) <a class="code" href="classentt_1_1basic__prototype.html#ac030e38aaa91c32530493a97a64fe1af">get</a>() ENTT_NOEXCEPT {</div><div class="line"><a name="l00193"></a><span class="lineno"> 193</span>  <span class="keywordflow">if</span> constexpr(<span class="keyword">sizeof</span>...(Component) == 1) {</div><div class="line"><a name="l00194"></a><span class="lineno"> 194</span>  <span class="keywordflow">return</span> (const_cast<Component &>(std::as_const(*this).template get<Component>()), ...);</div><div class="line"><a name="l00195"></a><span class="lineno"> 195</span>  } <span class="keywordflow">else</span> {</div><div class="line"><a name="l00196"></a><span class="lineno"> 196</span>  <span class="keywordflow">return</span> std::tuple<Component &...>{get<Component>()...};</div><div class="line"><a name="l00197"></a><span class="lineno"> 197</span>  }</div><div class="line"><a name="l00198"></a><span class="lineno"> 198</span>  }</div><div class="line"><a name="l00199"></a><span class="lineno"> 199</span> </div><div class="line"><a name="l00205"></a><span class="lineno"> 205</span>  <span class="keyword">template</span><<span class="keyword">typename</span>... Component></div><div class="line"><a name="l00206"></a><span class="lineno"><a class="line" href="classentt_1_1basic__prototype.html#a26c239c2d51cda5c0f5ff398d6a67f8c"> 206</a></span>  <span class="keyword">auto</span> <a class="code" href="classentt_1_1basic__prototype.html#a26c239c2d51cda5c0f5ff398d6a67f8c">try_get</a>() const ENTT_NOEXCEPT {</div><div class="line"><a name="l00207"></a><span class="lineno"> 207</span>  <span class="keywordflow">if</span> constexpr(<span class="keyword">sizeof</span>...(Component) == 1) {</div><div class="line"><a name="l00208"></a><span class="lineno"> 208</span>  <span class="keyword">const</span> <span class="keyword">auto</span> *wrapper = reg->template <a class="code" href="classentt_1_1basic__prototype.html#a26c239c2d51cda5c0f5ff398d6a67f8c">try_get</a><component_wrapper<Component...>>(entity);</div><div class="line"><a name="l00209"></a><span class="lineno"> 209</span>  <span class="keywordflow">return</span> wrapper ? &wrapper->component : <span class="keyword">nullptr</span>;</div><div class="line"><a name="l00210"></a><span class="lineno"> 210</span>  } <span class="keywordflow">else</span> {</div><div class="line"><a name="l00211"></a><span class="lineno"> 211</span>  <span class="keywordflow">return</span> std::tuple<std::add_const_t<Component> *...>{try_get<Component>()...};</div><div class="line"><a name="l00212"></a><span class="lineno"> 212</span>  }</div><div class="line"><a name="l00213"></a><span class="lineno"> 213</span>  }</div><div class="line"><a name="l00214"></a><span class="lineno"> 214</span> </div><div class="line"><a name="l00216"></a><span class="lineno"> 216</span>  <span class="keyword">template</span><<span class="keyword">typename</span>... Component></div><div class="line"><a name="l00217"></a><span class="lineno"><a class="line" href="classentt_1_1basic__prototype.html#a59e50d3b0aabb00952322a72bdaa5c69"> 217</a></span>  <span class="keyword">auto</span> <a class="code" href="classentt_1_1basic__prototype.html#a59e50d3b0aabb00952322a72bdaa5c69">try_get</a>() ENTT_NOEXCEPT {</div><div class="line"><a name="l00218"></a><span class="lineno"> 218</span>  <span class="keywordflow">if</span> constexpr(<span class="keyword">sizeof</span>...(Component) == 1) {</div><div class="line"><a name="l00219"></a><span class="lineno"> 219</span>  <span class="keywordflow">return</span> (const_cast<Component *>(std::as_const(*this).template try_get<Component>()), ...);</div><div class="line"><a name="l00220"></a><span class="lineno"> 220</span>  } <span class="keywordflow">else</span> {</div><div class="line"><a name="l00221"></a><span class="lineno"> 221</span>  <span class="keywordflow">return</span> std::tuple<Component *...>{try_get<Component>()...};</div><div class="line"><a name="l00222"></a><span class="lineno"> 222</span>  }</div><div class="line"><a name="l00223"></a><span class="lineno"> 223</span>  }</div><div class="line"><a name="l00224"></a><span class="lineno"> 224</span> </div><div class="line"><a name="l00243"></a><span class="lineno"><a class="line" href="classentt_1_1basic__prototype.html#a6f96bf09702ed9b2d911c1d08ff5b0b1"> 243</a></span>  <a class="code" href="classentt_1_1basic__prototype.html#a0a8606dc36496d42f6188acdad4906f3">entity_type</a> <a class="code" href="classentt_1_1basic__prototype.html#a6f96bf09702ed9b2d911c1d08ff5b0b1">create</a>(<a class="code" href="classentt_1_1basic__registry.html">registry_type</a> &other)<span class="keyword"> const </span>{</div><div class="line"><a name="l00244"></a><span class="lineno"> 244</span>  <span class="keyword">const</span> <span class="keyword">auto</span> <a class="code" href="namespaceentt.html">entt</a> = other.<a class="code" href="classentt_1_1basic__registry.html#a1bb5d5d0c5af3bd98de3d902406ff372">create</a>();</div><div class="line"><a name="l00245"></a><span class="lineno"> 245</span>  <a class="code" href="classentt_1_1basic__prototype.html#a0a5c5313d46f5f52977e7fc3fe93d865">assign</a>(other, <a class="code" href="namespaceentt.html">entt</a>);</div><div class="line"><a name="l00246"></a><span class="lineno"> 246</span>  <span class="keywordflow">return</span> <a class="code" href="namespaceentt.html">entt</a>;</div><div class="line"><a name="l00247"></a><span class="lineno"> 247</span>  }</div><div class="line"><a name="l00248"></a><span class="lineno"> 248</span> </div><div class="line"><a name="l00266"></a><span class="lineno"><a class="line" href="classentt_1_1basic__prototype.html#adb90842d165a76693de962f2cb7444e4"> 266</a></span>  <a class="code" href="classentt_1_1basic__prototype.html#a0a8606dc36496d42f6188acdad4906f3">entity_type</a> <a class="code" href="classentt_1_1basic__prototype.html#adb90842d165a76693de962f2cb7444e4">create</a>()<span class="keyword"> const </span>{</div><div class="line"><a name="l00267"></a><span class="lineno"> 267</span>  <span class="keywordflow">return</span> <a class="code" href="classentt_1_1basic__prototype.html#adb90842d165a76693de962f2cb7444e4">create</a>(*reg);</div><div class="line"><a name="l00268"></a><span class="lineno"> 268</span>  }</div><div class="line"><a name="l00269"></a><span class="lineno"> 269</span> </div><div class="line"><a name="l00291"></a><span class="lineno"><a class="line" href="classentt_1_1basic__prototype.html#a0a5c5313d46f5f52977e7fc3fe93d865"> 291</a></span>  <span class="keywordtype">void</span> <a class="code" href="classentt_1_1basic__prototype.html#a0a5c5313d46f5f52977e7fc3fe93d865">assign</a>(<a class="code" href="classentt_1_1basic__registry.html">registry_type</a> &other, <span class="keyword">const</span> <a class="code" href="classentt_1_1basic__prototype.html#a0a8606dc36496d42f6188acdad4906f3">entity_type</a> dst)<span class="keyword"> const </span>{</div><div class="line"><a name="l00292"></a><span class="lineno"> 292</span>  <span class="keywordflow">for</span>(<span class="keyword">auto</span> &handler: handlers) {</div><div class="line"><a name="l00293"></a><span class="lineno"> 293</span>  handler.second.assign(*<span class="keyword">this</span>, other, dst);</div><div class="line"><a name="l00294"></a><span class="lineno"> 294</span>  }</div><div class="line"><a name="l00295"></a><span class="lineno"> 295</span>  }</div><div class="line"><a name="l00296"></a><span class="lineno"> 296</span> </div><div class="line"><a name="l00317"></a><span class="lineno"><a class="line" href="classentt_1_1basic__prototype.html#a6062b4ed6fcf6053ea748b235db47807"> 317</a></span>  <span class="keywordtype">void</span> <a class="code" href="classentt_1_1basic__prototype.html#a6062b4ed6fcf6053ea748b235db47807">assign</a>(<span class="keyword">const</span> <a class="code" href="classentt_1_1basic__prototype.html#a0a8606dc36496d42f6188acdad4906f3">entity_type</a> dst)<span class="keyword"> const </span>{</div><div class="line"><a name="l00318"></a><span class="lineno"> 318</span>  <a class="code" href="classentt_1_1basic__prototype.html#a0a5c5313d46f5f52977e7fc3fe93d865">assign</a>(*reg, dst);</div><div class="line"><a name="l00319"></a><span class="lineno"> 319</span>  }</div><div class="line"><a name="l00320"></a><span class="lineno"> 320</span> </div><div class="line"><a name="l00340"></a><span class="lineno"><a class="line" href="classentt_1_1basic__prototype.html#ad8cc32084b579a727669e8f0e7b600a9"> 340</a></span>  <span class="keywordtype">void</span> <a class="code" href="classentt_1_1basic__prototype.html#ad8cc32084b579a727669e8f0e7b600a9">assign_or_replace</a>(<a class="code" href="classentt_1_1basic__registry.html">registry_type</a> &other, <span class="keyword">const</span> <a class="code" href="classentt_1_1basic__prototype.html#a0a8606dc36496d42f6188acdad4906f3">entity_type</a> dst)<span class="keyword"> const </span>{</div><div class="line"><a name="l00341"></a><span class="lineno"> 341</span>  <span class="keywordflow">for</span>(<span class="keyword">auto</span> &handler: handlers) {</div><div class="line"><a name="l00342"></a><span class="lineno"> 342</span>  handler.second.assign_or_replace(*<span class="keyword">this</span>, other, dst);</div><div class="line"><a name="l00343"></a><span class="lineno"> 343</span>  }</div><div class="line"><a name="l00344"></a><span class="lineno"> 344</span>  }</div><div class="line"><a name="l00345"></a><span class="lineno"> 345</span> </div><div class="line"><a name="l00364"></a><span class="lineno"><a class="line" href="classentt_1_1basic__prototype.html#a2884b160480a2e26acefd0d47316c26d"> 364</a></span>  <span class="keywordtype">void</span> <a class="code" href="classentt_1_1basic__prototype.html#a2884b160480a2e26acefd0d47316c26d">assign_or_replace</a>(<span class="keyword">const</span> <a class="code" href="classentt_1_1basic__prototype.html#a0a8606dc36496d42f6188acdad4906f3">entity_type</a> dst)<span class="keyword"> const </span>{</div><div class="line"><a name="l00365"></a><span class="lineno"> 365</span>  <a class="code" href="classentt_1_1basic__prototype.html#ad8cc32084b579a727669e8f0e7b600a9">assign_or_replace</a>(*reg, dst);</div><div class="line"><a name="l00366"></a><span class="lineno"> 366</span>  }</div><div class="line"><a name="l00367"></a><span class="lineno"> 367</span> </div><div class="line"><a name="l00389"></a><span class="lineno"><a class="line" href="classentt_1_1basic__prototype.html#a463e0d4a93ce396a069bd181c59ba6e2"> 389</a></span>  <span class="keywordtype">void</span> <a class="code" href="classentt_1_1basic__prototype.html#a463e0d4a93ce396a069bd181c59ba6e2">operator()</a>(<a class="code" href="classentt_1_1basic__registry.html">registry_type</a> &other, <span class="keyword">const</span> <a class="code" href="classentt_1_1basic__prototype.html#a0a8606dc36496d42f6188acdad4906f3">entity_type</a> dst) <span class="keyword">const</span> ENTT_NOEXCEPT {</div><div class="line"><a name="l00390"></a><span class="lineno"> 390</span>  <a class="code" href="classentt_1_1basic__prototype.html#a0a5c5313d46f5f52977e7fc3fe93d865">assign</a>(other, dst);</div><div class="line"><a name="l00391"></a><span class="lineno"> 391</span>  }</div><div class="line"><a name="l00392"></a><span class="lineno"> 392</span> </div><div class="line"><a name="l00413"></a><span class="lineno"><a class="line" href="classentt_1_1basic__prototype.html#a081d19f1dbb870c85f2bb215422700c1"> 413</a></span>  <span class="keywordtype">void</span> <a class="code" href="classentt_1_1basic__prototype.html#a081d19f1dbb870c85f2bb215422700c1">operator()</a>(<span class="keyword">const</span> <a class="code" href="classentt_1_1basic__prototype.html#a0a8606dc36496d42f6188acdad4906f3">entity_type</a> dst) <span class="keyword">const</span> ENTT_NOEXCEPT {</div><div class="line"><a name="l00414"></a><span class="lineno"> 414</span>  <a class="code" href="classentt_1_1basic__prototype.html#a0a5c5313d46f5f52977e7fc3fe93d865">assign</a>(*reg, dst);</div><div class="line"><a name="l00415"></a><span class="lineno"> 415</span>  }</div><div class="line"><a name="l00416"></a><span class="lineno"> 416</span> </div><div class="line"><a name="l00435"></a><span class="lineno"><a class="line" href="classentt_1_1basic__prototype.html#a8e47d98dbba3929f3edfe682975db846"> 435</a></span>  <a class="code" href="classentt_1_1basic__prototype.html#a0a8606dc36496d42f6188acdad4906f3">entity_type</a> <a class="code" href="classentt_1_1basic__prototype.html#a8e47d98dbba3929f3edfe682975db846">operator()</a>(<a class="code" href="classentt_1_1basic__registry.html">registry_type</a> &other) <span class="keyword">const</span> ENTT_NOEXCEPT {</div><div class="line"><a name="l00436"></a><span class="lineno"> 436</span>  <span class="keywordflow">return</span> <a class="code" href="classentt_1_1basic__prototype.html#adb90842d165a76693de962f2cb7444e4">create</a>(other);</div><div class="line"><a name="l00437"></a><span class="lineno"> 437</span>  }</div><div class="line"><a name="l00438"></a><span class="lineno"> 438</span> </div><div class="line"><a name="l00456"></a><span class="lineno"><a class="line" href="classentt_1_1basic__prototype.html#afa55befc754adbf67d25ebae7aed6a75"> 456</a></span>  <a class="code" href="classentt_1_1basic__prototype.html#a0a8606dc36496d42f6188acdad4906f3">entity_type</a> <a class="code" href="classentt_1_1basic__prototype.html#afa55befc754adbf67d25ebae7aed6a75">operator()</a>() const ENTT_NOEXCEPT {</div><div class="line"><a name="l00457"></a><span class="lineno"> 457</span>  <span class="keywordflow">return</span> <a class="code" href="classentt_1_1basic__prototype.html#adb90842d165a76693de962f2cb7444e4">create</a>(*reg);</div><div class="line"><a name="l00458"></a><span class="lineno"> 458</span>  }</div><div class="line"><a name="l00459"></a><span class="lineno"> 459</span> </div><div class="line"><a name="l00464"></a><span class="lineno"><a class="line" href="classentt_1_1basic__prototype.html#a3eca09d9203b3ad97d6663e0bf5bb2f8"> 464</a></span>  <span class="keyword">const</span> <a class="code" href="classentt_1_1basic__registry.html">registry_type</a> & <a class="code" href="classentt_1_1basic__prototype.html#a3eca09d9203b3ad97d6663e0bf5bb2f8">backend</a>() const ENTT_NOEXCEPT {</div><div class="line"><a name="l00465"></a><span class="lineno"> 465</span>  <span class="keywordflow">return</span> *reg;</div><div class="line"><a name="l00466"></a><span class="lineno"> 466</span>  }</div><div class="line"><a name="l00467"></a><span class="lineno"> 467</span> </div><div class="line"><a name="l00469"></a><span class="lineno"><a class="line" href="classentt_1_1basic__prototype.html#ac6cdd27694a8e9e2bdb576ffca098e1b"> 469</a></span>  <a class="code" href="classentt_1_1basic__registry.html">registry_type</a> & <a class="code" href="classentt_1_1basic__prototype.html#ac6cdd27694a8e9e2bdb576ffca098e1b">backend</a>() ENTT_NOEXCEPT {</div><div class="line"><a name="l00470"></a><span class="lineno"> 470</span>  <span class="keywordflow">return</span> <span class="keyword">const_cast<</span><a class="code" href="classentt_1_1basic__registry.html">registry_type</a> &<span class="keyword">></span>(std::as_const(*this).backend());</div><div class="line"><a name="l00471"></a><span class="lineno"> 471</span>  }</div><div class="line"><a name="l00472"></a><span class="lineno"> 472</span> </div><div class="line"><a name="l00473"></a><span class="lineno"> 473</span> <span class="keyword">private</span>:</div><div class="line"><a name="l00474"></a><span class="lineno"> 474</span>  std::unordered_map<component_type, component_handler> handlers;</div><div class="line"><a name="l00475"></a><span class="lineno"> 475</span>  <a class="code" href="classentt_1_1basic__registry.html">registry_type</a> *reg;</div><div class="line"><a name="l00476"></a><span class="lineno"> 476</span>  <a class="code" href="classentt_1_1basic__prototype.html#a0a8606dc36496d42f6188acdad4906f3">entity_type</a> entity;</div><div class="line"><a name="l00477"></a><span class="lineno"> 477</span> };</div><div class="line"><a name="l00478"></a><span class="lineno"> 478</span> </div><div class="line"><a name="l00479"></a><span class="lineno"> 479</span> </div><div class="line"><a name="l00480"></a><span class="lineno"> 480</span> }</div><div class="line"><a name="l00481"></a><span class="lineno"> 481</span> </div><div class="line"><a name="l00482"></a><span class="lineno"> 482</span> </div><div class="line"><a name="l00483"></a><span class="lineno"> 483</span> <span class="preprocessor">#endif // ENTT_ENTITY_PROTOTYPE_HPP</span></div><div class="ttc" id="classentt_1_1basic__prototype_html_a1592ff421e77a624830cb965c6f52110"><div class="ttname"><a href="classentt_1_1basic__prototype.html#a1592ff421e77a624830cb965c6f52110">entt::basic_prototype::basic_prototype</a></div><div class="ttdeci">basic_prototype(basic_prototype &&other)</div><div class="ttdoc">Move constructor. </div><div class="ttdef"><b>Definition:</b> <a href="prototype_8hpp_source.html#l00092">prototype.hpp:92</a></div></div>
|
|
<div class="ttc" id="classentt_1_1basic__prototype_html_a2884b160480a2e26acefd0d47316c26d"><div class="ttname"><a href="classentt_1_1basic__prototype.html#a2884b160480a2e26acefd0d47316c26d">entt::basic_prototype::assign_or_replace</a></div><div class="ttdeci">void assign_or_replace(const entity_type dst) const</div><div class="ttdoc">Assigns or replaces the components of a prototype for an entity. </div><div class="ttdef"><b>Definition:</b> <a href="prototype_8hpp_source.html#l00364">prototype.hpp:364</a></div></div>
|
|
<div class="ttc" id="classentt_1_1basic__prototype_html_a6f96bf09702ed9b2d911c1d08ff5b0b1"><div class="ttname"><a href="classentt_1_1basic__prototype.html#a6f96bf09702ed9b2d911c1d08ff5b0b1">entt::basic_prototype::create</a></div><div class="ttdeci">entity_type create(registry_type &other) const</div><div class="ttdoc">Creates a new entity using a given prototype. </div><div class="ttdef"><b>Definition:</b> <a href="prototype_8hpp_source.html#l00243">prototype.hpp:243</a></div></div>
|
|
<div class="ttc" id="classentt_1_1basic__prototype_html_a0a8606dc36496d42f6188acdad4906f3"><div class="ttname"><a href="classentt_1_1basic__prototype.html#a0a8606dc36496d42f6188acdad4906f3">entt::basic_prototype::entity_type</a></div><div class="ttdeci">Entity entity_type</div><div class="ttdoc">Underlying entity identifier. </div><div class="ttdef"><b>Definition:</b> <a href="prototype_8hpp_source.html#l00063">prototype.hpp:63</a></div></div>
|
|
<div class="ttc" id="classentt_1_1basic__prototype_html_a01d3afe0260e80974f24c1d36b5fbccc"><div class="ttname"><a href="classentt_1_1basic__prototype.html#a01d3afe0260e80974f24c1d36b5fbccc">entt::basic_prototype::size_type</a></div><div class="ttdeci">std::size_t size_type</div><div class="ttdoc">Unsigned integer type. </div><div class="ttdef"><b>Definition:</b> <a href="prototype_8hpp_source.html#l00065">prototype.hpp:65</a></div></div>
|
|
<div class="ttc" id="namespaceentt_html"><div class="ttname"><a href="namespaceentt.html">entt</a></div><div class="ttdoc">EnTT default namespace. </div><div class="ttdef"><b>Definition:</b> <a href="algorithm_8hpp_source.html#l00010">algorithm.hpp:10</a></div></div>
|
|
<div class="ttc" id="classentt_1_1basic__prototype_html_a1181e970dc90a33b823210d33af819d5"><div class="ttname"><a href="classentt_1_1basic__prototype.html#a1181e970dc90a33b823210d33af819d5">entt::basic_prototype::~basic_prototype</a></div><div class="ttdeci">~basic_prototype()</div><div class="ttdoc">Releases all its resources. </div><div class="ttdef"><b>Definition:</b> <a href="prototype_8hpp_source.html#l00079">prototype.hpp:79</a></div></div>
|
|
<div class="ttc" id="classentt_1_1basic__prototype_html_a081d19f1dbb870c85f2bb215422700c1"><div class="ttname"><a href="classentt_1_1basic__prototype.html#a081d19f1dbb870c85f2bb215422700c1">entt::basic_prototype::operator()</a></div><div class="ttdeci">void operator()(const entity_type dst) const ENTT_NOEXCEPT</div><div class="ttdoc">Assigns the components of a prototype to an entity. </div><div class="ttdef"><b>Definition:</b> <a href="prototype_8hpp_source.html#l00413">prototype.hpp:413</a></div></div>
|
|
<div class="ttc" id="classentt_1_1basic__registry_html_a1bb5d5d0c5af3bd98de3d902406ff372"><div class="ttname"><a href="classentt_1_1basic__registry.html#a1bb5d5d0c5af3bd98de3d902406ff372">entt::basic_registry::create</a></div><div class="ttdeci">decltype(auto) create()</div><div class="ttdoc">Creates a new entity and returns it. </div><div class="ttdef"><b>Definition:</b> <a href="registry_8hpp_source.html#l00559">registry.hpp:559</a></div></div>
|
|
<div class="ttc" id="classentt_1_1basic__prototype_html_a6062b4ed6fcf6053ea748b235db47807"><div class="ttname"><a href="classentt_1_1basic__prototype.html#a6062b4ed6fcf6053ea748b235db47807">entt::basic_prototype::assign</a></div><div class="ttdeci">void assign(const entity_type dst) const</div><div class="ttdoc">Assigns the components of a prototype to a given entity. </div><div class="ttdef"><b>Definition:</b> <a href="prototype_8hpp_source.html#l00317">prototype.hpp:317</a></div></div>
|
|
<div class="ttc" id="classentt_1_1basic__prototype_html_acffae325962a54170176025d67d38a80"><div class="ttname"><a href="classentt_1_1basic__prototype.html#acffae325962a54170176025d67d38a80">entt::basic_prototype::basic_prototype</a></div><div class="ttdeci">basic_prototype(registry_type &ref)</div><div class="ttdoc">Constructs a prototype that is bound to a given registry. </div><div class="ttdef"><b>Definition:</b> <a href="prototype_8hpp_source.html#l00071">prototype.hpp:71</a></div></div>
|
|
<div class="ttc" id="classentt_1_1basic__prototype_html_a463e0d4a93ce396a069bd181c59ba6e2"><div class="ttname"><a href="classentt_1_1basic__prototype.html#a463e0d4a93ce396a069bd181c59ba6e2">entt::basic_prototype::operator()</a></div><div class="ttdeci">void operator()(registry_type &other, const entity_type dst) const ENTT_NOEXCEPT</div><div class="ttdoc">Assigns the components of a prototype to an entity. </div><div class="ttdef"><b>Definition:</b> <a href="prototype_8hpp_source.html#l00389">prototype.hpp:389</a></div></div>
|
|
<div class="ttc" id="classentt_1_1basic__prototype_html_adb90842d165a76693de962f2cb7444e4"><div class="ttname"><a href="classentt_1_1basic__prototype.html#adb90842d165a76693de962f2cb7444e4">entt::basic_prototype::create</a></div><div class="ttdeci">entity_type create() const</div><div class="ttdoc">Creates a new entity using a given prototype. </div><div class="ttdef"><b>Definition:</b> <a href="prototype_8hpp_source.html#l00266">prototype.hpp:266</a></div></div>
|
|
<div class="ttc" id="namespaceentt_html_a588326af8f6f902a6c0b57d3f9fc6c17"><div class="ttname"><a href="namespaceentt.html#a588326af8f6f902a6c0b57d3f9fc6c17">entt::null</a></div><div class="ttdeci">constexpr auto null</div><div class="ttdoc">Null entity. </div><div class="ttdef"><b>Definition:</b> <a href="entity_8hpp_source.html#l00165">entity.hpp:165</a></div></div>
|
|
<div class="ttc" id="classentt_1_1basic__prototype_html_afa55befc754adbf67d25ebae7aed6a75"><div class="ttname"><a href="classentt_1_1basic__prototype.html#afa55befc754adbf67d25ebae7aed6a75">entt::basic_prototype::operator()</a></div><div class="ttdeci">entity_type operator()() const ENTT_NOEXCEPT</div><div class="ttdoc">Creates a new entity using a given prototype. </div><div class="ttdef"><b>Definition:</b> <a href="prototype_8hpp_source.html#l00456">prototype.hpp:456</a></div></div>
|
|
<div class="ttc" id="classentt_1_1basic__registry_html_ace85f74fac787b967100f4186860f226"><div class="ttname"><a href="classentt_1_1basic__registry.html#ace85f74fac787b967100f4186860f226">entt::basic_registry::component_type</a></div><div class="ttdeci">ENTT_ID_TYPE component_type</div><div class="ttdoc">Unsigned integer type. </div><div class="ttdef"><b>Definition:</b> <a href="registry_8hpp_source.html#l00312">registry.hpp:312</a></div></div>
|
|
<div class="ttc" id="classentt_1_1basic__registry_html"><div class="ttname"><a href="classentt_1_1basic__registry.html">entt::basic_registry</a></div><div class="ttdoc">Fast and reliable entity-component system. </div><div class="ttdef"><b>Definition:</b> <a href="entity_2fwd_8hpp_source.html#l00014">fwd.hpp:14</a></div></div>
|
|
<div class="ttc" id="classentt_1_1basic__prototype_html_a59e50d3b0aabb00952322a72bdaa5c69"><div class="ttname"><a href="classentt_1_1basic__prototype.html#a59e50d3b0aabb00952322a72bdaa5c69">entt::basic_prototype::try_get</a></div><div class="ttdeci">auto try_get() ENTT_NOEXCEPT</div><div class="ttdoc">Returns pointers to the given components. </div><div class="ttdef"><b>Definition:</b> <a href="prototype_8hpp_source.html#l00217">prototype.hpp:217</a></div></div>
|
|
<div class="ttc" id="classentt_1_1basic__prototype_html_a05230038ddbafaca4d5da09dfb247186"><div class="ttname"><a href="classentt_1_1basic__prototype.html#a05230038ddbafaca4d5da09dfb247186">entt::basic_prototype::unset</a></div><div class="ttdeci">void unset() ENTT_NOEXCEPT</div><div class="ttdoc">Removes the given component from a prototype. </div><div class="ttdef"><b>Definition:</b> <a href="prototype_8hpp_source.html#l00154">prototype.hpp:154</a></div></div>
|
|
<div class="ttc" id="classentt_1_1basic__prototype_html_ad8cc32084b579a727669e8f0e7b600a9"><div class="ttname"><a href="classentt_1_1basic__prototype.html#ad8cc32084b579a727669e8f0e7b600a9">entt::basic_prototype::assign_or_replace</a></div><div class="ttdeci">void assign_or_replace(registry_type &other, const entity_type dst) const</div><div class="ttdoc">Assigns or replaces the components of a prototype for an entity. </div><div class="ttdef"><b>Definition:</b> <a href="prototype_8hpp_source.html#l00340">prototype.hpp:340</a></div></div>
|
|
<div class="ttc" id="classentt_1_1basic__prototype_html_a0a5c5313d46f5f52977e7fc3fe93d865"><div class="ttname"><a href="classentt_1_1basic__prototype.html#a0a5c5313d46f5f52977e7fc3fe93d865">entt::basic_prototype::assign</a></div><div class="ttdeci">void assign(registry_type &other, const entity_type dst) const</div><div class="ttdoc">Assigns the components of a prototype to a given entity. </div><div class="ttdef"><b>Definition:</b> <a href="prototype_8hpp_source.html#l00291">prototype.hpp:291</a></div></div>
|
|
<div class="ttc" id="classentt_1_1basic__prototype_html"><div class="ttname"><a href="classentt_1_1basic__prototype.html">entt::basic_prototype</a></div><div class="ttdoc">Prototype container for concepts. </div><div class="ttdef"><b>Definition:</b> <a href="entity_2fwd_8hpp_source.html#l00038">fwd.hpp:38</a></div></div>
|
|
<div class="ttc" id="classentt_1_1basic__prototype_html_a3eca09d9203b3ad97d6663e0bf5bb2f8"><div class="ttname"><a href="classentt_1_1basic__prototype.html#a3eca09d9203b3ad97d6663e0bf5bb2f8">entt::basic_prototype::backend</a></div><div class="ttdeci">const registry_type & backend() const ENTT_NOEXCEPT</div><div class="ttdoc">Returns a reference to the underlying registry. </div><div class="ttdef"><b>Definition:</b> <a href="prototype_8hpp_source.html#l00464">prototype.hpp:464</a></div></div>
|
|
<div class="ttc" id="classentt_1_1basic__prototype_html_ac6cdd27694a8e9e2bdb576ffca098e1b"><div class="ttname"><a href="classentt_1_1basic__prototype.html#ac6cdd27694a8e9e2bdb576ffca098e1b">entt::basic_prototype::backend</a></div><div class="ttdeci">registry_type & backend() ENTT_NOEXCEPT</div><div class="ttdoc">Returns a reference to the underlying registry. </div><div class="ttdef"><b>Definition:</b> <a href="prototype_8hpp_source.html#l00469">prototype.hpp:469</a></div></div>
|
|
<div class="ttc" id="classentt_1_1basic__prototype_html_a8e47d98dbba3929f3edfe682975db846"><div class="ttname"><a href="classentt_1_1basic__prototype.html#a8e47d98dbba3929f3edfe682975db846">entt::basic_prototype::operator()</a></div><div class="ttdeci">entity_type operator()(registry_type &other) const ENTT_NOEXCEPT</div><div class="ttdoc">Creates a new entity using a given prototype. </div><div class="ttdef"><b>Definition:</b> <a href="prototype_8hpp_source.html#l00435">prototype.hpp:435</a></div></div>
|
|
<div class="ttc" id="classentt_1_1basic__prototype_html_ac030e38aaa91c32530493a97a64fe1af"><div class="ttname"><a href="classentt_1_1basic__prototype.html#ac030e38aaa91c32530493a97a64fe1af">entt::basic_prototype::get</a></div><div class="ttdeci">decltype(auto) get() const ENTT_NOEXCEPT</div><div class="ttdoc">Returns references to the given components. </div><div class="ttdef"><b>Definition:</b> <a href="prototype_8hpp_source.html#l00182">prototype.hpp:182</a></div></div>
|
|
<div class="ttc" id="classentt_1_1basic__prototype_html_a26c239c2d51cda5c0f5ff398d6a67f8c"><div class="ttname"><a href="classentt_1_1basic__prototype.html#a26c239c2d51cda5c0f5ff398d6a67f8c">entt::basic_prototype::try_get</a></div><div class="ttdeci">auto try_get() const ENTT_NOEXCEPT</div><div class="ttdoc">Returns pointers to the given components. </div><div class="ttdef"><b>Definition:</b> <a href="prototype_8hpp_source.html#l00206">prototype.hpp:206</a></div></div>
|
|
<div class="ttc" id="classentt_1_1basic__prototype_html_a6d4f9ce06a07f9b40ec714b13428326c"><div class="ttname"><a href="classentt_1_1basic__prototype.html#a6d4f9ce06a07f9b40ec714b13428326c">entt::basic_prototype::has</a></div><div class="ttdeci">bool has() const ENTT_NOEXCEPT</div><div class="ttdoc">Checks if a prototype owns all the given components. </div><div class="ttdef"><b>Definition:</b> <a href="prototype_8hpp_source.html#l00165">prototype.hpp:165</a></div></div>
|
|
<div class="ttc" id="classentt_1_1basic__prototype_html_a24a5c455ba9368897c959f722496fa54"><div class="ttname"><a href="classentt_1_1basic__prototype.html#a24a5c455ba9368897c959f722496fa54">entt::basic_prototype::operator=</a></div><div class="ttdeci">basic_prototype & operator=(basic_prototype &&other)</div><div class="ttdoc">Move assignment operator. </div><div class="ttdef"><b>Definition:</b> <a href="prototype_8hpp_source.html#l00110">prototype.hpp:110</a></div></div>
|
|
</div><!-- fragment --></div><!-- contents -->
|
|
<!-- start footer part -->
|
|
<hr class="footer"/><address class="footer"><small>
|
|
Generated by  <a href="http://www.doxygen.org/index.html">
|
|
<img class="footer" src="doxygen.png" alt="doxygen"/>
|
|
</a> 1.8.13
|
|
</small></address>
|
|
</body>
|
|
</html>
|