System builder. More...
#include <builder.hpp>
Public Member Functions | |
| system_builder (flecs::world_t *world, const char *name=nullptr) | |
| template<typename Func> | |
| system | each (Func &&func) |
| Public Member Functions inherited from flecs::_::builder< system, ecs_system_desc_t, system_builder< Components... >, system_builder_i, Components ... > | |
| builder (world_t *world, const char *name=nullptr) | |
| builder (const builder &other) | |
| builder (builder &&other) noexcept | |
| operator ecs_system_desc_t * () | |
| operator const ecs_system_desc_t * () const | |
| system | build () const |
| system | run (Func &&func, Each &&... each_func) |
| system | each (Func &&func) |
| system | run_each (Func &&func) |
| operator ecs_system_desc_t * () | |
| operator const ecs_system_desc_t * () const | |
| Public Member Functions inherited from flecs::system_builder_i< Base, Components > | |
| system_builder_i (ecs_system_desc_t *desc, int32_t term_index=0) | |
| Base & | kind (entity_t phase) |
| Specify in which phase the system should run. | |
| template<typename E, if_t< is_enum< E >::value > = 0> | |
| Base & | kind (E phase) |
| Specify in which phase the system should run, using an enum constant. | |
| template<typename Phase> | |
| Base & | kind () |
| Specify in which phase the system should run. | |
| Base & | multi_threaded (bool value=true) |
| Specify whether the system can run on multiple threads. | |
| Base & | immediate (bool value=true) |
| Specify whether the system should be run in an immediate (non-staged) context. | |
| Base & | interval (ecs_ftime_t interval) |
| Set the system interval. | |
| Base & | rate (const entity_t tick_source, int32_t rate) |
| Set the system rate. | |
| Base & | rate (int32_t rate) |
| Set the system rate. | |
| template<typename T> | |
| Base & | tick_source () |
| Set the tick source. | |
| Base & | tick_source (flecs::entity_t tick_source) |
| Set the tick source. | |
| Base & | ctx (void *ptr) |
| Set the system context. | |
| Base & | run (ecs_iter_action_t action) |
| Set the system run callback. | |
| Public Member Functions inherited from flecs::query_builder_i< Base, Components ... > | |
| query_builder_i (ecs_query_desc_t *desc, int32_t term_index=0) | |
| Construct from a query descriptor. | |
| Base & | query_flags (ecs_flags32_t flags) |
| Set the query flags. | |
| Base & | cache_kind (query_cache_kind_t kind) |
| Set the cache kind for the query. | |
| Base & | cached () |
| Enable auto-caching for the query. | |
| Base & | detect_changes () |
| Enable change detection for the query. | |
| Base & | expr (const char *expr) |
| Set the query expression string. | |
| Base & | with () |
| Base & | with () |
| Base & | with (Second second) |
| Base & | with (Arg &&arg) |
| Base & | with (First first, Second second) |
| Base & | without (Args &&... args) |
| Base & | write () |
| Base & | write (Args &&... args) |
| Base & | read () |
| Base & | read (Args &&... args) |
| Base & | scope_open () |
| Open a query scope. | |
| Base & | scope_close () |
| Close a query scope. | |
| Base & | term () |
| Set the current term to the next one in the term list. | |
| Base & | term_at () |
| Set the current term to the one with the provided type. | |
| Base & | term_at (int32_t term_index) |
| Set the current term to the one at the provided index. | |
| Base & | term_at (int32_t term_index) |
| Set the current term to the one at the provided index and assert that the type matches. | |
| Base & | order_by (int(*compare)(flecs::entity_t, const T *, flecs::entity_t, const T *)) |
| Sort the output of a query. | |
| Base & | order_by (flecs::entity_t component, int(*compare)(flecs::entity_t, const void *, flecs::entity_t, const void *)) |
| Sort the output of a query. | |
| Base & | group_by (uint64_t(*group_by_action)(flecs::world_t *, flecs::table_t *table, flecs::id_t id, void *ctx)) |
| Group and sort matched tables. | |
| Base & | group_by (flecs::entity_t component, uint64_t(*group_by_action)(flecs::world_t *, flecs::table_t *table, flecs::id_t id, void *ctx)) |
| Group and sort matched tables. | |
| Base & | group_by () |
| Group and sort matched tables. | |
| Base & | group_by (flecs::entity_t component) |
| Group and sort matched tables. | |
| Base & | group_by_ctx (void *ctx, ecs_ctx_free_t ctx_free=nullptr) |
| Specify context to be passed to the group_by() function. | |
| Base & | on_group_create (ecs_group_create_action_t action) |
| Specify the on_group_create() action. | |
| Base & | on_group_delete (ecs_group_delete_action_t action) |
| Specify the on_group_delete() action. | |
| Public Member Functions inherited from flecs::term_builder_i< Base > | |
| term_builder_i () | |
| Default constructor. | |
| term_builder_i (ecs_term_t *term_ptr) | |
| Construct from a term pointer. | |
| Base & | term (id_t id) |
| Set the term ID. | |
| template<typename T = void, typename... Args> | |
| Base & | src (Args... args) |
| template<typename T = void, typename... Args> | |
| Base & | first (Args... args) |
| template<typename T = void, typename... Args> | |
| Base & | second (Args... args) |
| Base & | up (flecs::entity_t trav=0) |
| The up flag indicates that the term identifier may be substituted by traversing a relationship upwards. | |
| template<typename Trav> | |
| Base & | up () |
| Traverse upwards using the specified relationship type. | |
| Base & | cascade (flecs::entity_t trav=0) |
| The cascade flag is like up(), but returns results in breadth-first order. | |
| template<typename Trav> | |
| Base & | cascade () |
| Cascade using the specified relationship type. | |
| Base & | desc () |
| Use with cascade() to iterate results in descending (bottom-to-top) order. | |
| Base & | parent () |
| Same as up(). | |
| Base & | trav (flecs::entity_t trav, flecs::flags32_t flags=0) |
| Specify the relationship to traverse, and flags to indicate direction. | |
| Base & | id_flags (id_t flags) |
| Set ID flags for the term. | |
| Base & | inout (flecs::inout_kind_t inout) |
| Set read/write access of the term. | |
| Base & | inout_stage (flecs::inout_kind_t inout) |
| Set read/write access for a stage. | |
| Base & | write () |
| Short for inout_stage(flecs::Out). | |
| Base & | read () |
| Short for inout_stage(flecs::In). | |
| Base & | read_write () |
| Short for inout_stage(flecs::InOut). | |
| Base & | in () |
| Short for inout(flecs::In). | |
| Base & | out () |
| Short for inout(flecs::Out). | |
| Base & | inout () |
| Short for inout(flecs::InOut). | |
| Base & | inout_none () |
| Short for inout(flecs::InOutNone). | |
| Base & | oper (flecs::oper_kind_t oper) |
| Set the operator of the term. | |
| Base & | and_ () |
| Short for oper(flecs::And). | |
| Base & | or_ () |
| Short for oper(flecs::Or). | |
| Base & | not_ () |
| Short for oper(flecs::Not). | |
| Base & | optional () |
| Short for oper(flecs::Optional). | |
| Base & | and_from () |
| Short for oper(flecs::AndFrom). | |
| Base & | or_from () |
| Short for oper(flecs::OrFrom). | |
| Base & | not_from () |
| Short for oper(flecs::NotFrom). | |
| Base & | filter () |
| Mark the term as a filter. | |
| Public Member Functions inherited from flecs::term_ref_builder_i< Base > | |
| term_ref_builder_i () | |
| Default constructor. | |
| virtual | ~term_ref_builder_i () |
| Destructor. | |
| Base & | self () |
| The self flag indicates that the term identifier itself is used. | |
| Base & | id (flecs::entity_t id) |
| Specify the value of the identifier by ID. | |
| Base & | entity (flecs::entity_t entity) |
| Specify the value of the identifier by ID. | |
| Base & | name (const char *name) |
| Specify the value of the identifier by name. | |
| Base & | var (const char *var_name) |
| Specify that the identifier is a variable (resolved at query evaluation time). | |
| Base & | flags (flecs::flags64_t flags) |
| Override the term ID flags. | |
System builder.
Forward declaration for system builder.
Definition at line 25 of file builder.hpp.
|
inline |
Definition at line 26 of file builder.hpp.
|
inline |