pub struct Native<R, O, E> { /* private fields */ }Expand description
A host over std, reading console input from R and writing console
output to O and E.
Implementations§
Source§impl<R: Read, O: Write, E: Write> Native<R, O, E>
impl<R: Read, O: Write, E: Write> Native<R, O, E>
Sourcepub fn perform<A: IVm>(
&mut self,
command: Any<A>,
payload: Any<A>,
) -> Result<Any<A>, Any<A>>
pub fn perform<A: IVm>( &mut self, command: Any<A>, payload: Any<A>, ) -> Result<Any<A>, Any<A>>
Performs command with payload: the answer is a Result for the
continuation. A request that is not one the operation takes is thrown
in the language, as the JavaScript runners’ assert ends their loop.
Trait Implementations§
Auto Trait Implementations§
impl<R, O, E> Freeze for Native<R, O, E>
impl<R, O, E> RefUnwindSafe for Native<R, O, E>
impl<R, O, E> Send for Native<R, O, E>
impl<R, O, E> Sync for Native<R, O, E>
impl<R, O, E> Unpin for Native<R, O, E>
impl<R, O, E> UnsafeUnpin for Native<R, O, E>
impl<R, O, E> UnwindSafe for Native<R, O, E>
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