/* tslint:disable */
/* eslint-disable */
/**
*/
export enum NativeEngineMode {
  SingleFrame,
  MultiFrame,
}
/**
*/
export class NativeEngine {
  free(): void;
/**
* @param {Function} read_file
* @param {Function} file_exists
* @param {Function} resolve_file
* @param {number} engine_mode
* @returns {NativeEngine}
*/
  static new(read_file: Function, file_exists: Function, resolve_file: Function, engine_mode: number): NativeEngine;
/**
* @param {string} uri
* @returns {any}
*/
  load(uri: string): any;
/**
* @param {string} uri
* @returns {any}
*/
  run(uri: string): any;
/**
* @returns {any}
*/
  get_graph_uris(): any;
/**
* @param {Function} listener
*/
  add_listener(listener: Function): void;
/**
* @param {string} uri
* @returns {any}
*/
  get_loaded_ast(uri: string): any;
/**
* @param {string} content
* @returns {any}
*/
  parse_content(content: string): any;
/**
* @param {string} uri
* @returns {any}
*/
  parse_file(uri: string): any;
/**
* @param {string} uri
* @param {string} content
*/
  update_virtual_file_content(uri: string, content: string): void;
}

export type InitInput = RequestInfo | URL | Response | BufferSource | WebAssembly.Module;

export interface InitOutput {
  readonly memory: WebAssembly.Memory;
  readonly __wbg_nativeengine_free: (a: number) => void;
  readonly nativeengine_new: (a: number, b: number, c: number, d: number) => number;
  readonly nativeengine_load: (a: number, b: number, c: number) => number;
  readonly nativeengine_run: (a: number, b: number, c: number) => number;
  readonly nativeengine_get_graph_uris: (a: number) => number;
  readonly nativeengine_add_listener: (a: number, b: number) => void;
  readonly nativeengine_get_loaded_ast: (a: number, b: number, c: number) => number;
  readonly nativeengine_parse_content: (a: number, b: number, c: number) => number;
  readonly nativeengine_parse_file: (a: number, b: number, c: number) => number;
  readonly nativeengine_update_virtual_file_content: (a: number, b: number, c: number, d: number, e: number) => void;
  readonly __wbindgen_malloc: (a: number) => number;
  readonly __wbindgen_realloc: (a: number, b: number, c: number) => number;
  readonly __wbindgen_exn_store: (a: number) => void;
  readonly __wbindgen_free: (a: number, b: number) => void;
}

/**
* If `module_or_path` is {RequestInfo} or {URL}, makes a request and
* for everything else, calls `WebAssembly.instantiate` directly.
*
* @param {InitInput | Promise<InitInput>} module_or_path
*
* @returns {Promise<InitOutput>}
*/
export default function init (module_or_path?: InitInput | Promise<InitInput>): Promise<InitOutput>;
        