|
| basic_view () noexcept |
| Default constructor to use to create empty, invalid views.
|
|
| basic_view (Get &value) noexcept |
| Constructs a view from a storage class.
|
|
| basic_view (std::tuple< Get & > value, std::tuple<>={}) noexcept |
| Constructs a view from a storage class.
|
|
template<typename Type = typename Get::element_type> |
auto * | storage () const noexcept |
| Returns the storage for a given element type, if any.
|
|
template<std::size_t Index> |
auto * | storage () const noexcept |
| Returns the storage for a given index, if any.
|
|
void | storage (Get &elem) noexcept |
| Assigns a storage to a view.
|
|
template<std::size_t Index> |
void | storage (Get &elem) noexcept |
| Assigns a storage to a view.
|
|
Get * | operator-> () const noexcept |
| Returns a pointer to the underlying storage.
|
|
decltype(auto) | operator[] (const entity_type entt) const |
| Returns the element assigned to the given entity.
|
|
template<typename Elem> |
decltype(auto) | get (const entity_type entt) const |
| Returns the element assigned to the given entity.
|
|
template<std::size_t... Index> |
decltype(auto) | get (const entity_type entt) const |
| Returns the element assigned to the given entity.
|
|
template<typename Func> |
void | each (Func func) const |
| Iterates entities and elements 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> |
std::enable_if_t< std::is_base_of_v< common_type, OGet >, basic_view< get_t< Get, OGet >, exclude_t<> > > | operator| (OGet &other) const noexcept |
| Combines a view and a storage in more specific 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.
|
|
const common_type * | handle () const noexcept |
| Returns the leading storage of a view, if any.
|
|
std::enable_if_t< Pol !=deletion_policy::in_place, size_type > | size () const noexcept |
| Returns the number of entities that have the given element.
|
|
std::enable_if_t< Pol==deletion_policy::in_place, size_type > | size_hint () const noexcept |
| Estimates the number of entities iterated by the view.
|
|
std::enable_if_t< Pol !=deletion_policy::in_place, bool > | empty () const noexcept |
| Checks whether a view is empty.
|
|
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.
|
|
std::enable_if_t< Pol !=deletion_policy::in_place, reverse_iterator > | rbegin () const noexcept |
| Returns an iterator to the first entity of the reversed view.
|
|
std::enable_if_t< Pol !=deletion_policy::in_place, reverse_iterator > | rend () const noexcept |
| Returns an iterator that is past the last entity of the reversed 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>
class entt::basic_view< get_t< Get >, exclude_t<> >
Storage view specialization.
This specialization offers a boost in terms of performance. It can access the underlying data structure directly and avoid superfluous checks.
- See also
- basic_view
- Template Parameters
-
Get | Type of storage iterated by the view. |
Definition at line 912 of file view.hpp.