pub struct AgentWorldActions<'w> { /* private fields */ }
Expand description
Modify actions using World
.
Trait Implementations§
source§impl ModifyActions for AgentWorldActions<'_>
impl ModifyActions for AgentWorldActions<'_>
source§fn order(&mut self, order: AddOrder) -> &mut Self
fn order(&mut self, order: AddOrder) -> &mut Self
Specify the queue order for actions to be added.
Default is
AddOrder::Back
.source§fn repeat(&mut self, repeat: Repeat) -> &mut Self
fn repeat(&mut self, repeat: Repeat) -> &mut Self
Specify the repeat configuration for actions to be added.
Default is
Repeat::None
.source§fn add(&mut self, action: impl Into<Box<dyn Action>>) -> &mut Self
fn add(&mut self, action: impl Into<Box<dyn Action>>) -> &mut Self
Adds a single
action
to the queue.source§fn add_sequence(
&mut self,
actions: impl DoubleEndedIterator<Item = Box<dyn Action>> + Send + Sync + 'static
) -> &mut Self
fn add_sequence( &mut self, actions: impl DoubleEndedIterator<Item = Box<dyn Action>> + Send + Sync + 'static ) -> &mut Self
Adds a collection of actions to the queue that are executed sequentially, i.e. one by one.
source§fn add_parallel(
&mut self,
actions: impl Iterator<Item = Box<dyn Action>> + Send + Sync + 'static
) -> &mut Self
fn add_parallel( &mut self, actions: impl Iterator<Item = Box<dyn Action>> + Send + Sync + 'static ) -> &mut Self
Adds a collection of actions to the queue that are executed in parallel, i.e. all at once.
source§fn add_linked(
&mut self,
f: impl FnOnce(&mut LinkedActionsBuilder) + Send + Sync + 'static
) -> &mut Self
fn add_linked( &mut self, f: impl FnOnce(&mut LinkedActionsBuilder) + Send + Sync + 'static ) -> &mut Self
Adds a collection of linked actions to the queue that are executed sequentially.
Linked actions have the property that if any of them are
canceled
,
then the remaining actions in the collection are ignored.Auto Trait Implementations§
impl<'w> !RefUnwindSafe for AgentWorldActions<'w>
impl<'w> Send for AgentWorldActions<'w>
impl<'w> Sync for AgentWorldActions<'w>
impl<'w> Unpin for AgentWorldActions<'w>
impl<'w> !UnwindSafe for AgentWorldActions<'w>
Blanket Implementations§
§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere T: Any,
§fn into_any(self: Box<T, Global>) -> Box<dyn Any + 'static, Global>
fn into_any(self: Box<T, Global>) -> Box<dyn Any + 'static, Global>
Convert
Box<dyn Trait>
(where Trait: Downcast
) to Box<dyn Any>
. Box<dyn Any>
can
then be further downcast
into Box<ConcreteType>
where ConcreteType
implements Trait
.§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any + 'static>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any + 'static>
Convert
Rc<Trait>
(where Trait: Downcast
) to Rc<Any>
. Rc<Any>
can then be
further downcast
into Rc<ConcreteType>
where ConcreteType
implements Trait
.§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
Convert
&Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &Any
’s vtable from &Trait
’s.§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
Convert
&mut Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &mut Any
’s vtable from &mut Trait
’s.