pub trait Storage: SizedAny {
    fn any(&self) -> &dyn Any { ... }
    fn any_mut(&mut self) -> &mut dyn Any { ... }
    fn delete(&mut self, _entity: EntityId, _current: u32) { ... }
    fn clear(&mut self, _current: u32) { ... }
    fn memory_usage(&self) -> Option<StorageMemoryUsage> { ... }
    fn name(&self) -> Cow<'static, str> { ... }
    fn sparse_array(&self) -> Option<&SparseArray<EntityId, 32>> { ... }
    fn is_empty(&self) -> bool { ... }
    fn clear_all_removed_or_deleted(&mut self) { ... }
    fn clear_all_removed_or_deleted_older_than_timestamp(
        &mut self,
        _timestamp: TrackingTimestamp
    ) { ... } }
Expand description

Defines common storage operations.

Provided Methods

Casts to &dyn Any.

Casts to &mut dyn Any.

Deletes an entity from this storage.

Deletes all components of this storage.

Returns how much memory this storage uses.

Returns the storage’s name.

Returns a SparseSet’s internal SparseArray.

Returns true if the storage is empty.

Clear all deletion and removal tracking data.

Clear all deletion and removal tracking data older than some timestamp.

Implementors