Skip to main content

NodeRun

Struct NodeRun 

Source
pub struct NodeRun<T: TypedMachine> { /* private fields */ }
Expand description

The run behind an addon’s Run class: a run of the machine compiled once per addon, a chunk at a time, retired by a panic.

Implementations§

Source§

impl<T: TypedMachine> NodeRun<T>

Source

pub fn open(env: &Env, options: &str) -> Result<Self>

Opens a run with run options (xmachines_machine::open_run). An open that fails is an error of the fault’s code, message and seq.

Source

pub fn opening(&self) -> Vec<String>

The records the run opened with.

Source

pub fn apply(&mut self, env: &Env, chunk: &str) -> Result<Vec<String>>

Applies one chunk and gives its records; a fault is an error of its code, message and seq.

Source

pub fn can(&mut self, event: &str) -> Result<bool>

Whether the root would take event now.

Source

pub fn checkpoint(&self) -> Result<String>

The run as a checkpoint now.

Auto Trait Implementations§

§

impl<T> !RefUnwindSafe for NodeRun<T>

§

impl<T> !Sync for NodeRun<T>

§

impl<T> !UnwindSafe for NodeRun<T>

§

impl<T> Forget for NodeRun<T>

§

impl<T> Freeze for NodeRun<T>

§

impl<T> Move for NodeRun<T>

§

impl<T> Send for NodeRun<T>
where Arc<Machine<<T as TypedMachine>::Context, <T as TypedMachine>::Event>>: Send, Arc<dyn Logic>: Send, RawVecInner: Send, Arc<Vec<(String, Arc<dyn Logic>)>>: Send, &'static str: Send, String: Send, Arc<str>: Send, BoxRaw<str>: Send, BoxRaw<Value>: Send, BoxRaw<dyn AnySnapshot>: Send, RawTable<usize>: Send, Arc<dyn Fn() -> Result<(), String> + Send + Sync>: Send, BoxRaw<SystemError>: Send, BoxRaw<Scratch>: Send, BoxRaw<Vec<(ActorRef, Value)>>: Send,

§

impl<T> Unpin for NodeRun<T>
where Arc<Machine<<T as TypedMachine>::Context, <T as TypedMachine>::Event>>: Unpin, Arc<dyn Logic>: Unpin, *const u8 is !null: Unpin, Arc<Vec<(String, Arc<dyn Logic>)>>: Unpin, &'static str: Unpin, String: Unpin, Arc<str>: Unpin, Box<str>: Unpin, Box<Value>: Unpin, Box<dyn AnySnapshot>: Unpin, Arc<dyn Fn() -> Result<(), String> + Send + Sync>: Unpin, Box<SystemError>: Unpin, Box<Scratch>: Unpin, Box<Vec<(ActorRef, Value)>>: Unpin,

§

impl<T> UnsafeUnpin for NodeRun<T>
where *const ArcInner<Machine<<T as TypedMachine>::Context, <T as TypedMachine>::Event>> is !null: UnsafeUnpin, PhantomData<ArcInner<Machine<<T as TypedMachine>::Context, <T as TypedMachine>::Event>>>: UnsafeUnpin, *const ArcInner<dyn Logic> is !null: UnsafeUnpin, PhantomData<ArcInner<dyn Logic>>: UnsafeUnpin, *const u8 is !null: UnsafeUnpin, PhantomData<(String, Arc<dyn Logic>)>: UnsafeUnpin, *const ArcInner<Vec<(String, Arc<dyn Logic>)>> is !null: UnsafeUnpin, PhantomData<ArcInner<Vec<(String, Arc<dyn Logic>)>>>: UnsafeUnpin, &'static str: UnsafeUnpin, String: UnsafeUnpin, *const ArcInner<str> is !null: UnsafeUnpin, PhantomData<ArcInner<str>>: UnsafeUnpin, PhantomData<ActorEntry>: UnsafeUnpin, PhantomData<usize>: UnsafeUnpin, PhantomData<Bucket<String, ActorRef>>: UnsafeUnpin, PhantomData<fn() -> DefaultHasher>: UnsafeUnpin, PhantomData<Message>: UnsafeUnpin, PhantomData<Bucket<String, SystemTimer>>: UnsafeUnpin, PhantomData<Reverse<(u64, u64, u64)>>: UnsafeUnpin, PhantomData<Bucket<String, ExternalEffect>>: UnsafeUnpin, *const SystemError is !null: UnsafeUnpin, PhantomData<SystemError>: UnsafeUnpin, *const Scratch is !null: UnsafeUnpin, PhantomData<Scratch>: UnsafeUnpin, PhantomData<Value>: UnsafeUnpin, *const Vec<(ActorRef, Value)> is !null: UnsafeUnpin, PhantomData<Vec<(ActorRef, Value)>>: UnsafeUnpin, PhantomData<Vec<Value>>: UnsafeUnpin, *const str is !null: UnsafeUnpin, PhantomData<str>: UnsafeUnpin, PhantomData<fn(<T as TypedMachine>::Event)>: UnsafeUnpin, PhantomData<u8>: UnsafeUnpin, PhantomData<Bucket<String, Value>>: UnsafeUnpin, PhantomData<Work>: UnsafeUnpin, PhantomData<String>: UnsafeUnpin,

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 = !

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

fn try_from(value: U) -> Result<T, !>

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.