Trait agent_tk::execution::tst::AgentExecutorTrait

source ·
pub trait AgentExecutorTrait {
    type SeqExecutor: Executor<Seq>;
    type ConcExecutor: Executor<Conc>;
    type MoveToExecutor: Executor<MoveTo>;
    type SearchAreaExecutor: Executor<SearchArea>;

    // Required methods
    fn from_agent<TAgent>(agent: &TAgent) -> Self
       where Self::SeqExecutor: CreatableFromAgent<TAgent, Self::SeqExecutor>,
             Self::ConcExecutor: CreatableFromAgent<TAgent, Self::ConcExecutor>,
             Self::MoveToExecutor: CreatableFromAgent<TAgent, Self::MoveToExecutor>,
             Self::SearchAreaExecutor: CreatableFromAgent<TAgent, Self::SearchAreaExecutor>;
    fn execute(&self, t: Node) -> ExecutionResult<'_>;
}
Expand description

Base trait for the AgentExecutor

Required Associated Types§

source

type SeqExecutor: Executor<Seq>

Executor for sequential nodes

source

type ConcExecutor: Executor<Conc>

Executor for concurrent nodes

source

type MoveToExecutor: Executor<MoveTo>

Executor for move_to nodes

source

type SearchAreaExecutor: Executor<SearchArea>

Executor for search area nodes

Required Methods§

source

fn from_agent<TAgent>(agent: &TAgent) -> Self

Create a new executor for the given agent

source

fn execute(&self, t: Node) -> ExecutionResult<'_>

Execute the tst

Object Safety§

This trait is not object safe.

Implementors§

source§

impl<TSeqExecutor: Executor<Seq>, TConcExecutor: Executor<Conc>, TMoveToExecutor: Executor<MoveTo>, TSearchAreaExecutor: Executor<SearchArea>> AgentExecutorTrait for AgentExecutor<TSeqExecutor, TConcExecutor, TMoveToExecutor, TSearchAreaExecutor>

source§

type SeqExecutor = TSeqExecutor

source§

type ConcExecutor = TConcExecutor

source§

type MoveToExecutor = TMoveToExecutor

source§

type SearchAreaExecutor = TSearchAreaExecutor