Struct nyar_wasm::StructureItem
source · pub struct StructureItem {
pub symbol: WasmSymbol,
pub fields: BTreeMap<String, FieldType>,
pub span: FileSpan,
}Fields§
§symbol: WasmSymbol§fields: BTreeMap<String, FieldType>§span: FileSpanImplementations§
source§impl StructureItem
impl StructureItem
pub fn new<S: Into<WasmSymbol>>(name: S) -> Self
pub fn name(&self) -> String
pub fn set_field(&mut self, field: FieldType)
pub fn with_fields<I>(self, fields: I) -> Selfwhere
I: IntoIterator<Item = FieldType>,
Trait Implementations§
source§impl Clone for StructureItem
impl Clone for StructureItem
source§fn clone(&self) -> StructureItem
fn clone(&self) -> StructureItem
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moresource§impl Debug for StructureItem
impl Debug for StructureItem
source§impl From<StructureItem> for WasmType
impl From<StructureItem> for WasmType
source§fn from(value: StructureItem) -> Self
fn from(value: StructureItem) -> Self
Converts to this type from the input type.
source§impl From<StructureItem> for WasmValue
impl From<StructureItem> for WasmValue
source§fn from(value: StructureItem) -> Self
fn from(value: StructureItem) -> Self
Converts to this type from the input type.
source§impl<'a, 'i> IntoWasm<'a, ComponentDefinedType<'i>> for StructureItemwhere
'a: 'i,
impl<'a, 'i> IntoWasm<'a, ComponentDefinedType<'i>> for StructureItemwhere
'a: 'i,
fn as_wast(&'a self) -> ComponentDefinedType<'i>
source§impl<'a, 'i> IntoWasm<'a, Record<'i>> for StructureItemwhere
'a: 'i,
impl<'a, 'i> IntoWasm<'a, Record<'i>> for StructureItemwhere
'a: 'i,
source§impl<'a, 'i> IntoWasm<'a, Type<'i>> for StructureItemwhere
'a: 'i,
impl<'a, 'i> IntoWasm<'a, Type<'i>> for StructureItemwhere
'a: 'i,
source§impl<'a, 'i> IntoWasm<'a, TypeDef<'i>> for StructureItemwhere
'a: 'i,
impl<'a, 'i> IntoWasm<'a, TypeDef<'i>> for StructureItemwhere
'a: 'i,
source§impl<'a, 'i> IntoWasm<'a, VariantCase<'i>> for StructureItemwhere
'a: 'i,
impl<'a, 'i> IntoWasm<'a, VariantCase<'i>> for StructureItemwhere
'a: 'i,
fn as_wast(&'a self) -> VariantCase<'i>
source§impl WasmItem for StructureItem
impl WasmItem for StructureItem
fn register(self, builder: &mut WasmBuilder)
Auto Trait Implementations§
impl RefUnwindSafe for StructureItem
impl Send for StructureItem
impl Sync for StructureItem
impl Unpin for StructureItem
impl UnwindSafe for StructureItem
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