Struct web_assembler::builder::ModuleBuilder [−][src]
pub struct ModuleBuilder(_);
Methods
impl ModuleBuilder[src]
impl ModuleBuilderpub fn new() -> Self[src]
pub fn new() -> Selfpub fn function_index_of(
&self,
i: ImportIndex
) -> Result<FunctionSpaceIndex, ImportIndex>[src]
pub fn function_index_of(
&self,
i: ImportIndex
) -> Result<FunctionSpaceIndex, ImportIndex>pub fn build(self) -> Module[src]
pub fn build(self) -> Modulepub fn add_type(&mut self, ty: FuncType) -> TypeIndex[src]
pub fn add_type(&mut self, ty: FuncType) -> TypeIndexpub fn add_import(&mut self, ty: ImportEntry) -> ImportIndex[src]
pub fn add_import(&mut self, ty: ImportEntry) -> ImportIndexpub fn add_table(&mut self, ty: TableType) -> TableIndex[src]
pub fn add_table(&mut self, ty: TableType) -> TableIndexpub fn add_memory(&mut self, ty: MemoryType) -> MemoryIndex[src]
pub fn add_memory(&mut self, ty: MemoryType) -> MemoryIndexpub fn add_global(&mut self, ty: GlobalVariable) -> GlobalIndex[src]
pub fn add_global(&mut self, ty: GlobalVariable) -> GlobalIndexpub fn add_export(&mut self, ty: ExportEntry) -> ExportIndex[src]
pub fn add_export(&mut self, ty: ExportEntry) -> ExportIndexpub fn start(&mut self, index: FunctionIndex)[src]
pub fn start(&mut self, index: FunctionIndex)pub fn add_element(&mut self, ty: ElemSegment) -> ElementIndex[src]
pub fn add_element(&mut self, ty: ElemSegment) -> ElementIndexpub fn add_data(&mut self, ty: DataSegment) -> DataIndex[src]
pub fn add_data(&mut self, ty: DataSegment) -> DataIndexpub fn new_function(
&mut self,
(t, body): (FuncType, FunctionBody)
) -> FunctionIndex[src]
pub fn new_function(
&mut self,
(t, body): (FuncType, FunctionBody)
) -> FunctionIndexpub fn new_data(
&mut self,
idx: MemoryIndex,
offset: Code,
data: Vec<u8>
) -> DataIndex[src]
pub fn new_data(
&mut self,
idx: MemoryIndex,
offset: Code,
data: Vec<u8>
) -> DataIndexpub fn new_global(&mut self, ty: GlobalType, init: Code) -> GlobalIndex[src]
pub fn new_global(&mut self, ty: GlobalType, init: Code) -> GlobalIndexTrait Implementations
impl NewTable<Range<u32>> for ModuleBuilder[src]
impl NewTable<Range<u32>> for ModuleBuilderimpl NewTable<RangeFrom<u32>> for ModuleBuilder[src]
impl NewTable<RangeFrom<u32>> for ModuleBuilderimpl NewMemory<Range<u32>> for ModuleBuilder[src]
impl NewMemory<Range<u32>> for ModuleBuilderfn new_memory(&mut self, range: Range<u32>) -> MemoryIndex[src]
fn new_memory(&mut self, range: Range<u32>) -> MemoryIndeximpl NewMemory<RangeFrom<u32>> for ModuleBuilder[src]
impl NewMemory<RangeFrom<u32>> for ModuleBuilderfn new_memory(&mut self, range: RangeFrom<u32>) -> MemoryIndex[src]
fn new_memory(&mut self, range: RangeFrom<u32>) -> MemoryIndeximpl Export<FunctionIndex> for ModuleBuilder[src]
impl Export<FunctionIndex> for ModuleBuilderfn export<S: Into<String>>(
&mut self,
name: S,
index: FunctionIndex
) -> ExportIndex[src]
fn export<S: Into<String>>(
&mut self,
name: S,
index: FunctionIndex
) -> ExportIndeximpl Export<TableIndex> for ModuleBuilder[src]
impl Export<TableIndex> for ModuleBuilderfn export<S: Into<String>>(&mut self, name: S, index: TableIndex) -> ExportIndex[src]
fn export<S: Into<String>>(&mut self, name: S, index: TableIndex) -> ExportIndeximpl Export<MemoryIndex> for ModuleBuilder[src]
impl Export<MemoryIndex> for ModuleBuilderfn export<S: Into<String>>(
&mut self,
name: S,
index: MemoryIndex
) -> ExportIndex[src]
fn export<S: Into<String>>(
&mut self,
name: S,
index: MemoryIndex
) -> ExportIndeximpl Export<GlobalIndex> for ModuleBuilder[src]
impl Export<GlobalIndex> for ModuleBuilderfn export<S: Into<String>>(
&mut self,
name: S,
index: GlobalIndex
) -> ExportIndex[src]
fn export<S: Into<String>>(
&mut self,
name: S,
index: GlobalIndex
) -> ExportIndeximpl Import<TypeIndex> for ModuleBuilder[src]
impl Import<TypeIndex> for ModuleBuilderfn import<S, T>(&mut self, module: S, name: T, index: TypeIndex) -> ImportIndex where
S: Into<String>,
T: Into<String>, [src]
fn import<S, T>(&mut self, module: S, name: T, index: TypeIndex) -> ImportIndex where
S: Into<String>,
T: Into<String>, impl Import<TableType> for ModuleBuilder[src]
impl Import<TableType> for ModuleBuilderfn import<S, T>(&mut self, module: S, name: T, index: TableType) -> ImportIndex where
S: Into<String>,
T: Into<String>, [src]
fn import<S, T>(&mut self, module: S, name: T, index: TableType) -> ImportIndex where
S: Into<String>,
T: Into<String>, impl Import<MemoryType> for ModuleBuilder[src]
impl Import<MemoryType> for ModuleBuilderfn import<S, T>(&mut self, module: S, name: T, index: MemoryType) -> ImportIndex where
S: Into<String>,
T: Into<String>, [src]
fn import<S, T>(&mut self, module: S, name: T, index: MemoryType) -> ImportIndex where
S: Into<String>,
T: Into<String>, impl Import<GlobalType> for ModuleBuilder[src]
impl Import<GlobalType> for ModuleBuilderfn import<S, T>(&mut self, module: S, name: T, index: GlobalType) -> ImportIndex where
S: Into<String>,
T: Into<String>, [src]
fn import<S, T>(&mut self, module: S, name: T, index: GlobalType) -> ImportIndex where
S: Into<String>,
T: Into<String>, impl NewFunction<TypeIndex> for ModuleBuilder[src]
impl NewFunction<TypeIndex> for ModuleBuilderfn new_function(&mut self, t: TypeIndex, body: FunctionBody) -> FunctionIndex[src]
fn new_function(&mut self, t: TypeIndex, body: FunctionBody) -> FunctionIndeximpl NewFunction<FuncType> for ModuleBuilder[src]
impl NewFunction<FuncType> for ModuleBuilderfn new_function(&mut self, t: FuncType, body: FunctionBody) -> FunctionIndex[src]
fn new_function(&mut self, t: FuncType, body: FunctionBody) -> FunctionIndexAuto Trait Implementations
impl Send for ModuleBuilder
impl Send for ModuleBuilderimpl Sync for ModuleBuilder
impl Sync for ModuleBuilder