co_ecs 0.9.0
Cobalt ECS
Loading...
Searching...
No Matches
co_ecs::component_fetch Struct Reference

Component fetch is a namespace for routines that figure out based on input component_reference how to fetch the component from the chunk. More...

#include <chunk.hpp>

Static Public Member Functions

template<component_reference C>
static auto fetch_pointer (auto &&chunk, std::size_t index) -> const decay_component_t< C > *requires(const_component_reference_v< C >)
 Fetches pointer for const component reference.
 
template<component_reference C>
static auto fetch_pointer (auto &&chunk, std::size_t index) -> decay_component_t< C > *requires(mutable_component_reference_v< C >)
 Fetches pointer for mutable component reference.
 

Detailed Description

Component fetch is a namespace for routines that figure out based on input component_reference how to fetch the component from the chunk.

Member Function Documentation

◆ fetch_pointer() [1/2]

template<component_reference C>
static auto co_ecs::component_fetch::fetch_pointer ( auto && chunk,
std::size_t index ) -> const decay_component_t<C>* requires(const_component_reference_v<C>)
inlinestatic

Fetches pointer for const component reference.

Template Parameters
CComponent reference

◆ fetch_pointer() [2/2]

template<component_reference C>
static auto co_ecs::component_fetch::fetch_pointer ( auto && chunk,
std::size_t index ) -> decay_component_t<C>* requires(mutable_component_reference_v<C>)
inlinestatic

Fetches pointer for mutable component reference.

Template Parameters
CComponent reference

The documentation for this struct was generated from the following file: