import * as wasm from './wasm'; import * as ast from './ast'; import { Options } from './BinaryWriter'; export declare class Module { version: number; types: Array; exports: Array; imports: Array; functions: Array; start: ast.Function | null; tables: Array; memories: Array; globals: Array; readonly names: Array; addGlobal(type: wasm.Type, init: ast.Expression, immutable: boolean): ast.Global; addMemory(initialSize: number, maximumSize: number, segments: Array): ast.Memory; addTable(elements: Array, offset?: ast.Expression): ast.Table; addStart(start: ast.Function): ast.Function; addExport(externalName: string, value: ast.Function): ast.Export; addImport(name: string, moduleName: string, fieldName: string, externalKind: wasm.ExternalKind, type: ast.Type | wasm.Type): ast.Import; addFunctionType(paramTypes?: Array, returnTypes?: Array | wasm.Type): ast.FunctionType; addFunction(name: string, type: ast.FunctionType, localTypes: Array, body: Array): ast.Function; toBuffer(options?: Options): ArrayBuffer; }