pub struct CallOutcome {
pub commands: Vec<ScriptCommand>,
pub ret: Option<ScriptValue>,
pub found: bool,
}Expand description
Outcome of one ScriptHost::call invocation.
commands is the full drain of the host’s command sink at return. It is
drained even when found == false, because builtins invoked outside
handlers may have queued commands.
Fields§
§commands: Vec<ScriptCommand>Commands the host’s builtins pushed into the sink during (and before) the call, drained at return.
ret: Option<ScriptValue>The script function’s return value. None when the function was
not found (or no program is loaded). Carries meaning for hooks
like on_close() -> Bool(false) vetoes the close.
found: boolfalse when the function does not exist - the runtime probes
optional handlers and treats a miss as silent success.
Trait Implementations§
Source§impl Clone for CallOutcome
impl Clone for CallOutcome
Source§fn clone(&self) -> CallOutcome
fn clone(&self) -> CallOutcome
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for CallOutcome
impl !RefUnwindSafe for CallOutcome
impl Send for CallOutcome
impl Sync for CallOutcome
impl Unpin for CallOutcome
impl UnsafeUnpin for CallOutcome
impl !UnwindSafe for CallOutcome
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
§impl<T> IntoResult<T> for T
impl<T> IntoResult<T> for T
§fn into_result(self) -> Result<T, RunSystemError>
fn into_result(self) -> Result<T, RunSystemError>
Converts this type into the system output type.