Class Environment

Environment to impelement most of the JS library functions.

Hierarchy

  • Environment

Implements

Constructors

  • Parameters

    • importObject: Record<string, any> = {}
    • logger: ((msg) => void) = console.log
        • (msg): void
        • Parameters

          • msg: string

          Returns void

    Returns Environment

Properties

imports: Record<string, any>

The imports that can be passed to WebAssembly instance creation.

logger: ((msg) => void)

Type declaration

    • (msg): void
    • Parameters

      • msg: string

      Returns void

packedCFuncTable: FTVMWasmPackedCFunc[] = ...

Maintains a table of FTVMWasmPackedCFunc that the C part can call via TVMWasmPackedCFunc.

We maintain a separate table so that we can have un-limited amount of functions that do not maps to the address space.

packedCFuncTableFreeId: number[] = []

Free table index that can be recycled.

Methods

Generated using TypeDoc