Options
All
  • Public
  • Public/Protected
  • All
Menu

Class Environment

Environment to impelement most of the JS library functions.

Hierarchy

  • Environment

Implements

Index

Constructors

constructor

  • new Environment(importObject?: Record<string, any>, logger?: (msg: string) => void): Environment
  • Parameters

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

          • msg: string

          Returns void

    Returns Environment

Properties

imports

imports: Record<string, any>

logger

logger: (msg: string) => void

Type declaration

    • (msg: string): void
    • Parameters

      • msg: string

      Returns void

packedCFuncTable

packedCFuncTable: Array<ctypes.FTVMWasmPackedCFunc | undefined> = [undefined,]

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

packedCFuncTableFreeId: Array<number> = []

Free table index that can be recycled.

Methods

start

  • start(inst: Instance): void
  • Mark the start of the instance.

    Parameters

    • inst: Instance

    Returns void

Generated using TypeDoc