vec_entities

Function vec_entities 

Source
fn vec_entities<'a>(
    e_type: &'a EntityType,
    epoch_info: &'a EpochInfo,
) -> &'a Vec<Entity>
Expand description

Returns a slice over the entities of the requested type from the given EpochInfo.

The function matches the supplied e_type to the appropriate collection inside epoch_info. For unimplemented entity types the call will panic because of the todo!() placeholder.

§Arguments

  • e_type - The type of entities to retrieve.
  • epoch_info - The epoch information containing the collections.

§Returns

A reference to the vector containing the requested entities.
The lifetime of the returned slice is tied to that of epoch_info.