pub struct MockModuleBuilder { /* private fields */ }
Implementations§
Source§impl MockModuleBuilder
impl MockModuleBuilder
pub fn new() -> Self
pub fn with_heap_spec(self, heap_spec: HeapSpec) -> Self
pub fn with_initial_heap(self, heap: &[u8]) -> Self
pub fn with_global(self, idx: u32, init_val: i64) -> Self
pub fn with_exported_global( self, idx: u32, init_val: i64, export_name: &str, ) -> Self
pub fn with_import( self, idx: u32, import_module: &str, import_field: &str, ) -> Self
pub fn with_exported_import( self, idx: u32, import_module: &str, import_field: &str, export_name: &str, ) -> Self
pub fn with_table_element(self, idx: u32, element: &TableElement) -> Self
pub fn with_export_func(self, export: MockExportBuilder) -> Self
pub fn with_exported_import_func( self, export_name: &'static str, import_fn_ptr: FunctionPointer, sig: Signature, ) -> Self
pub fn with_table_func( self, table_idx: u32, func_idx: u32, func: FunctionPointer, ) -> Self
pub fn with_start_func(self, func: FunctionPointer) -> Self
pub fn build(self) -> Arc<dyn Module>
Trait Implementations§
Source§impl Default for MockModuleBuilder
impl Default for MockModuleBuilder
Source§fn default() -> MockModuleBuilder
fn default() -> MockModuleBuilder
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for MockModuleBuilder
impl RefUnwindSafe for MockModuleBuilder
impl Send for MockModuleBuilder
impl Sync for MockModuleBuilder
impl Unpin for MockModuleBuilder
impl UnwindSafe for MockModuleBuilder
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