pub struct Module<V: VectorFactory> { /* private fields */ }
Implementations§
Source§impl<V: VectorFactory> Module<V>
impl<V: VectorFactory> Module<V>
pub fn decode(wasm_bytes: &[u8]) -> Result<Self, DecodeError>
pub fn instantiate<R>(
self,
resolver: R,
) -> Result<ModuleInstance<V, R::HostFunc>, ExecuteError>where
R: Resolve,
pub fn types(&self) -> &[Functype<V>]
pub fn funcs(&self) -> &[Func<V>]
pub fn table(&self) -> Option<Tabletype>
pub fn mem(&self) -> Option<Memtype>
pub fn globals(&self) -> &[Global]
pub fn elems(&self) -> &[Elem<V>]
pub fn datas(&self) -> &[Data<V>]
pub fn start(&self) -> Option<Funcidx>
pub fn imports(&self) -> &[Import<V>]
pub fn exports(&self) -> &[Export<V>]
Trait Implementations§
Source§impl<V: VectorFactory> Clone for Module<V>
impl<V: VectorFactory> Clone for Module<V>
Auto Trait Implementations§
impl<V> Freeze for Module<V>where
<V as VectorFactory>::Vector<Functype<V>>: Freeze,
<V as VectorFactory>::Vector<Func<V>>: Freeze,
<V as VectorFactory>::Vector<Import<V>>: Freeze,
<V as VectorFactory>::Vector<Global>: Freeze,
<V as VectorFactory>::Vector<Elem<V>>: Freeze,
<V as VectorFactory>::Vector<Data<V>>: Freeze,
<V as VectorFactory>::Vector<Export<V>>: Freeze,
impl<V> RefUnwindSafe for Module<V>where
<V as VectorFactory>::Vector<Functype<V>>: RefUnwindSafe,
<V as VectorFactory>::Vector<Func<V>>: RefUnwindSafe,
<V as VectorFactory>::Vector<Import<V>>: RefUnwindSafe,
<V as VectorFactory>::Vector<Global>: RefUnwindSafe,
<V as VectorFactory>::Vector<Elem<V>>: RefUnwindSafe,
<V as VectorFactory>::Vector<Data<V>>: RefUnwindSafe,
<V as VectorFactory>::Vector<Export<V>>: RefUnwindSafe,
impl<V> Send for Module<V>where
<V as VectorFactory>::Vector<Functype<V>>: Send,
<V as VectorFactory>::Vector<Func<V>>: Send,
<V as VectorFactory>::Vector<Import<V>>: Send,
<V as VectorFactory>::Vector<Global>: Send,
<V as VectorFactory>::Vector<Elem<V>>: Send,
<V as VectorFactory>::Vector<Data<V>>: Send,
<V as VectorFactory>::Vector<Export<V>>: Send,
impl<V> Sync for Module<V>where
<V as VectorFactory>::Vector<Functype<V>>: Sync,
<V as VectorFactory>::Vector<Func<V>>: Sync,
<V as VectorFactory>::Vector<Import<V>>: Sync,
<V as VectorFactory>::Vector<Global>: Sync,
<V as VectorFactory>::Vector<Elem<V>>: Sync,
<V as VectorFactory>::Vector<Data<V>>: Sync,
<V as VectorFactory>::Vector<Export<V>>: Sync,
impl<V> Unpin for Module<V>where
<V as VectorFactory>::Vector<Functype<V>>: Unpin,
<V as VectorFactory>::Vector<Func<V>>: Unpin,
<V as VectorFactory>::Vector<Import<V>>: Unpin,
<V as VectorFactory>::Vector<Global>: Unpin,
<V as VectorFactory>::Vector<Elem<V>>: Unpin,
<V as VectorFactory>::Vector<Data<V>>: Unpin,
<V as VectorFactory>::Vector<Export<V>>: Unpin,
impl<V> UnwindSafe for Module<V>where
<V as VectorFactory>::Vector<Functype<V>>: UnwindSafe,
<V as VectorFactory>::Vector<Func<V>>: UnwindSafe,
<V as VectorFactory>::Vector<Import<V>>: UnwindSafe,
<V as VectorFactory>::Vector<Global>: UnwindSafe,
<V as VectorFactory>::Vector<Elem<V>>: UnwindSafe,
<V as VectorFactory>::Vector<Data<V>>: UnwindSafe,
<V as VectorFactory>::Vector<Export<V>>: UnwindSafe,
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