Wasmtime
|
#include <wasmtime/component/component.h>
#include <wasmtime/component/func.h>
#include <wasmtime/conf.h>
#include <wasmtime/store.h>
Go to the source code of this file.
Data Structures | |
struct | wasmtime_component_instance |
Representation of a instance in Wasmtime. More... | |
Typedefs | |
typedef struct wasmtime_component_instance | wasmtime_component_instance_t |
Representation of a instance in Wasmtime. More... | |
Functions | |
wasmtime_component_export_index_t * | wasmtime_component_instance_get_export_index (const wasmtime_component_instance_t *instance, wasmtime_context_t *context, const wasmtime_component_export_index_t *instance_export_index, const char *name, size_t name_len) |
A methods similar to wasmtime_component_get_export_index except for this instance. More... | |
bool | wasmtime_component_instance_get_func (const wasmtime_component_instance_t *instance, wasmtime_context_t *context, const wasmtime_component_export_index_t *export_index, wasmtime_component_func_t *func_out) |
Looks up an exported function by name within this wasmtime_component_instance_t. More... | |
typedef struct wasmtime_component_instance wasmtime_component_instance_t |
Representation of a instance in Wasmtime.
Instances are represented with a 64-bit identifying integer in Wasmtime. They do not have any destructor associated with them. Instances cannot interoperate between wasmtime_store_t instances and if the wrong instance is passed to the wrong store then it may trigger an assertion to abort the process.
wasmtime_component_export_index_t * wasmtime_component_instance_get_export_index | ( | const wasmtime_component_instance_t * | instance, |
wasmtime_context_t * | context, | ||
const wasmtime_component_export_index_t * | instance_export_index, | ||
const char * | name, | ||
size_t | name_len | ||
) |
A methods similar to wasmtime_component_get_export_index except for this instance.
instance | the instance to look up name in |
context | the context where instance lives in |
instance_export_index | optional (i.e. nullable) instance to look up in |
name | the name of the export |
name_len | length of name in bytes |
bool wasmtime_component_instance_get_func | ( | const wasmtime_component_instance_t * | instance, |
wasmtime_context_t * | context, | ||
const wasmtime_component_export_index_t * | export_index, | ||
wasmtime_component_func_t * | func_out | ||
) |
Looks up an exported function by name within this wasmtime_component_instance_t.
instance | the instance to look up this name in |
context | the store that instance lives in |
export_index | the export index of the function |
func_out | if found, the function corresponding to name |
name
was found