FixedMainSchedule

Struct FixedMainSchedule 

pub struct FixedMainSchedule(/* private fields */);
Expand description

A Schedule that is part of the main Schedule that runs at a fixed interval, regardless of the frame rate. It may run zero or multiple times per frame.

Implementations§

§

impl FixedMainSchedule

pub fn new() -> Self

Methods from Deref<Target = Schedule>§

Source

pub fn dump_if_env(&self) -> Result<(), Error>

Dumps the schedule to a file specified by the PULZ_DUMP_SCHEDULE environment variable, if it is set. The dump-format can be specified by the PULZ_DUMP_SCHEDULE_FORMAT environment variable and defaults to debug.

Source

pub fn dump_file( &self, format: ScheduleDumpFormat, path: &Path, backtrace: Option<&Backtrace>, ) -> Result<(), Error>

Source

pub fn dump( &self, format: ScheduleDumpFormat, out: &mut dyn Write, backtrace: Option<&Backtrace>, ) -> Result<(), Error>

Source

pub fn run(&mut self, resources: &mut Resources)

Runs a single iteration of all active systems.

Exclusive-Systems and Non-Send Systems are always run on the current thread. Send-Systems are send on a thread-pool.

Source

pub fn run_local(&mut self, resources: &mut Resources)

Runs a single iteration of all active systems.

run_local runs all systems on the current thread.

Source

pub fn add_system<S, Marker>(&mut self, system: S) -> ScheduleNodeBuilder<'_>
where S: IntoSystem<Marker>, <S as IntoSystem<Marker>>::System: SendSystem,

Source

pub fn add_system_unsend<S, Marker>( &mut self, system: S, ) -> ScheduleNodeBuilder<'_>
where S: IntoSystem<Marker>, <S as IntoSystem<Marker>>::System: System,

Source

pub fn add_system_exclusive<S, Marker>( &mut self, system: S, ) -> ScheduleNodeBuilder<'_>
where S: IntoSystem<Marker>,

Source

pub fn chain(&mut self, phases: impl IntoIterator<Item = impl SystemSet>)

Source

pub fn add_dependency( &mut self, dependency: impl SystemSet, dependent: impl SystemSet, )

Source

pub fn init(&mut self, resources: &mut Resources) -> bool

Trait Implementations§

§

impl AsMut<Schedule> for FixedMainSchedule

§

fn as_mut(&mut self) -> &mut Schedule

Converts this type into a mutable reference of the (usually inferred) input type.
§

impl AsRef<Schedule> for FixedMainSchedule

§

fn as_ref(&self) -> &Schedule

Converts this type into a shared reference of the (usually inferred) input type.
§

impl Debug for FixedMainSchedule

§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
§

impl Default for FixedMainSchedule

§

fn default() -> FixedMainSchedule

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

impl Deref for FixedMainSchedule

§

type Target = Schedule

The resulting type after dereferencing.
§

fn deref(&self) -> &Self::Target

Dereferences the value.
§

impl DerefMut for FixedMainSchedule

§

fn deref_mut(&mut self) -> &mut Self::Target

Mutably dereferences the value.
§

impl ExclusiveSystem for FixedMainSchedule

§

fn run_exclusive(&mut self, resources: &mut Resources)

§

impl IntoSystem<()> for FixedMainSchedule

§

impl SystemInit for FixedMainSchedule

§

fn init(&mut self, resources: &mut Resources)

Source§

fn system_type_name(&self) -> &'static str

Source§

fn system_type_id(&self) -> TypeId

Source§

fn system_label(&self) -> SystemLabel

Auto Trait Implementations§

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> FromResources for T
where T: Default,

Source§

fn from_resources(_resources: &Resources) -> T

Source§

impl<T> FromResourcesMut for T
where T: FromResources,

Source§

fn from_resources_mut(resources: &mut Resources) -> T

Source§

impl<T> Instrument for T

Source§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Source§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
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<S> IntoSystem<SelfSystemMarker<S>> for S
where S: ExclusiveSystem,

Source§

type System = S

Source§

fn into_system(self) -> <S as IntoSystem<SelfSystemMarker<S>>>::System

Source§

impl<P, T> Receiver for P
where P: Deref<Target = T> + ?Sized, T: ?Sized,

Source§

type Target = T

🔬This is a nightly-only experimental API. (arbitrary_self_types)
The target type on which the method may be called.
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.
Source§

impl<T> WithSubscriber for T

Source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more