Documentation
¶
Overview ¶
Package entitycache stores large system records densely behind a small entity index.
Index ¶
- type Store
- func (s *Store[T]) All(yield func(ecs.Entity, *T) bool)
- func (s *Store[T]) Delete(entity ecs.Entity)
- func (s *Store[T]) Ensure(entity ecs.Entity) *T
- func (s *Store[T]) Get(entity ecs.Entity) *T
- func (s *Store[T]) Len() int
- func (s *Store[T]) Prune(keep func(ecs.Entity, *T) bool)
- func (s *Store[T]) Reset()
- func (s *Store[T]) Trim()
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Store ¶
type Store[T any] struct { // contains filtered or unexported fields }
Store validates full entity generations. Record pointers are borrowed until the next Ensure, Delete, Reset or Trim; no pointers into ECS columns are retained.