Struct wasm_encoder::ComponentTypeEncoder
source · pub struct ComponentTypeEncoder<'a>(_);
Expand description
Used to encode component and instance types.
Implementations§
source§impl<'a> ComponentTypeEncoder<'a>
impl<'a> ComponentTypeEncoder<'a>
sourcepub fn component(self, ty: &ComponentType)
pub fn component(self, ty: &ComponentType)
Define a component type.
sourcepub fn instance(self, ty: &InstanceType)
pub fn instance(self, ty: &InstanceType)
Define an instance type.
sourcepub fn function(self) -> ComponentFuncTypeEncoder<'a>
pub fn function(self) -> ComponentFuncTypeEncoder<'a>
Define a function type.
sourcepub fn defined_type(self) -> ComponentDefinedTypeEncoder<'a>
pub fn defined_type(self) -> ComponentDefinedTypeEncoder<'a>
Define a defined component type.
The returned encoder must be used before adding another type.