pub struct WasmtimeExtensionProvider { /* private fields */ }Expand description
Import-free Wasmtime host for the direct scalar core.v1 ABI.
Implementations§
Source§impl WasmtimeExtensionProvider
impl WasmtimeExtensionProvider
pub fn compile(bytes: &[u8]) -> Result<Self, String>
pub fn compile_memory( bytes: &[u8], plan: MemoryBindingPlan, ) -> Result<Self, String>
pub fn compile_hta(bytes: &[u8]) -> Result<Self, String>
pub fn drain_lifecycle_events(&self) -> Vec<HtaProviderEvent>
pub fn compile_hta_with_host_handler( bytes: &[u8], host_handler: Option<Rc<dyn Fn(String, String, Vec<Value>) -> Result<Value, String>>>, ) -> Result<Self, String>
pub fn compile_hta_with_library( bytes: &[u8], library_bytes: &[u8], host_handler: Option<Rc<dyn Fn(String, String, Vec<Value>) -> Result<Value, String>>>, ) -> Result<Self, String>
Trait Implementations§
Source§impl WasmExtensionProvider for WasmtimeExtensionProvider
impl WasmExtensionProvider for WasmtimeExtensionProvider
fn supports(&self, abi: WasmAbi) -> bool
fn capabilities(&self) -> Vec<String>
fn start(&self, manifest: &ExtensionManifest) -> Result<(), String>
fn invoke( &self, manifest: &ExtensionManifest, export: &str, arguments: &[Value], ) -> Result<Value, String>
fn cancel( &self, _manifest: &ExtensionManifest, _request: u64, ) -> Result<(), String>
fn release( &self, manifest: &ExtensionManifest, handle: &Value, ) -> Result<(), String>
fn shutdown(&self, manifest: &ExtensionManifest)
Auto Trait Implementations§
impl !Freeze for WasmtimeExtensionProvider
impl !RefUnwindSafe for WasmtimeExtensionProvider
impl !Send for WasmtimeExtensionProvider
impl !Sync for WasmtimeExtensionProvider
impl !UnwindSafe for WasmtimeExtensionProvider
impl Unpin for WasmtimeExtensionProvider
impl UnsafeUnpin for WasmtimeExtensionProvider
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more