class Entitas::EntityIndex(TEntity, TKey)
Defined in:
entitas.crentitas/entity_index/entity_index.cr
Constructors
- .new(name : String, group : Entitas::Group(TEntity), get_key : Proc(TEntity, Entitas::IComponent | Nil, TKey) | Nil, get_keys : Proc(TEntity, Entitas::IComponent | Nil, Array(TKey)) | Nil, is_single_key : Bool)
- .new(name : String, group : Entitas::Group(TEntity), get_keys : Proc(TEntity, Entitas::IComponent | Nil, Array(TKey)))
- .new(name : String, group : Entitas::Group(TEntity), get_key : Proc(TEntity, Entitas::IComponent | Nil, TKey))
Instance Method Summary
- #[](value : TKey)
- #[]?(value : TKey)
- #add_entity(key : TKey, entity : TEntity)
- #clear
- #del_entity(key : TKey, entity : TEntity)
- #each(*args, **options)
- #each(*args, **options, &)
- #get_entities(key : TKey) : Array(TEntity)
- #index : Hash(TKey, Array(TEntity))
- #to_s(io)
Instance methods inherited from class Entitas::AbstractEntityIndex(TEntity, TKey)
activate : Nil
activate,
add_entity(key : TKey, entity : TEntity)
add_entity,
clear
clear,
deactivate : Nil
deactivate,
del_entity(key : TKey, entity : TEntity)
del_entity,
finalize
finalize,
get_key : Proc(TEntity, Entitas::IComponent | Nil, TKey)
get_key,
get_keys : Proc(TEntity, Entitas::IComponent | Nil, Array(TKey))
get_keys,
name : String
name
Constructor methods inherited from class Entitas::AbstractEntityIndex(TEntity, TKey)
new(name : String, group : Entitas::Group(TEntity), get_key : Proc(TEntity, Entitas::IComponent | Nil, TKey) | Nil, get_keys : Proc(TEntity, Entitas::IComponent | Nil, Array(TKey)) | Nil, is_single_key : Bool)new(name : String, group : Entitas::Group(TEntity), get_keys : Proc(TEntity, Entitas::IComponent | Nil, Array(TKey)))
new(name : String, group : Entitas::Group(TEntity), get_key : Proc(TEntity, Entitas::IComponent | Nil, TKey)) new
Instance methods inherited from module Entitas::IEntityIndex
activate : Nil
activate,
deactivate : Nil
deactivate,
name : String
name,
to_json(json)
to_json,
to_s(io)
to_s,
to_string_cache : String | Nil
to_string_cache,
to_string_cache=(to_string_cache : String | Nil)
to_string_cache=
Constructor Detail
def self.new(name : String, group : Entitas::Group(TEntity), get_key : Proc(TEntity, Entitas::IComponent | Nil, TKey) | Nil, get_keys : Proc(TEntity, Entitas::IComponent | Nil, Array(TKey)) | Nil, is_single_key : Bool)
#
def self.new(name : String, group : Entitas::Group(TEntity), get_keys : Proc(TEntity, Entitas::IComponent | Nil, Array(TKey)))
#
def self.new(name : String, group : Entitas::Group(TEntity), get_key : Proc(TEntity, Entitas::IComponent | Nil, TKey))
#