@wgb5445/aptos-intent-npm 0.0.1 → 0.0.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/aptos_intent.d.ts +138 -0
- package/dist/cjs/entry.js +818 -0
- package/dist/esm/entry.js +812 -1
- package/package.json +2 -1
@@ -0,0 +1,138 @@
|
|
1
|
+
/* tslint:disable */
|
2
|
+
/* eslint-disable */
|
3
|
+
/**
|
4
|
+
*/
|
5
|
+
export enum ArgumentOperation {
|
6
|
+
Move = 0,
|
7
|
+
Copy = 1,
|
8
|
+
Borrow = 2,
|
9
|
+
BorrowMut = 3,
|
10
|
+
}
|
11
|
+
/**
|
12
|
+
* Arguments for each function.
|
13
|
+
*/
|
14
|
+
export enum BatchArgumentType {
|
15
|
+
Raw = 0,
|
16
|
+
Signer = 1,
|
17
|
+
PreviousResult = 2,
|
18
|
+
}
|
19
|
+
/**
|
20
|
+
* Arguments for each function. Wasm bindgen only support C-style enum so use option to work around.
|
21
|
+
*/
|
22
|
+
export class BatchArgument {
|
23
|
+
free(): void;
|
24
|
+
/**
|
25
|
+
* @param {Uint8Array} bytes
|
26
|
+
* @returns {BatchArgument}
|
27
|
+
*/
|
28
|
+
static new_bytes(bytes: Uint8Array): BatchArgument;
|
29
|
+
/**
|
30
|
+
* @param {number} signer_idx
|
31
|
+
* @returns {BatchArgument}
|
32
|
+
*/
|
33
|
+
static new_signer(signer_idx: number): BatchArgument;
|
34
|
+
/**
|
35
|
+
* @returns {BatchArgument}
|
36
|
+
*/
|
37
|
+
borrow(): BatchArgument;
|
38
|
+
/**
|
39
|
+
* @returns {BatchArgument}
|
40
|
+
*/
|
41
|
+
borrow_mut(): BatchArgument;
|
42
|
+
/**
|
43
|
+
* @returns {BatchArgument}
|
44
|
+
*/
|
45
|
+
copy(): BatchArgument;
|
46
|
+
}
|
47
|
+
/**
|
48
|
+
* Call a Move entry function.
|
49
|
+
*/
|
50
|
+
export class BatchedFunctionCall {
|
51
|
+
free(): void;
|
52
|
+
}
|
53
|
+
/**
|
54
|
+
*/
|
55
|
+
export class BatchedFunctionCallBuilder {
|
56
|
+
free(): void;
|
57
|
+
/**
|
58
|
+
* @returns {BatchedFunctionCallBuilder}
|
59
|
+
*/
|
60
|
+
static single_signer(): BatchedFunctionCallBuilder;
|
61
|
+
/**
|
62
|
+
* @param {number} signer_count
|
63
|
+
* @returns {BatchedFunctionCallBuilder}
|
64
|
+
*/
|
65
|
+
static multi_signer(signer_count: number): BatchedFunctionCallBuilder;
|
66
|
+
/**
|
67
|
+
* @param {string} module
|
68
|
+
* @param {string} _function
|
69
|
+
* @param {(string)[]} ty_args
|
70
|
+
* @param {(BatchArgument)[]} args
|
71
|
+
* @returns {(BatchArgument)[]}
|
72
|
+
*/
|
73
|
+
add_batched_call(module: string, _function: string, ty_args: (string)[], args: (BatchArgument)[]): (BatchArgument)[];
|
74
|
+
/**
|
75
|
+
* @returns {Uint8Array}
|
76
|
+
*/
|
77
|
+
generate_batched_calls(): Uint8Array;
|
78
|
+
/**
|
79
|
+
* @param {string} network
|
80
|
+
* @param {string} module_name
|
81
|
+
* @returns {Promise<void>}
|
82
|
+
*/
|
83
|
+
load_module(network: string, module_name: string): Promise<void>;
|
84
|
+
}
|
85
|
+
/**
|
86
|
+
*/
|
87
|
+
export class PreviousResult {
|
88
|
+
free(): void;
|
89
|
+
}
|
90
|
+
|
91
|
+
export type InitInput = RequestInfo | URL | Response | BufferSource | WebAssembly.Module;
|
92
|
+
|
93
|
+
export interface InitOutput {
|
94
|
+
readonly memory: WebAssembly.Memory;
|
95
|
+
readonly __wbg_previousresult_free: (a: number) => void;
|
96
|
+
readonly __wbg_batchargument_free: (a: number) => void;
|
97
|
+
readonly __wbg_batchedfunctioncall_free: (a: number) => void;
|
98
|
+
readonly __wbg_batchedfunctioncallbuilder_free: (a: number) => void;
|
99
|
+
readonly batchedfunctioncallbuilder_single_signer: () => number;
|
100
|
+
readonly batchedfunctioncallbuilder_multi_signer: (a: number) => number;
|
101
|
+
readonly batchedfunctioncallbuilder_add_batched_call: (a: number, b: number, c: number, d: number, e: number, f: number, g: number, h: number, i: number, j: number) => void;
|
102
|
+
readonly batchedfunctioncallbuilder_generate_batched_calls: (a: number, b: number) => void;
|
103
|
+
readonly batchedfunctioncallbuilder_load_module: (a: number, b: number, c: number, d: number, e: number) => number;
|
104
|
+
readonly batchargument_new_bytes: (a: number, b: number) => number;
|
105
|
+
readonly batchargument_new_signer: (a: number) => number;
|
106
|
+
readonly batchargument_borrow: (a: number, b: number) => void;
|
107
|
+
readonly batchargument_borrow_mut: (a: number, b: number) => void;
|
108
|
+
readonly batchargument_copy: (a: number, b: number) => void;
|
109
|
+
readonly __wbindgen_malloc: (a: number, b: number) => number;
|
110
|
+
readonly __wbindgen_realloc: (a: number, b: number, c: number, d: number) => number;
|
111
|
+
readonly __wbindgen_export_2: WebAssembly.Table;
|
112
|
+
readonly _dyn_core__ops__function__FnMut__A____Output___R_as_wasm_bindgen__closure__WasmClosure___describe__invoke__h09acdaa8b02601d5: (a: number, b: number, c: number) => void;
|
113
|
+
readonly __wbindgen_add_to_stack_pointer: (a: number) => number;
|
114
|
+
readonly __wbindgen_free: (a: number, b: number, c: number) => void;
|
115
|
+
readonly __wbindgen_exn_store: (a: number) => void;
|
116
|
+
readonly wasm_bindgen__convert__closures__invoke2_mut__h4c0838795c3445c5: (a: number, b: number, c: number, d: number) => void;
|
117
|
+
}
|
118
|
+
|
119
|
+
export type SyncInitInput = BufferSource | WebAssembly.Module;
|
120
|
+
/**
|
121
|
+
* Instantiates the given `module`, which can either be bytes or
|
122
|
+
* a precompiled `WebAssembly.Module`.
|
123
|
+
*
|
124
|
+
* @param {SyncInitInput} module
|
125
|
+
*
|
126
|
+
* @returns {InitOutput}
|
127
|
+
*/
|
128
|
+
export function initSync(module: SyncInitInput): InitOutput;
|
129
|
+
|
130
|
+
/**
|
131
|
+
* If `module_or_path` is {RequestInfo} or {URL}, makes a request and
|
132
|
+
* for everything else, calls `WebAssembly.instantiate` directly.
|
133
|
+
*
|
134
|
+
* @param {InitInput | Promise<InitInput>} module_or_path
|
135
|
+
*
|
136
|
+
* @returns {Promise<InitOutput>}
|
137
|
+
*/
|
138
|
+
export default function __wbg_init (module_or_path?: InitInput | Promise<InitInput>): Promise<InitOutput>;
|