wasmtime_linker_define_instance function
- @Native<Pointer<
wasmtime_error_t> Function(Pointer<wasmtime_linker_t> , Pointer<wasmtime_context_t> , Pointer<wasm_byte_t> , Size, Pointer<wasmtime_instance_t> )>(ffi.Pointer<wasmtime_linker_t>, ffi.Pointer<wasmtime_context_t>, ffi.Pointer<ffi.Char>, ffi.Size, ffi.Pointer<wasmtime_instance_t>)>()
- Pointer<
wasmtime_linker_t> linker, - Pointer<
wasmtime_context_t> store, - Pointer<
wasm_byte_t> name, - int name_len,
- Pointer<
wasmtime_instance_t> instance,
\brief Defines an instance under the specified name in this linker.
\param linker the linker the name is being defined in.
\param store the store that owns instance
\param name the module name to define instance under.
\param name_len the byte length of name
\param instance a previously-created instance.
\return On success NULL is returned, otherwise an error is returned which
describes why the definition failed.
This function will take all of the exports of the instance provided and
defined them under a module called name with a field name as the export's
own name.
For more information about name resolution consult the Rust documentation.
Implementation
@ffi.Native<
ffi.Pointer<wasmtime_error_t> Function(
ffi.Pointer<wasmtime_linker_t>,
ffi.Pointer<wasmtime_context_t>,
ffi.Pointer<ffi.Char>,
ffi.Size,
ffi.Pointer<wasmtime_instance_t>,
)
>()
external ffi.Pointer<wasmtime_error_t> wasmtime_linker_define_instance(
ffi.Pointer<wasmtime_linker_t> linker,
ffi.Pointer<wasmtime_context_t> store,
ffi.Pointer<ffi.Char> name,
int name_len,
ffi.Pointer<wasmtime_instance_t> instance,
);