pub struct InvocationChunk<'chunk, 'call, 'source, C>where
C: HostSchema,{ /* private fields */ }Expand description
A borrowed source chunk executed through a typed Invocation.
Implementations§
Source§impl<'chunk, 'call, 'source, C> InvocationChunk<'chunk, 'call, 'source, C>where
C: HostSchema,
impl<'chunk, 'call, 'source, C> InvocationChunk<'chunk, 'call, 'source, C>where
C: HostSchema,
Sourcepub fn source_name(self, source_name: impl Into<String>) -> Self
pub fn source_name(self, source_name: impl Into<String>) -> Self
Sets the source name used by compile/runtime diagnostics and as the
referrer passed to the host module resolver for require calls.
Sourcepub fn source_map(self, mapping: SourceMap) -> Self
pub fn source_map(self, mapping: SourceMap) -> Self
Maps a generated console prefix out of human-facing diagnostics.
Sourcepub fn environment(self, environment: impl Into<Table>) -> Self
pub fn environment(self, environment: impl Into<Table>) -> Self
Selects the exact rooted lexical environment.
Sourcepub fn eval<T>(self) -> Result<T>where
T: FromRustia,
pub fn eval<T>(self) -> Result<T>where
T: FromRustia,
Evaluates and converts the first result through the owned typed facade.
Sourcepub fn eval_live(self) -> Result<Value>
pub fn eval_live(self) -> Result<Value>
Evaluates and retains the first result without snapshotting.
Sourcepub fn eval_serde<T>(self) -> Result<T>where
T: DeserializeOwned,
pub fn eval_serde<T>(self) -> Result<T>where
T: DeserializeOwned,
Evaluates and deserializes directly from the live VM graph.
Trait Implementations§
Auto Trait Implementations§
impl<'chunk, 'call, 'source, C> Freeze for InvocationChunk<'chunk, 'call, 'source, C>
impl<'chunk, 'call, 'source, C> !RefUnwindSafe for InvocationChunk<'chunk, 'call, 'source, C>
impl<'chunk, 'call, 'source, C> !Send for InvocationChunk<'chunk, 'call, 'source, C>
impl<'chunk, 'call, 'source, C> !Sync for InvocationChunk<'chunk, 'call, 'source, C>
impl<'chunk, 'call, 'source, C> Unpin for InvocationChunk<'chunk, 'call, 'source, C>
impl<'chunk, 'call, 'source, C> UnsafeUnpin for InvocationChunk<'chunk, 'call, 'source, C>
impl<'chunk, 'call, 'source, C> !UnwindSafe for InvocationChunk<'chunk, 'call, 'source, C>
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