Flecs v3.2
A fast entity component system (ECS) for C & C++
Loading...
Searching...
No Matches
flecs::field< T > Struct Template Reference

Wrapper class around a field. More...

#include <field.hpp>

Public Member Functions

 field (T *array, size_t count, bool is_shared=false)
 Create field from component array.
 
 field (iter &iter, int field)
 Create field from iterator.
 
T & operator[] (size_t index) const
 Return element in component array.
 
T & operator* () const
 Return first element of component array.
 
T * operator-> () const
 Return first element of component array.
 

Protected Attributes

T * m_data
 
size_t m_count
 
bool m_is_shared
 

Detailed Description

template<typename T>
struct flecs::field< T >

Wrapper class around a field.

Template Parameters
Tcomponent type of the field.

Definition at line 61 of file field.hpp.


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