-
-
Notifications
You must be signed in to change notification settings - Fork 73
Expand file tree
/
Copy pathSwiftClass.Export.d.ts
More file actions
32 lines (31 loc) · 1005 Bytes
/
SwiftClass.Export.d.ts
File metadata and controls
32 lines (31 loc) · 1005 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
// NOTICE: This is auto-generated code by BridgeJS from JavaScriptKit,
// DO NOT EDIT.
//
// To update this file, just rebuild your project or run
// `swift package bridge-js`.
/// Represents a Swift heap object like a class instance or an actor instance.
export interface SwiftHeapObject {
/// Release the heap object.
///
/// Note: Calling this method will release the heap object and it will no longer be accessible.
release(): void;
}
export interface Greeter extends SwiftHeapObject {
greet(): string;
changeName(name: string): void;
}
export type Exports = {
Greeter: {
constructor(name: string): Greeter;
}
takeGreeter(greeter: Greeter): void;
}
export type Imports = {
}
export function createInstantiator(options: {
imports: Imports;
}, swift: any): Promise<{
addImports: (importObject: WebAssembly.Imports) => void;
setInstance: (instance: WebAssembly.Instance) => void;
createExports: (instance: WebAssembly.Instance) => Exports;
}>;