3#ifndef WASMTIME_COMPONENT_COMPONENT_H
4#define WASMTIME_COMPONENT_COMPONENT_H
10#ifdef WASMTIME_FEATURE_COMPONENT_MODEL
19#ifdef WASMTIME_FEATURE_COMPILER
130 const char *name,
size_t name_len);
wasmtime_error_t * wasmtime_component_deserialize(const wasm_engine_t *engine, const uint8_t *buf, size_t len, wasmtime_component_t **component_out)
Build a component from serialized data.
wasmtime_component_t * wasmtime_component_clone(const wasmtime_component_t *component)
Creates a shallow clone of the specified component, increasing the internal reference count.
struct wasmtime_component_export_index_t wasmtime_component_export_index_t
A value which represents a known export of a component.
Definition: component/component.h:113
struct wasmtime_component_t wasmtime_component_t
Representation of a component in the component model.
Definition: component/component.h:17
wasmtime_component_export_index_t * wasmtime_component_get_export_index(const wasmtime_component_t *component, const wasmtime_component_export_index_t *instance_export_index, const char *name, size_t name_len)
Looks up a specific export of this component by name optionally nested within the instance provided.
wasmtime_error_t * wasmtime_component_new(const wasm_engine_t *engine, const uint8_t *buf, size_t len, wasmtime_component_t **component_out)
Compiles a WebAssembly binary into a wasmtime_component_t.
wasmtime_error_t * wasmtime_component_serialize(const wasmtime_component_t *component, wasm_byte_vec_t *ret)
This function serializes compiled component artifacts as blob data.
void wasmtime_component_delete(wasmtime_component_t *component)
Deletes a wasmtime_component_t created by wasmtime_component_new.
void wasmtime_component_export_index_delete(wasmtime_component_export_index_t *export_index)
Deletes a wasmtime_component_export_index_t.
wasmtime_error_t * wasmtime_component_deserialize_file(const wasm_engine_t *engine, const char *path, wasmtime_component_t **component_out)
Deserialize a component from an on-disk file.
Build-time defines for how the C API was built.
Definition and accessors of wasmtime_error_t.
A list of bytes.
Definition: wasm.h:102
Compilation environment and configuration.
Errors generated by Wasmtime.