Galaxy

Struct Galaxy 

Source
pub struct Galaxy { /* private fields */ }

Implementations§

Source§

impl Galaxy

Source

pub fn insert_entity(&self) -> EntityGetter<'_, ()>

Source

pub fn get_entity( &self, entity: Entity, ) -> Option<EntityGetter<'_, EntityModifyOnlyImpl>>

Source

pub fn remove_entity(&self, e: Entity)

Source

pub fn get_entities(&self) -> Vec<Entity>

Source§

impl Galaxy

Source

pub fn insert_event<E>(&self, e: E) -> &Galaxy
where E: Event + 'static,

Source

pub fn get_events<E>(&self) -> &[E]
where E: Event + 'static,

Source§

impl Galaxy

Source

pub fn query<CA>(&self) -> QueryInfo<'_, CA>
where CA: ComponentAccessOptional,

Source§

impl Galaxy

Source

pub fn insert_resource<R, RH>(&self, rh: RH, r: R) -> &Galaxy
where R: Resource + 'static, RH: Clone + Hash + 'static,

Source

pub fn remove_resource<R, RH>(&self, rh: RH) -> &Galaxy
where R: Resource + 'static, RH: Clone + Hash + 'static,

Source

pub fn get_resource<R, RH>(&self, rh: RH) -> Option<ResourceReadGuard<'_, R>>
where R: Resource + 'static, RH: Hash + 'static,

Source

pub fn get_mut_resource<R, RH>( &self, rh: RH, ) -> Option<ResourceWriteGuard<'_, R>>
where R: Resource + 'static, RH: Hash + 'static,

Source§

impl Galaxy

Source

pub fn new() -> Galaxy

Source

pub fn set_exit(&self)

Source

pub fn update(&mut self) -> Option<()>

Trait Implementations§

Source§

impl Default for Galaxy

Source§

fn default() -> Galaxy

Returns the “default value” for a type. Read more

Auto Trait Implementations§

§

impl !Freeze for Galaxy

§

impl !RefUnwindSafe for Galaxy

§

impl Send for Galaxy

§

impl Sync for Galaxy

§

impl Unpin for Galaxy

§

impl UnwindSafe for Galaxy

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.