|
| basic_view () noexcept |
| Default constructor to use to create empty, invalid views.
|
|
| basic_view (Get &...value, Exclude &...excl) noexcept |
| Constructs a view from a set of storage classes.
|
|
| basic_view (std::tuple< Get &... > value, std::tuple< Exclude &... > excl={}) noexcept |
| Constructs a view from a set of storage classes.
|
|
template<typename Type > |
void | use () noexcept |
| Forces a view to use a given component to drive iterations.
|
|
template<std::size_t Index> |
void | use () noexcept |
| Forces a view to use a given component to drive iterations.
|
|
template<typename Type > |
auto * | storage () const noexcept |
| Returns the storage for a given component type, if any.
|
|
template<std::size_t Index> |
auto * | storage () const noexcept |
| Returns the storage for a given index, if any.
|
|
template<typename Type > |
void | storage (Type &elem) noexcept |
| Assigns a storage to a view.
|
|
template<std::size_t Index, typename Type > |
void | storage (Type &elem) noexcept |
| Assigns a storage to a view.
|
|
decltype(auto) | operator[] (const entity_type entt) const |
| Returns the components assigned to the given entity.
|
|
template<typename Type , typename... Other> |
decltype(auto) | get (const entity_type entt) const |
| Returns the components assigned to the given entity.
|
|
template<std::size_t... Index> |
decltype(auto) | get (const entity_type entt) const |
| Returns the components assigned to the given entity.
|
|
template<typename Func > |
void | each (Func func) const |
| Iterates entities and components and applies the given function object to them.
|
|
iterable | each () const noexcept |
| Returns an iterable object to use to visit a view.
|
|
template<typename... OGet, typename... OExclude> |
auto | operator| (const basic_view< get_t< OGet... >, exclude_t< OExclude... > > &other) const noexcept |
| Combines two views in a more specific one.
|
|
void | refresh () noexcept |
| Updates the internal leading view if required.
|
|
const common_type * | handle () const noexcept |
| Returns the leading storage of a view, if any.
|
|
size_type | size_hint () const noexcept |
| Estimates the number of entities iterated by the view.
|
|
iterator | begin () const noexcept |
| Returns an iterator to the first entity of the view.
|
|
iterator | end () const noexcept |
| Returns an iterator that is past the last entity of the view.
|
|
entity_type | front () const noexcept |
| Returns the first entity of the view, if any.
|
|
entity_type | back () const noexcept |
| Returns the last entity of the view, if any.
|
|
iterator | find (const entity_type entt) const noexcept |
| Finds an entity.
|
|
| operator bool () const noexcept |
| Checks if a view is fully initialized.
|
|
bool | contains (const entity_type entt) const noexcept |
| Checks if a view contains an entity.
|
|
template<typename... Get, typename... Exclude>
class entt::basic_view< get_t< Get... >, exclude_t< Exclude... > >
General purpose view.
This view visits all entities that are at least in the given storage. During initialization, it also looks at the number of elements available for each storage and uses the smallest set in order to get a performance boost.
- See also
- basic_view
- Template Parameters
-
Get | Types of storage iterated by the view. |
Exclude | Types of storage used to filter the view. |
Definition at line 388 of file view.hpp.