Trait Interpreter

Source
pub trait Interpreter<H> {
    type State;
    type Trap;

    // Required methods
    fn deconstruct(self) -> (Self::State, Vec<u8>);
    fn state(&self) -> &Self::State;
    fn state_mut(&mut self) -> &mut Self::State;
    fn run(&mut self, handle: &mut H) -> Capture<ExitResult, Self::Trap>;
}

Required Associated Types§

Required Methods§

Source

fn deconstruct(self) -> (Self::State, Vec<u8>)

Source

fn state(&self) -> &Self::State

Source

fn state_mut(&mut self) -> &mut Self::State

Source

fn run(&mut self, handle: &mut H) -> Capture<ExitResult, Self::Trap>

Implementors§

Source§

impl<'etable, H, ES: EtableSet<Handle = H>> Interpreter<H> for EtableInterpreter<'etable, ES>

Source§

type State = <ES as EtableSet>::State

Source§

type Trap = <ES as EtableSet>::Trap