diff --git a/README_8md_source.html b/README_8md_source.html index 4acb6f77b..6a25fdc61 100644 --- a/README_8md_source.html +++ b/README_8md_source.html @@ -22,7 +22,7 @@
| begin() const noexcept | entt::PersistentView< Entity, Component > | inline | |||
| data() const noexcept | entt::PersistentView< Entity, Component > | inline | |||
| each(Func &&func) | entt::PersistentView< Entity, Component > | inline | |||
| each(Func &&func) const | entt::PersistentView< Entity, Component > | inline | |||
| each(Func func) const | entt::PersistentView< Entity, Component > | inline | |||
| each(Func func) | entt::PersistentView< Entity, Component > | inline | |||
| end() const noexcept | entt::PersistentView< Entity, Component > | inline | |||
| entity_type typedef | entt::PersistentView< Entity, Component > | ||||
| get(entity_type entity) const noexcept | entt::PersistentView< Entity, Component > | inline | |||
|
entt
- 2.2.0
+ 2.3.0
|
|||||
| Comp & | get (entity_type entity) noexcept | ||||
| Returns the component assigned to the given entity. More... | |||||
| template<typename Func > | |||||
| void | each (Func &&func) | ||||
| Iterate the entities and applies them the given function object. More... | |||||
| template<typename Func > | |||||
| void | each (Func &&func) const | ||||
| Iterate the entities and applies them the given function object. More... | |||||
| template<typename Func > | |||||
| void | each (Func func) const | ||||
| Iterate the entities and applies them the given function object. More... | |||||
| template<typename Func > | |||||
| void | each (Func func) | ||||
| Iterate the entities and applies them the given function object. More... | |||||
| template<typename Comp > | |||||
| void | sort () | ||||
| Sort the shared pool of entities according to the given component. More... | |||||
| void entt::PersistentView< Entity, Component >::each | ( | -Func && | -func | ) | -- |
Iterate the entities and applies them the given function object.
-The function object is invoked for each entity. It is provided with the entity itself and a set of references to all the components of the view.
- The signature of the function should be equivalent to the following:
| Func | Type of the function object to invoke. |
| func | A valid function object. |
-
+
+
Iterate the entities and applies them the given function object. +The function object is invoked for each entity. It is provided with the entity itself and a set of references to all the components of the view. void(entity_type, Component &...);
Definition at line 142 of file view.hpp. +Definition at line 143 of file view.hpp. @@ -477,7 +477,7 @@ template<typename Comp >
Definition at line 164 of file view.hpp. +Definition at line 165 of file view.hpp. @@ -527,7 +527,7 @@ template<typename Comp >
Definition at line 186 of file view.hpp. +Definition at line 187 of file view.hpp. @@ -559,7 +559,7 @@ template<typename Entity , typename... Component>Returns the number of entities that have the given components.
Definition at line 89 of file view.hpp. +Definition at line 90 of file view.hpp. @@ -600,7 +600,7 @@ template<typename Comp > -Definition at line 251 of file view.hpp. +Definition at line 252 of file view.hpp. diff --git a/classentt_1_1Process-members.html b/classentt_1_1Process-members.html index ed3c7006e..917bcff91 100644 --- a/classentt_1_1Process-members.html +++ b/classentt_1_1Process-members.html @@ -22,7 +22,7 @@
|
entt
- 2.2.0
+ 2.3.0
|
entt
- 2.2.0
+ 2.3.0
|
entt
- 2.2.0
+ 2.3.0
attach(entity_type entity, Args &&... args) | entt::Registry< Entity > | inline | attachee() const noexcept | entt::Registry< Entity > | inline | capacity() const noexcept | entt::Registry< Entity > | inline | component() const noexcept | entt::Registry< Entity > | inline | component_type typedef | entt::Registry< Entity > | contains() const noexcept | entt::Registry< Entity > | inline | create(Component &&... components) noexcept | entt::Registry< Entity > | inline | create() noexcept | entt::Registry< Entity > | inline | current(entity_type entity) const noexcept | entt::Registry< Entity > | inline | destroy(entity_type entity) | entt::Registry< Entity > | inline | discard() | entt::Registry< Entity > | inline | empty() const noexcept | entt::Registry< Entity > | inline | empty() const noexcept | entt::Registry< Entity > | inline | entity_type typedef | entt::Registry< Entity > | get() const noexcept | entt::Registry< Entity > | inline | get() noexcept | entt::Registry< Entity > | inline | get(entity_type entity) const noexcept | entt::Registry< Entity > | inline | get(entity_type entity) noexcept | entt::Registry< Entity > | inline | has() const noexcept | entt::Registry< Entity > | inline | has(entity_type entity) const noexcept | entt::Registry< Entity > | inline | operator=(const Registry &)=delete | entt::Registry< Entity > | operator=(Registry &&)=default | entt::Registry< Entity > | persistent() | entt::Registry< Entity > | inline | prepare() | entt::Registry< Entity > | inline | Registry()=default | entt::Registry< Entity > | Registry(const Registry &)=delete | entt::Registry< Entity > | Registry(Registry &&)=default | entt::Registry< Entity > | remove() | entt::Registry< Entity > | inline | remove(entity_type entity) | entt::Registry< Entity > | inline | replace(entity_type entity, Args &&... args) | entt::Registry< Entity > | inline | reset(entity_type entity) | entt::Registry< Entity > | inline | reset() | entt::Registry< Entity > | inline | reset() | entt::Registry< Entity > | inline | size() const noexcept | entt::Registry< Entity > | inline | size() const noexcept | entt::Registry< Entity > | inline | size_type typedef | entt::Registry< Entity > | sort(Compare compare) | entt::Registry< Entity > | inline | sort() | entt::Registry< Entity > | inline | valid(entity_type entity) const noexcept | entt::Registry< Entity > | inline | version(entity_type entity) const noexcept | entt::Registry< Entity > | inline | version_type typedef | entt::Registry< Entity > | view() | entt::Registry< Entity > | inline | each(Func func) const | entt::Registry< Entity > | inline | empty() const noexcept | entt::Registry< Entity > | inline | empty() const noexcept | entt::Registry< Entity > | inline | entity_type typedef | entt::Registry< Entity > | get() const noexcept | entt::Registry< Entity > | inline | get() noexcept | entt::Registry< Entity > | inline | get(entity_type entity) const noexcept | entt::Registry< Entity > | inline | get(entity_type entity) noexcept | entt::Registry< Entity > | inline | has() const noexcept | entt::Registry< Entity > | inline | has(entity_type entity) const noexcept | entt::Registry< Entity > | inline | operator=(const Registry &)=delete | entt::Registry< Entity > | operator=(Registry &&)=default | entt::Registry< Entity > | persistent() | entt::Registry< Entity > | inline | prepare() | entt::Registry< Entity > | inline | Registry()=default | entt::Registry< Entity > | Registry(const Registry &)=delete | entt::Registry< Entity > | Registry(Registry &&)=default | entt::Registry< Entity > | remove() | entt::Registry< Entity > | inline | remove(entity_type entity) | entt::Registry< Entity > | inline | replace(entity_type entity, Args &&... args) | entt::Registry< Entity > | inline | reset(entity_type entity) | entt::Registry< Entity > | inline | reset() | entt::Registry< Entity > | inline | reset() | entt::Registry< Entity > | inline | size() const noexcept | entt::Registry< Entity > | inline | size() const noexcept | entt::Registry< Entity > | inline | size_type typedef | entt::Registry< Entity > | sort(Compare compare) | entt::Registry< Entity > | inline | sort() | entt::Registry< Entity > | inline | tag() const noexcept | entt::Registry< Entity > | inline | tag_type typedef | entt::Registry< Entity > | valid(entity_type entity) const noexcept | entt::Registry< Entity > | inline | version(entity_type entity) const noexcept | entt::Registry< Entity > | inline | version_type typedef | entt::Registry< Entity > | view() | entt::Registry< Entity > | inline | diff --git a/classentt_1_1Registry.html b/classentt_1_1Registry.html index c972e0d6e..afd432021 100644 --- a/classentt_1_1Registry.html +++ b/classentt_1_1Registry.html @@ -22,7 +22,7 @@
|
entt
- 2.2.0
+ 2.3.0
| size_type = std::size_t | |||||||||||||||||||||||||||||||||||||
| Unsigned integer type. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| +using | tag_type = typename tag_family::family_type | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Unsigned integer type. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| +using | component_type = typename component_family::family_type | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Unsigned integer type. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Public Member Functions | |||||||
| Registry & | operator= (Registry &&)=default | ||||||
| Default move assignment operator. More... | |||||||
| template<typename Tag > | |||||||
| tag_type | tag () const noexcept | ||||||
| Returns the numeric identifier of a type of tag at runtime. More... | |||||||
| template<typename Component > | |||||||
| component_type | component () const noexcept | ||||||
| Returns the numeric identifier of a type of component at runtime. More... | |||||||
| template<typename Component > | |||||||
| size_type | size () const noexcept | ||||||
| Returns the number of existing components of the given type. More... | |||||||
| void | reset () | ||||||
| Resets a whole registry. More... | |||||||
| template<typename Func > | |||||||
| void | each (Func func) const | ||||||
| Iterate entities and applies them the given function object. More... | |||||||
| template<typename... Component> | |||||||
| View< Entity, Component... > | view () | ||||||
| Returns a standard view for the given components. More... | |||||||
+
|
+ +inlinenoexcept | +
Returns the numeric identifier of a type of component at runtime.
+The given component doesn't need to be necessarily in use. However, the registry could decide to prepare internal data structures for it for later uses.
+ Do not use this functionality to provide numeric identifiers to types at runtime.
| Component | Type of component to query. |
Definition at line 212 of file registry.hpp.
Definition at line 913 of file registry.hpp.
+Definition at line 972 of file registry.hpp.
@@ -613,7 +675,7 @@ template<typename... Component>Definition at line 285 of file registry.hpp.
+Definition at line 327 of file registry.hpp.
@@ -660,7 +722,7 @@ template<typename... Component>Definition at line 312 of file registry.hpp.
+Definition at line 354 of file registry.hpp.
@@ -699,7 +761,7 @@ template<typename Entity>The returned entity has no components assigned.
Definition at line 337 of file registry.hpp.
+Definition at line 379 of file registry.hpp.
@@ -741,7 +803,7 @@ template<typename Entity>Definition at line 259 of file registry.hpp.
+Definition at line 299 of file registry.hpp.
@@ -782,7 +844,7 @@ template<typename Entity> -Definition at line 368 of file registry.hpp.
+Definition at line 410 of file registry.hpp.
@@ -824,7 +886,56 @@ template<typename... Component> -Definition at line 895 of file registry.hpp.
+Definition at line 954 of file registry.hpp.
+ + + + +
+
|
+ +inline | +
Iterate entities and applies them the given function object.
+The function object is invoked for each entity, no matter if it's in use or not.
+ The signature of the function should be equivalent to the following:
Consider using a view if the goal is to iterate entities that have a determinate set of components. A view is usually faster than combining this function with a bunch of custom tests.
+| Func | Type of the function object to invoke. |
| func | A valid function object. |
Definition at line 874 of file registry.hpp.
Definition at line 211 of file registry.hpp.
+Definition at line 249 of file registry.hpp.
@@ -896,7 +1007,7 @@ template<typename Entity>Checks if there exists at least an entity still in use.
Definition at line 219 of file registry.hpp.
+Definition at line 257 of file registry.hpp.
@@ -938,7 +1049,7 @@ template<typename Tag >Definition at line 460 of file registry.hpp.
+Definition at line 501 of file registry.hpp.
@@ -980,7 +1091,7 @@ template<typename Tag >Definition at line 478 of file registry.hpp.
+Definition at line 519 of file registry.hpp.
@@ -1029,7 +1140,7 @@ template<typename Component >Definition at line 583 of file registry.hpp.
+Definition at line 623 of file registry.hpp.
@@ -1078,7 +1189,7 @@ template<typename Component >Definition at line 603 of file registry.hpp.
+Definition at line 643 of file registry.hpp.
@@ -1118,7 +1229,7 @@ template<typename Tag >Definition at line 438 of file registry.hpp.
+Definition at line 479 of file registry.hpp.
@@ -1167,7 +1278,7 @@ template<typename... Component>Definition at line 558 of file registry.hpp.
+Definition at line 599 of file registry.hpp.
@@ -1285,7 +1396,7 @@ template<typename... Component>Definition at line 957 of file registry.hpp.
+Definition at line 1016 of file registry.hpp.
@@ -1327,7 +1438,7 @@ template<typename... Component> -Definition at line 875 of file registry.hpp.
+Definition at line 934 of file registry.hpp.
@@ -1366,7 +1477,7 @@ template<typename Tag > -Definition at line 426 of file registry.hpp.
+Definition at line 467 of file registry.hpp.
@@ -1414,7 +1525,7 @@ template<typename Component > -Definition at line 540 of file registry.hpp.
+Definition at line 581 of file registry.hpp.
@@ -1476,7 +1587,7 @@ template<typename Component , typename... Args>Definition at line 628 of file registry.hpp.
+Definition at line 668 of file registry.hpp.
@@ -1525,7 +1636,7 @@ template<typename Component > -Definition at line 754 of file registry.hpp.
+Definition at line 788 of file registry.hpp.
@@ -1565,7 +1676,7 @@ template<typename Component > -Definition at line 775 of file registry.hpp.
+Definition at line 809 of file registry.hpp.
@@ -1597,7 +1708,7 @@ template<typename Entity>Resets a whole registry.
Destroys all the entities. After a call to reset, all the entities previously created are recycled with a new version number. In case entity identifers are stored around, the current member function can be used to know if they are still valid.
Definition at line 795 of file registry.hpp.
+Definition at line 829 of file registry.hpp.
@@ -1637,7 +1748,7 @@ template<typename Component >Definition at line 184 of file registry.hpp.
+Definition at line 222 of file registry.hpp.
@@ -1669,7 +1780,7 @@ template<typename Entity>Returns the number of entities still in use.
Definition at line 192 of file registry.hpp.
+Definition at line 230 of file registry.hpp.
@@ -1705,8 +1816,7 @@ template<typename Component , typename Compare >The order of the elements in a pool is highly affected by assignements of components to entities and deletions. Components are arranged to maximize the performance during iterations and users should not make any assumption on the order.
This function can be used to impose an order to the elements in the pool for the given component. The order is kept valid until a component of the given type is assigned or removed from an entity.
The comparison function object must return true if the first element is less than the second one, false otherwise. The signature of the comparison function should be equivalent to the following:
Where e1 and e2 are valid entity identifiers.
| Component | Type of components to sort. | |||||
| Compare | Type of comparison function object. |
+
|
+ +inlinenoexcept | +
Returns the numeric identifier of a type of tag at runtime.
+The given tag doesn't need to be necessarily in use. However, the registry could decide to prepare internal data structures for it for later uses.
+ Do not use this functionality to provide numeric identifiers to types at runtime.
| Tag | Type of tag to query. |
Definition at line 195 of file registry.hpp.
Definition at line 228 of file registry.hpp.
+Definition at line 266 of file registry.hpp.
@@ -1847,7 +1999,7 @@ template<typename Entity>Definition at line 238 of file registry.hpp.
+Definition at line 278 of file registry.hpp.
@@ -1902,7 +2054,7 @@ template<typename... Component>Definition at line 854 of file registry.hpp.
+Definition at line 913 of file registry.hpp.
diff --git a/classentt_1_1ResourceCache-members.html b/classentt_1_1ResourceCache-members.html index 3320c092b..e19654b94 100644 --- a/classentt_1_1ResourceCache-members.html +++ b/classentt_1_1ResourceCache-members.html @@ -22,7 +22,7 @@Sparse set.
Primary template isn't defined on purpose. All the specializations give a compile-time error, but for a few reasonable cases.
-Definition at line 23 of file sparse_set.hpp.
+Definition at line 25 of file sparse_set.hpp.
Definition at line 410 of file sparse_set.hpp.
+Definition at line 375 of file sparse_set.hpp.
Definition at line 523 of file sparse_set.hpp.
+Definition at line 488 of file sparse_set.hpp.
Reimplemented from entt::SparseSet< Entity >.
-Definition at line 541 of file sparse_set.hpp.
+Definition at line 506 of file sparse_set.hpp.
@@ -393,7 +393,7 @@ template<typename Entity , typename Type >Definition at line 488 of file sparse_set.hpp.
+Definition at line 453 of file sparse_set.hpp.
@@ -434,7 +434,7 @@ template<typename Entity , typename Type >Definition at line 504 of file sparse_set.hpp.
+Definition at line 469 of file sparse_set.hpp.
@@ -530,7 +530,7 @@ template<typename Entity , typename Type >sort has been previously invoked. Internal data structures arrange elements to maximize performance. Accessing them directly gives a performance boost but less guarantees. Use begin and end if you want to iterate the sparse set in the expected order.Definition at line 453 of file sparse_set.hpp.
+Definition at line 418 of file sparse_set.hpp.
@@ -564,12 +564,12 @@ template<typename Entity , typename Type >sort has been previously invoked. Internal data structures arrange elements to maximize performance. Accessing them directly gives a performance boost but less guarantees. Use begin and end if you want to iterate the sparse set in the expected order.Definition at line 472 of file sparse_set.hpp.
+Definition at line 437 of file sparse_set.hpp.
- -| void entt::SparseSet< Entity, Type >::swap | +void entt::SparseSet< Entity, Type >::respect | ( | -entity_type | -lhs, | -||
| + | const SparseSet< Entity > & | +other | ) | - | entity_type | -rhs | -
| - | ) | -
Swaps two entities and their objects.
-Sort components according to the order of the entities in another sparse set.
+Entities that are part of both the sparse sets are ordered internally according to the order they have in other. All the other entities goes to the end of the list and there are no guarantess on their order. Components are sorted according to the entities to which they belong.
+ In other terms, this function can be used to impose the same order on two sets by using one of them as a master and the other one as a slave.
Iterating the sparse set with a couple of iterators returns elements in the expected order after a call to sort. See begin and end for more details.
data gives no guarantees on the order, even though sort has been invoked.| lhs | A valid entity identifier. |
| rhs | A valid entity identifier. |
| other | The sparse sets that imposes the order of the entities. |
Reimplemented from entt::SparseSet< Entity >.
+Reimplemented from entt::SparseSet< Entity >.
-Definition at line 564 of file sparse_set.hpp.
+Definition at line 582 of file sparse_set.hpp.
+ +
+
|
+ +inline | +
Sort components according to the given comparison function.
+Sort the elements so that iterating the sparse set with a couple of iterators returns them in the expected order. See begin and end for more details.
The comparison function object must return true if the first element is less than the second one, false otherwise. The signature of the comparison function should be equivalent to the following:
data gives no guarantees on the order, even though sort has been invoked.| Compare | Type of comparison function object. |
| compare | A valid comparison function object. |
Definition at line 536 of file sparse_set.hpp.
Definition at line 54 of file sparse_set.hpp.
+Definition at line 56 of file sparse_set.hpp.
sort.Definition at line 171 of file sparse_set.hpp.
+Definition at line 173 of file sparse_set.hpp.
@@ -262,7 +258,7 @@ template<typename Entity > -Definition at line 233 of file sparse_set.hpp.
+Definition at line 237 of file sparse_set.hpp.
@@ -296,7 +292,7 @@ template<typename Entity >sort has been previously invoked. Internal data structures arrange elements to maximize performance. Accessing them directly gives a performance boost but less guarantees. Use begin and end if you want to iterate the sparse set in the expected order.Definition at line 155 of file sparse_set.hpp.
+Definition at line 157 of file sparse_set.hpp.
@@ -338,7 +334,7 @@ template<typename Entity >Reimplemented in entt::SparseSet< Entity, Type >.
-Definition at line 258 of file sparse_set.hpp.
+Definition at line 264 of file sparse_set.hpp.
@@ -370,7 +366,7 @@ template<typename Entity >Checks whether a sparse set is empty.
Definition at line 136 of file sparse_set.hpp.
+Definition at line 138 of file sparse_set.hpp.
@@ -404,7 +400,7 @@ template<typename Entity >sort.Definition at line 188 of file sparse_set.hpp.
+Definition at line 190 of file sparse_set.hpp.
@@ -445,7 +441,7 @@ template<typename Entity >Definition at line 215 of file sparse_set.hpp.
+Definition at line 219 of file sparse_set.hpp.
@@ -484,7 +480,7 @@ template<typename Entity >Definition at line 197 of file sparse_set.hpp.
+Definition at line 199 of file sparse_set.hpp.
@@ -550,8 +546,8 @@ template<typename Entity > - -| void entt::SparseSet< Entity >::respect | +virtual void entt::SparseSet< Entity >::respect | ( | const SparseSet< Entity > & | other | ) | @@ -571,12 +567,12 @@ template<typename Entity >
Sort entities according to their order in a sparse set.
+Sort entities according to their order in another sparse set.
Entities that are part of both the sparse sets are ordered internally according to the order they have in other. All the other entities goes to the end of the list and there are no guarantess on their order.
In other terms, this function can be used to impose the same order on two sets by using one of them as a master and the other one as a slave.
Iterating the sparse set with a couple of iterators returns elements in the expected order after a call to sort. See begin and end for more details.
Definition at line 345 of file sparse_set.hpp.
+Reimplemented in entt::SparseSet< Entity, Type >.
+ +Definition at line 319 of file sparse_set.hpp.
@@ -621,60 +619,12 @@ template<typename Entity >The number of elements is also the size of the internal packed array. There is no guarantee that the internal sparse array has the same size. Usually the size of the internal sparse array is equal or greater than the one of the internal packed array.
Definition at line 128 of file sparse_set.hpp.
+Definition at line 130 of file sparse_set.hpp.
- -
-
|
- -inline | -
Sort entities according to the given comparison function.
-Sort the elements so that iterating the sparse set with a couple of iterators returns them in the expected order. See begin and end for more details.
data gives no guarantees on the order, even though sort has been invoked.| Compare | Type of the comparison function. |
| compare | A comparison function whose signature shall be equivalent to: bool(Entity, Entity). |
Definition at line 313 of file sparse_set.hpp.
- -| virtual void entt::SparseSet< Entity >::swap | +void entt::SparseSet< Entity >::swap | ( | -entity_type | +pos_type | lhs, |
| - | entity_type | +pos_type | rhs | ||
| lhs | A valid entity identifier. |
| rhs | A valid entity identifier. |
| lhs | A valid position within the sparse set. |
| rhs | A valid position within the sparse set. |
Reimplemented in entt::SparseSet< Entity, Type >.
- -Definition at line 287 of file sparse_set.hpp.
+Definition at line 293 of file sparse_set.hpp.
diff --git a/classentt_1_1View-members.html b/classentt_1_1View-members.html index 65d90bba0..8104a5ceb 100644 --- a/classentt_1_1View-members.html +++ b/classentt_1_1View-members.html @@ -22,7 +22,7 @@This is the complete list of members for entt::View< Entity, First, Other >, including all inherited members.
+This is the complete list of members for entt::View< Entity, Component >, including all inherited members.
Public Types | |
| using | iterator_type = Iterator |
| -using | entity_type = typename base_pool_type::entity_type |
| Underlying entity identifier. | |
| -using | size_type = typename base_pool_type::size_type |
| Unsigned integer type. | |
| using | iterator_type = Iterator |
| +using | entity_type = typename base_pool_type::entity_type |
| Underlying entity identifier. | |
| +using | size_type = typename base_pool_type::size_type |
| Unsigned integer type. | |
Public Member Functions | |
| View (pool_type< First > &pool, pool_type< Other > &... other) noexcept | |
| Constructs a view out of a bunch of pools of components. More... | |
| iterator_type | begin () const noexcept |
| Returns an iterator to the first entity that has the given components. More... | |
| iterator_type | end () const noexcept |
| Returns an iterator that is past the last entity that has the given components. More... | |
| template<typename Component > | |
| const Component & | get (entity_type entity) const noexcept |
| Returns the component assigned to the given entity. More... | |
| template<typename Component > | |
| Component & | get (entity_type entity) noexcept |
| Returns the component assigned to the given entity. More... | |
| template<typename Func > | |
| void | each (Func &&func) |
| Iterate the entities and applies them the given function object. More... | |
| template<typename Func > | |
| void | each (Func &&func) const |
| Iterate the entities and applies them the given function object. More... | |
| void | reset () |
| Resets the view and reinitializes it. More... | |
| View (pool_type< Component > &... pools) noexcept | |
| Constructs a view out of a bunch of pools of components. More... | |
| iterator_type | begin () const noexcept |
| Returns an iterator to the first entity that has the given components. More... | |
| iterator_type | end () const noexcept |
| Returns an iterator that is past the last entity that has the given components. More... | |
| template<typename Comp > | |
| const Comp & | get (entity_type entity) const noexcept |
| Returns the component assigned to the given entity. More... | |
| template<typename Comp > | |
| Comp & | get (entity_type entity) noexcept |
| Returns the component assigned to the given entity. More... | |
| template<typename Func > | |
| void | each (Func func) const |
| Iterate the entities and applies them the given function object. More... | |
| template<typename Func > | |
| void | each (Func func) |
| Iterate the entities and applies them the given function object. More... | |
| void | reset () |
| Resets the view and reinitializes it. More... | |
Multi component view.
Multi component views iterate over those entities that have at least all the given components in their bags. During initialization, a multi component view looks at the number of entities available for each component and picks up a reference to the smallest set of candidate entities in order to get a performance boost when iterate.
@@ -144,61 +144,50 @@ class entt::View< Entity, First, Other >
| Entity | A valid entity type (see entt_traits for more details). |
| First | One of the components to iterate. |
| Other | The rest of the components to iterate. |
| Component | Types of components iterated by the view. |
| using entt::View< Entity, First, Other >::iterator_type = Iterator | +using entt::View< Entity, Component >::iterator_type = Iterator |
|
@@ -211,30 +200,29 @@ template<typename Entity , typename First , typename... Other>
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| pool | A reference to a pool of components. |
| other | Other references to pools of components. |
| pools | References to pools of components. |
Definition at line 372 of file view.hpp.
+Definition at line 373 of file view.hpp.
-
-
-
-
-Iterate the entities and applies them the given function object. -The function object is invoked for each entity. It is provided with the entity itself and a set of references to all the components of the view. void(entity_type, Component &...);
◆ each() [2/2]- -
-
-
-template<typename Entity , typename First , typename... Other>
-
-template<typename Func >
-
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||