@secondts/bark-react-native 0.1.0-beta.6
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/BarkReactNative.podspec +44 -0
- package/README.md +46 -0
- package/android/CMakeLists.txt +76 -0
- package/android/build.gradle +144 -0
- package/android/cpp-adapter.cpp +42 -0
- package/android/generated/android/app/build/generated/source/codegen/java/com/facebook/fbreact/specs/NativeBarkReactNativeSpec.java +41 -0
- package/android/generated/android/app/build/generated/source/codegen/jni/CMakeLists.txt +36 -0
- package/android/generated/android/app/build/generated/source/codegen/jni/RNBarkReactNativeSpec-generated.cpp +38 -0
- package/android/generated/android/app/build/generated/source/codegen/jni/RNBarkReactNativeSpec.h +31 -0
- package/android/generated/android/app/build/generated/source/codegen/jni/react/renderer/components/RNBarkReactNativeSpec/ComponentDescriptors.cpp +22 -0
- package/android/generated/android/app/build/generated/source/codegen/jni/react/renderer/components/RNBarkReactNativeSpec/ComponentDescriptors.h +24 -0
- package/android/generated/android/app/build/generated/source/codegen/jni/react/renderer/components/RNBarkReactNativeSpec/EventEmitters.cpp +16 -0
- package/android/generated/android/app/build/generated/source/codegen/jni/react/renderer/components/RNBarkReactNativeSpec/EventEmitters.h +17 -0
- package/android/generated/android/app/build/generated/source/codegen/jni/react/renderer/components/RNBarkReactNativeSpec/Props.cpp +19 -0
- package/android/generated/android/app/build/generated/source/codegen/jni/react/renderer/components/RNBarkReactNativeSpec/Props.h +18 -0
- package/android/generated/android/app/build/generated/source/codegen/jni/react/renderer/components/RNBarkReactNativeSpec/RNBarkReactNativeSpecJSI-generated.cpp +32 -0
- package/android/generated/android/app/build/generated/source/codegen/jni/react/renderer/components/RNBarkReactNativeSpec/RNBarkReactNativeSpecJSI.h +76 -0
- package/android/generated/android/app/build/generated/source/codegen/jni/react/renderer/components/RNBarkReactNativeSpec/ShadowNodes.cpp +17 -0
- package/android/generated/android/app/build/generated/source/codegen/jni/react/renderer/components/RNBarkReactNativeSpec/ShadowNodes.h +23 -0
- package/android/generated/android/app/build/generated/source/codegen/jni/react/renderer/components/RNBarkReactNativeSpec/States.cpp +16 -0
- package/android/generated/android/app/build/generated/source/codegen/jni/react/renderer/components/RNBarkReactNativeSpec/States.h +19 -0
- package/android/src/main/AndroidManifest.xml +5 -0
- package/android/src/main/java/com/barkreactnative/BarkReactNativeModule.kt +43 -0
- package/android/src/main/java/com/barkreactnative/BarkReactNativePackage.kt +34 -0
- package/app.plugin.js +1 -0
- package/cpp/bark-react-native.cpp +16 -0
- package/cpp/bark-react-native.h +15 -0
- package/cpp/generated/bark.cpp +6665 -0
- package/cpp/generated/bark.hpp +212 -0
- package/cpp/secondts-bark-react-native.cpp +16 -0
- package/cpp/secondts-bark-react-native.h +15 -0
- package/ios/BarkReactNative.h +16 -0
- package/ios/BarkReactNative.mm +66 -0
- package/ios/generated/build/generated/ios/FBReactNativeSpec/FBReactNativeSpec-generated.mm +2321 -0
- package/ios/generated/build/generated/ios/FBReactNativeSpec/FBReactNativeSpec.h +2761 -0
- package/ios/generated/build/generated/ios/FBReactNativeSpecJSI-generated.cpp +2923 -0
- package/ios/generated/build/generated/ios/FBReactNativeSpecJSI.h +7718 -0
- package/ios/generated/build/generated/ios/RCTModulesConformingToProtocolsProvider.h +18 -0
- package/ios/generated/build/generated/ios/RCTModulesConformingToProtocolsProvider.mm +33 -0
- package/ios/generated/build/generated/ios/RNBarkReactNativeSpec/RNBarkReactNativeSpec-generated.mm +46 -0
- package/ios/generated/build/generated/ios/RNBarkReactNativeSpec/RNBarkReactNativeSpec.h +60 -0
- package/ios/generated/build/generated/ios/RNBarkReactNativeSpecJSI-generated.cpp +32 -0
- package/ios/generated/build/generated/ios/RNBarkReactNativeSpecJSI.h +76 -0
- package/ios/generated/build/generated/ios/react/renderer/components/RNBarkReactNativeSpec/ComponentDescriptors.cpp +22 -0
- package/ios/generated/build/generated/ios/react/renderer/components/RNBarkReactNativeSpec/ComponentDescriptors.h +24 -0
- package/ios/generated/build/generated/ios/react/renderer/components/RNBarkReactNativeSpec/EventEmitters.cpp +16 -0
- package/ios/generated/build/generated/ios/react/renderer/components/RNBarkReactNativeSpec/EventEmitters.h +17 -0
- package/ios/generated/build/generated/ios/react/renderer/components/RNBarkReactNativeSpec/Props.cpp +19 -0
- package/ios/generated/build/generated/ios/react/renderer/components/RNBarkReactNativeSpec/Props.h +18 -0
- package/ios/generated/build/generated/ios/react/renderer/components/RNBarkReactNativeSpec/RCTComponentViewHelpers.h +18 -0
- package/ios/generated/build/generated/ios/react/renderer/components/RNBarkReactNativeSpec/ShadowNodes.cpp +17 -0
- package/ios/generated/build/generated/ios/react/renderer/components/RNBarkReactNativeSpec/ShadowNodes.h +23 -0
- package/ios/generated/build/generated/ios/react/renderer/components/RNBarkReactNativeSpec/States.cpp +16 -0
- package/ios/generated/build/generated/ios/react/renderer/components/RNBarkReactNativeSpec/States.h +19 -0
- package/lib/commonjs/NativeBarkReactNative.js +10 -0
- package/lib/commonjs/NativeBarkReactNative.js.map +1 -0
- package/lib/commonjs/generated/bark-ffi.js +44 -0
- package/lib/commonjs/generated/bark-ffi.js.map +1 -0
- package/lib/commonjs/generated/bark.js +3175 -0
- package/lib/commonjs/generated/bark.js.map +1 -0
- package/lib/commonjs/index.js +63 -0
- package/lib/commonjs/index.js.map +1 -0
- package/lib/commonjs/package.json +1 -0
- package/lib/module/NativeBarkReactNative.js +7 -0
- package/lib/module/NativeBarkReactNative.js.map +1 -0
- package/lib/module/generated/bark-ffi.js +43 -0
- package/lib/module/generated/bark-ffi.js.map +1 -0
- package/lib/module/generated/bark.js +3164 -0
- package/lib/module/generated/bark.js.map +1 -0
- package/lib/module/index.js +43 -0
- package/lib/module/index.js.map +1 -0
- package/lib/module/package.json +1 -0
- package/lib/typescript/commonjs/package.json +1 -0
- package/lib/typescript/commonjs/plugin/src/index.d.ts +11 -0
- package/lib/typescript/commonjs/plugin/src/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/plugin/src/withAndroid.d.ts +6 -0
- package/lib/typescript/commonjs/plugin/src/withAndroid.d.ts.map +1 -0
- package/lib/typescript/commonjs/plugin/src/withIOS.d.ts +7 -0
- package/lib/typescript/commonjs/plugin/src/withIOS.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/NativeBarkReactNative.d.ts +8 -0
- package/lib/typescript/commonjs/src/NativeBarkReactNative.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/generated/bark-ffi.d.ts +264 -0
- package/lib/typescript/commonjs/src/generated/bark-ffi.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/generated/bark.d.ts +2963 -0
- package/lib/typescript/commonjs/src/generated/bark.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/index.d.ts +8 -0
- package/lib/typescript/commonjs/src/index.d.ts.map +1 -0
- package/lib/typescript/module/package.json +1 -0
- package/lib/typescript/module/plugin/src/index.d.ts +11 -0
- package/lib/typescript/module/plugin/src/index.d.ts.map +1 -0
- package/lib/typescript/module/plugin/src/withAndroid.d.ts +6 -0
- package/lib/typescript/module/plugin/src/withAndroid.d.ts.map +1 -0
- package/lib/typescript/module/plugin/src/withIOS.d.ts +7 -0
- package/lib/typescript/module/plugin/src/withIOS.d.ts.map +1 -0
- package/lib/typescript/module/src/NativeBarkReactNative.d.ts +8 -0
- package/lib/typescript/module/src/NativeBarkReactNative.d.ts.map +1 -0
- package/lib/typescript/module/src/generated/bark-ffi.d.ts +264 -0
- package/lib/typescript/module/src/generated/bark-ffi.d.ts.map +1 -0
- package/lib/typescript/module/src/generated/bark.d.ts +2963 -0
- package/lib/typescript/module/src/generated/bark.d.ts.map +1 -0
- package/lib/typescript/module/src/index.d.ts +8 -0
- package/lib/typescript/module/src/index.d.ts.map +1 -0
- package/package.json +154 -0
- package/plugin/build/index.d.ts +10 -0
- package/plugin/build/index.js +16 -0
- package/plugin/build/withAndroid.d.ts +5 -0
- package/plugin/build/withAndroid.js +26 -0
- package/plugin/build/withIOS.d.ts +6 -0
- package/plugin/build/withIOS.js +13 -0
- package/plugin/tsconfig.json +9 -0
- package/plugin/tsconfig.tsbuildinfo +1 -0
- package/react-native.config.js +12 -0
- package/scripts/postinstall.js +233 -0
- package/src/NativeBarkReactNative.ts +10 -0
- package/src/generated/bark-ffi.ts +694 -0
- package/src/generated/bark.ts +6068 -0
- package/src/index.tsx +41 -0
|
@@ -0,0 +1,694 @@
|
|
|
1
|
+
// This file was autogenerated by some hot garbage in the `uniffi-bindgen-react-native` crate.
|
|
2
|
+
// Trust me, you don't want to mess with it!
|
|
3
|
+
|
|
4
|
+
import {
|
|
5
|
+
type StructuralEquality as UniffiStructuralEquality,
|
|
6
|
+
type UniffiForeignFuture as RuntimeUniffiForeignFuture,
|
|
7
|
+
type UniffiRustCallStatus,
|
|
8
|
+
type UniffiRustArcPtr,
|
|
9
|
+
type UniffiRustFutureContinuationCallback as RuntimeUniffiRustFutureContinuationCallback,
|
|
10
|
+
type UniffiResult,
|
|
11
|
+
} from "uniffi-bindgen-react-native";
|
|
12
|
+
|
|
13
|
+
interface NativeModuleInterface {
|
|
14
|
+
ubrn_uniffi_internal_fn_func_ffi__string_to_byte_length(
|
|
15
|
+
string: string,
|
|
16
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
17
|
+
): number;
|
|
18
|
+
ubrn_uniffi_internal_fn_func_ffi__string_to_arraybuffer(
|
|
19
|
+
string: string,
|
|
20
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
21
|
+
): Uint8Array;
|
|
22
|
+
ubrn_uniffi_internal_fn_func_ffi__arraybuffer_to_string(
|
|
23
|
+
buffer: Uint8Array,
|
|
24
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
25
|
+
): string;
|
|
26
|
+
ubrn_uniffi_bark_ffi_fn_clone_onchainwallet(
|
|
27
|
+
ptr: bigint,
|
|
28
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
29
|
+
): bigint;
|
|
30
|
+
ubrn_uniffi_bark_ffi_fn_free_onchainwallet(
|
|
31
|
+
ptr: bigint,
|
|
32
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
33
|
+
): void;
|
|
34
|
+
ubrn_uniffi_bark_ffi_fn_constructor_onchainwallet_custom(
|
|
35
|
+
callbacks: bigint,
|
|
36
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
37
|
+
): bigint;
|
|
38
|
+
ubrn_uniffi_bark_ffi_fn_constructor_onchainwallet_default(
|
|
39
|
+
mnemonic: Uint8Array,
|
|
40
|
+
config: Uint8Array,
|
|
41
|
+
datadir: Uint8Array,
|
|
42
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
43
|
+
): bigint;
|
|
44
|
+
ubrn_uniffi_bark_ffi_fn_method_onchainwallet_balance(
|
|
45
|
+
ptr: bigint,
|
|
46
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
47
|
+
): Uint8Array;
|
|
48
|
+
ubrn_uniffi_bark_ffi_fn_method_onchainwallet_new_address(
|
|
49
|
+
ptr: bigint,
|
|
50
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
51
|
+
): Uint8Array;
|
|
52
|
+
ubrn_uniffi_bark_ffi_fn_method_onchainwallet_send(
|
|
53
|
+
ptr: bigint,
|
|
54
|
+
address: Uint8Array,
|
|
55
|
+
amountSats: bigint,
|
|
56
|
+
feeRateSatPerVb: bigint,
|
|
57
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
58
|
+
): Uint8Array;
|
|
59
|
+
ubrn_uniffi_bark_ffi_fn_method_onchainwallet_sync(
|
|
60
|
+
ptr: bigint,
|
|
61
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
62
|
+
): bigint;
|
|
63
|
+
ubrn_uniffi_bark_ffi_fn_clone_wallet(
|
|
64
|
+
ptr: bigint,
|
|
65
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
66
|
+
): bigint;
|
|
67
|
+
ubrn_uniffi_bark_ffi_fn_free_wallet(
|
|
68
|
+
ptr: bigint,
|
|
69
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
70
|
+
): void;
|
|
71
|
+
ubrn_uniffi_bark_ffi_fn_constructor_wallet_create(
|
|
72
|
+
mnemonic: Uint8Array,
|
|
73
|
+
config: Uint8Array,
|
|
74
|
+
datadir: Uint8Array,
|
|
75
|
+
forceRescan: number,
|
|
76
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
77
|
+
): bigint;
|
|
78
|
+
ubrn_uniffi_bark_ffi_fn_constructor_wallet_create_with_onchain(
|
|
79
|
+
mnemonic: Uint8Array,
|
|
80
|
+
config: Uint8Array,
|
|
81
|
+
datadir: Uint8Array,
|
|
82
|
+
onchainWallet: bigint,
|
|
83
|
+
forceRescan: number,
|
|
84
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
85
|
+
): bigint;
|
|
86
|
+
ubrn_uniffi_bark_ffi_fn_constructor_wallet_open(
|
|
87
|
+
mnemonic: Uint8Array,
|
|
88
|
+
config: Uint8Array,
|
|
89
|
+
datadir: Uint8Array,
|
|
90
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
91
|
+
): bigint;
|
|
92
|
+
ubrn_uniffi_bark_ffi_fn_constructor_wallet_open_with_onchain(
|
|
93
|
+
mnemonic: Uint8Array,
|
|
94
|
+
config: Uint8Array,
|
|
95
|
+
datadir: Uint8Array,
|
|
96
|
+
onchainWallet: bigint,
|
|
97
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
98
|
+
): bigint;
|
|
99
|
+
ubrn_uniffi_bark_ffi_fn_method_wallet_all_exits_claimable_at_height(
|
|
100
|
+
ptr: bigint,
|
|
101
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
102
|
+
): Uint8Array;
|
|
103
|
+
ubrn_uniffi_bark_ffi_fn_method_wallet_all_vtxos(
|
|
104
|
+
ptr: bigint,
|
|
105
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
106
|
+
): Uint8Array;
|
|
107
|
+
ubrn_uniffi_bark_ffi_fn_method_wallet_ark_info(
|
|
108
|
+
ptr: bigint,
|
|
109
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
110
|
+
): Uint8Array;
|
|
111
|
+
ubrn_uniffi_bark_ffi_fn_method_wallet_balance(
|
|
112
|
+
ptr: bigint,
|
|
113
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
114
|
+
): Uint8Array;
|
|
115
|
+
ubrn_uniffi_bark_ffi_fn_method_wallet_board_all(
|
|
116
|
+
ptr: bigint,
|
|
117
|
+
onchainWallet: bigint,
|
|
118
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
119
|
+
): Uint8Array;
|
|
120
|
+
ubrn_uniffi_bark_ffi_fn_method_wallet_board_amount(
|
|
121
|
+
ptr: bigint,
|
|
122
|
+
onchainWallet: bigint,
|
|
123
|
+
amountSats: bigint,
|
|
124
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
125
|
+
): Uint8Array;
|
|
126
|
+
ubrn_uniffi_bark_ffi_fn_method_wallet_bolt11_invoice(
|
|
127
|
+
ptr: bigint,
|
|
128
|
+
amountSats: bigint,
|
|
129
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
130
|
+
): Uint8Array;
|
|
131
|
+
ubrn_uniffi_bark_ffi_fn_method_wallet_broadcast_tx(
|
|
132
|
+
ptr: bigint,
|
|
133
|
+
txHex: Uint8Array,
|
|
134
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
135
|
+
): Uint8Array;
|
|
136
|
+
ubrn_uniffi_bark_ffi_fn_method_wallet_cancel_all_pending_rounds(
|
|
137
|
+
ptr: bigint,
|
|
138
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
139
|
+
): void;
|
|
140
|
+
ubrn_uniffi_bark_ffi_fn_method_wallet_cancel_pending_round(
|
|
141
|
+
ptr: bigint,
|
|
142
|
+
roundId: number,
|
|
143
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
144
|
+
): void;
|
|
145
|
+
ubrn_uniffi_bark_ffi_fn_method_wallet_check_lightning_payment(
|
|
146
|
+
ptr: bigint,
|
|
147
|
+
paymentHash: Uint8Array,
|
|
148
|
+
wait: number,
|
|
149
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
150
|
+
): Uint8Array;
|
|
151
|
+
ubrn_uniffi_bark_ffi_fn_method_wallet_claimable_lightning_receive_balance_sats(
|
|
152
|
+
ptr: bigint,
|
|
153
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
154
|
+
): bigint;
|
|
155
|
+
ubrn_uniffi_bark_ffi_fn_method_wallet_config(
|
|
156
|
+
ptr: bigint,
|
|
157
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
158
|
+
): Uint8Array;
|
|
159
|
+
ubrn_uniffi_bark_ffi_fn_method_wallet_drain_exits(
|
|
160
|
+
ptr: bigint,
|
|
161
|
+
vtxoIds: Uint8Array,
|
|
162
|
+
address: Uint8Array,
|
|
163
|
+
feeRateSatPerVb: Uint8Array,
|
|
164
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
165
|
+
): Uint8Array;
|
|
166
|
+
ubrn_uniffi_bark_ffi_fn_method_wallet_get_exit_status(
|
|
167
|
+
ptr: bigint,
|
|
168
|
+
vtxoId: Uint8Array,
|
|
169
|
+
includeHistory: number,
|
|
170
|
+
includeTransactions: number,
|
|
171
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
172
|
+
): Uint8Array;
|
|
173
|
+
ubrn_uniffi_bark_ffi_fn_method_wallet_get_exit_vtxos(
|
|
174
|
+
ptr: bigint,
|
|
175
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
176
|
+
): Uint8Array;
|
|
177
|
+
ubrn_uniffi_bark_ffi_fn_method_wallet_get_expiring_vtxos(
|
|
178
|
+
ptr: bigint,
|
|
179
|
+
thresholdBlocks: number,
|
|
180
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
181
|
+
): Uint8Array;
|
|
182
|
+
ubrn_uniffi_bark_ffi_fn_method_wallet_get_first_expiring_vtxo_blockheight(
|
|
183
|
+
ptr: bigint,
|
|
184
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
185
|
+
): Uint8Array;
|
|
186
|
+
ubrn_uniffi_bark_ffi_fn_method_wallet_get_next_required_refresh_blockheight(
|
|
187
|
+
ptr: bigint,
|
|
188
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
189
|
+
): Uint8Array;
|
|
190
|
+
ubrn_uniffi_bark_ffi_fn_method_wallet_get_vtxo_by_id(
|
|
191
|
+
ptr: bigint,
|
|
192
|
+
vtxoId: Uint8Array,
|
|
193
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
194
|
+
): Uint8Array;
|
|
195
|
+
ubrn_uniffi_bark_ffi_fn_method_wallet_get_vtxos_to_refresh(
|
|
196
|
+
ptr: bigint,
|
|
197
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
198
|
+
): Uint8Array;
|
|
199
|
+
ubrn_uniffi_bark_ffi_fn_method_wallet_has_pending_exits(
|
|
200
|
+
ptr: bigint,
|
|
201
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
202
|
+
): number;
|
|
203
|
+
ubrn_uniffi_bark_ffi_fn_method_wallet_history(
|
|
204
|
+
ptr: bigint,
|
|
205
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
206
|
+
): Uint8Array;
|
|
207
|
+
ubrn_uniffi_bark_ffi_fn_method_wallet_lightning_receive_status(
|
|
208
|
+
ptr: bigint,
|
|
209
|
+
paymentHash: Uint8Array,
|
|
210
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
211
|
+
): Uint8Array;
|
|
212
|
+
ubrn_uniffi_bark_ffi_fn_method_wallet_list_claimable_exits(
|
|
213
|
+
ptr: bigint,
|
|
214
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
215
|
+
): Uint8Array;
|
|
216
|
+
ubrn_uniffi_bark_ffi_fn_method_wallet_maintenance(
|
|
217
|
+
ptr: bigint,
|
|
218
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
219
|
+
): void;
|
|
220
|
+
ubrn_uniffi_bark_ffi_fn_method_wallet_maintenance_refresh(
|
|
221
|
+
ptr: bigint,
|
|
222
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
223
|
+
): Uint8Array;
|
|
224
|
+
ubrn_uniffi_bark_ffi_fn_method_wallet_maintenance_with_onchain(
|
|
225
|
+
ptr: bigint,
|
|
226
|
+
onchainWallet: bigint,
|
|
227
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
228
|
+
): void;
|
|
229
|
+
ubrn_uniffi_bark_ffi_fn_method_wallet_maybe_schedule_maintenance_refresh(
|
|
230
|
+
ptr: bigint,
|
|
231
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
232
|
+
): Uint8Array;
|
|
233
|
+
ubrn_uniffi_bark_ffi_fn_method_wallet_new_address(
|
|
234
|
+
ptr: bigint,
|
|
235
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
236
|
+
): Uint8Array;
|
|
237
|
+
ubrn_uniffi_bark_ffi_fn_method_wallet_new_address_with_index(
|
|
238
|
+
ptr: bigint,
|
|
239
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
240
|
+
): Uint8Array;
|
|
241
|
+
ubrn_uniffi_bark_ffi_fn_method_wallet_offboard_all(
|
|
242
|
+
ptr: bigint,
|
|
243
|
+
bitcoinAddress: Uint8Array,
|
|
244
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
245
|
+
): Uint8Array;
|
|
246
|
+
ubrn_uniffi_bark_ffi_fn_method_wallet_offboard_vtxos(
|
|
247
|
+
ptr: bigint,
|
|
248
|
+
vtxoIds: Uint8Array,
|
|
249
|
+
bitcoinAddress: Uint8Array,
|
|
250
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
251
|
+
): Uint8Array;
|
|
252
|
+
ubrn_uniffi_bark_ffi_fn_method_wallet_pay_lightning_address(
|
|
253
|
+
ptr: bigint,
|
|
254
|
+
lightningAddress: Uint8Array,
|
|
255
|
+
amountSats: bigint,
|
|
256
|
+
comment: Uint8Array,
|
|
257
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
258
|
+
): Uint8Array;
|
|
259
|
+
ubrn_uniffi_bark_ffi_fn_method_wallet_pay_lightning_invoice(
|
|
260
|
+
ptr: bigint,
|
|
261
|
+
invoice: Uint8Array,
|
|
262
|
+
amountSats: Uint8Array,
|
|
263
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
264
|
+
): Uint8Array;
|
|
265
|
+
ubrn_uniffi_bark_ffi_fn_method_wallet_pay_lightning_offer(
|
|
266
|
+
ptr: bigint,
|
|
267
|
+
offer: Uint8Array,
|
|
268
|
+
amountSats: Uint8Array,
|
|
269
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
270
|
+
): Uint8Array;
|
|
271
|
+
ubrn_uniffi_bark_ffi_fn_method_wallet_peak_address(
|
|
272
|
+
ptr: bigint,
|
|
273
|
+
index: number,
|
|
274
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
275
|
+
): Uint8Array;
|
|
276
|
+
ubrn_uniffi_bark_ffi_fn_method_wallet_pending_exits_total_sats(
|
|
277
|
+
ptr: bigint,
|
|
278
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
279
|
+
): bigint;
|
|
280
|
+
ubrn_uniffi_bark_ffi_fn_method_wallet_pending_lightning_receives(
|
|
281
|
+
ptr: bigint,
|
|
282
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
283
|
+
): Uint8Array;
|
|
284
|
+
ubrn_uniffi_bark_ffi_fn_method_wallet_pending_lightning_sends(
|
|
285
|
+
ptr: bigint,
|
|
286
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
287
|
+
): Uint8Array;
|
|
288
|
+
ubrn_uniffi_bark_ffi_fn_method_wallet_pending_round_states(
|
|
289
|
+
ptr: bigint,
|
|
290
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
291
|
+
): Uint8Array;
|
|
292
|
+
ubrn_uniffi_bark_ffi_fn_method_wallet_progress_exits(
|
|
293
|
+
ptr: bigint,
|
|
294
|
+
onchainWallet: bigint,
|
|
295
|
+
feeRateSatPerVb: Uint8Array,
|
|
296
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
297
|
+
): Uint8Array;
|
|
298
|
+
ubrn_uniffi_bark_ffi_fn_method_wallet_progress_pending_rounds(
|
|
299
|
+
ptr: bigint,
|
|
300
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
301
|
+
): void;
|
|
302
|
+
ubrn_uniffi_bark_ffi_fn_method_wallet_properties(
|
|
303
|
+
ptr: bigint,
|
|
304
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
305
|
+
): Uint8Array;
|
|
306
|
+
ubrn_uniffi_bark_ffi_fn_method_wallet_refresh_server(
|
|
307
|
+
ptr: bigint,
|
|
308
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
309
|
+
): void;
|
|
310
|
+
ubrn_uniffi_bark_ffi_fn_method_wallet_refresh_vtxos(
|
|
311
|
+
ptr: bigint,
|
|
312
|
+
vtxoIds: Uint8Array,
|
|
313
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
314
|
+
): Uint8Array;
|
|
315
|
+
ubrn_uniffi_bark_ffi_fn_method_wallet_send_arkoor_payment(
|
|
316
|
+
ptr: bigint,
|
|
317
|
+
arkAddress: Uint8Array,
|
|
318
|
+
amountSats: bigint,
|
|
319
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
320
|
+
): Uint8Array;
|
|
321
|
+
ubrn_uniffi_bark_ffi_fn_method_wallet_send_round_onchain_payment(
|
|
322
|
+
ptr: bigint,
|
|
323
|
+
address: Uint8Array,
|
|
324
|
+
amountSats: bigint,
|
|
325
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
326
|
+
): Uint8Array;
|
|
327
|
+
ubrn_uniffi_bark_ffi_fn_method_wallet_sign_exit_claim_inputs(
|
|
328
|
+
ptr: bigint,
|
|
329
|
+
psbtBase64: Uint8Array,
|
|
330
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
331
|
+
): Uint8Array;
|
|
332
|
+
ubrn_uniffi_bark_ffi_fn_method_wallet_spendable_vtxos(
|
|
333
|
+
ptr: bigint,
|
|
334
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
335
|
+
): Uint8Array;
|
|
336
|
+
ubrn_uniffi_bark_ffi_fn_method_wallet_start_exit_for_entire_wallet(
|
|
337
|
+
ptr: bigint,
|
|
338
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
339
|
+
): void;
|
|
340
|
+
ubrn_uniffi_bark_ffi_fn_method_wallet_start_exit_for_vtxos(
|
|
341
|
+
ptr: bigint,
|
|
342
|
+
vtxoIds: Uint8Array,
|
|
343
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
344
|
+
): void;
|
|
345
|
+
ubrn_uniffi_bark_ffi_fn_method_wallet_sync(
|
|
346
|
+
ptr: bigint,
|
|
347
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
348
|
+
): void;
|
|
349
|
+
ubrn_uniffi_bark_ffi_fn_method_wallet_sync_exits(
|
|
350
|
+
ptr: bigint,
|
|
351
|
+
onchainWallet: bigint,
|
|
352
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
353
|
+
): void;
|
|
354
|
+
ubrn_uniffi_bark_ffi_fn_method_wallet_sync_pending_boards(
|
|
355
|
+
ptr: bigint,
|
|
356
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
357
|
+
): void;
|
|
358
|
+
ubrn_uniffi_bark_ffi_fn_method_wallet_try_claim_all_lightning_receives(
|
|
359
|
+
ptr: bigint,
|
|
360
|
+
wait: number,
|
|
361
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
362
|
+
): void;
|
|
363
|
+
ubrn_uniffi_bark_ffi_fn_method_wallet_try_claim_lightning_receive(
|
|
364
|
+
ptr: bigint,
|
|
365
|
+
paymentHash: Uint8Array,
|
|
366
|
+
wait: number,
|
|
367
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
368
|
+
): void;
|
|
369
|
+
ubrn_uniffi_bark_ffi_fn_method_wallet_validate_arkoor_address(
|
|
370
|
+
ptr: bigint,
|
|
371
|
+
address: Uint8Array,
|
|
372
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
373
|
+
): number;
|
|
374
|
+
ubrn_uniffi_bark_ffi_fn_method_wallet_vtxos(
|
|
375
|
+
ptr: bigint,
|
|
376
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
377
|
+
): Uint8Array;
|
|
378
|
+
ubrn_uniffi_bark_ffi_fn_init_callback_vtable_customonchainwalletcallbacks(
|
|
379
|
+
vtable: UniffiVTableCallbackInterfaceCustomOnchainWalletCallbacks
|
|
380
|
+
): void;
|
|
381
|
+
ubrn_uniffi_bark_ffi_fn_func_extract_tx_from_psbt(
|
|
382
|
+
psbtBase64: Uint8Array,
|
|
383
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
384
|
+
): Uint8Array;
|
|
385
|
+
ubrn_uniffi_bark_ffi_fn_func_generate_mnemonic(
|
|
386
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
387
|
+
): Uint8Array;
|
|
388
|
+
ubrn_uniffi_bark_ffi_fn_func_validate_ark_address(
|
|
389
|
+
address: Uint8Array,
|
|
390
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
391
|
+
): number;
|
|
392
|
+
ubrn_uniffi_bark_ffi_fn_func_validate_mnemonic(
|
|
393
|
+
mnemonic: Uint8Array,
|
|
394
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
395
|
+
): number;
|
|
396
|
+
ubrn_uniffi_bark_ffi_checksum_func_extract_tx_from_psbt(): number;
|
|
397
|
+
ubrn_uniffi_bark_ffi_checksum_func_generate_mnemonic(): number;
|
|
398
|
+
ubrn_uniffi_bark_ffi_checksum_func_validate_ark_address(): number;
|
|
399
|
+
ubrn_uniffi_bark_ffi_checksum_func_validate_mnemonic(): number;
|
|
400
|
+
ubrn_uniffi_bark_ffi_checksum_method_onchainwallet_balance(): number;
|
|
401
|
+
ubrn_uniffi_bark_ffi_checksum_method_onchainwallet_new_address(): number;
|
|
402
|
+
ubrn_uniffi_bark_ffi_checksum_method_onchainwallet_send(): number;
|
|
403
|
+
ubrn_uniffi_bark_ffi_checksum_method_onchainwallet_sync(): number;
|
|
404
|
+
ubrn_uniffi_bark_ffi_checksum_method_wallet_all_exits_claimable_at_height(): number;
|
|
405
|
+
ubrn_uniffi_bark_ffi_checksum_method_wallet_all_vtxos(): number;
|
|
406
|
+
ubrn_uniffi_bark_ffi_checksum_method_wallet_ark_info(): number;
|
|
407
|
+
ubrn_uniffi_bark_ffi_checksum_method_wallet_balance(): number;
|
|
408
|
+
ubrn_uniffi_bark_ffi_checksum_method_wallet_board_all(): number;
|
|
409
|
+
ubrn_uniffi_bark_ffi_checksum_method_wallet_board_amount(): number;
|
|
410
|
+
ubrn_uniffi_bark_ffi_checksum_method_wallet_bolt11_invoice(): number;
|
|
411
|
+
ubrn_uniffi_bark_ffi_checksum_method_wallet_broadcast_tx(): number;
|
|
412
|
+
ubrn_uniffi_bark_ffi_checksum_method_wallet_cancel_all_pending_rounds(): number;
|
|
413
|
+
ubrn_uniffi_bark_ffi_checksum_method_wallet_cancel_pending_round(): number;
|
|
414
|
+
ubrn_uniffi_bark_ffi_checksum_method_wallet_check_lightning_payment(): number;
|
|
415
|
+
ubrn_uniffi_bark_ffi_checksum_method_wallet_claimable_lightning_receive_balance_sats(): number;
|
|
416
|
+
ubrn_uniffi_bark_ffi_checksum_method_wallet_config(): number;
|
|
417
|
+
ubrn_uniffi_bark_ffi_checksum_method_wallet_drain_exits(): number;
|
|
418
|
+
ubrn_uniffi_bark_ffi_checksum_method_wallet_get_exit_status(): number;
|
|
419
|
+
ubrn_uniffi_bark_ffi_checksum_method_wallet_get_exit_vtxos(): number;
|
|
420
|
+
ubrn_uniffi_bark_ffi_checksum_method_wallet_get_expiring_vtxos(): number;
|
|
421
|
+
ubrn_uniffi_bark_ffi_checksum_method_wallet_get_first_expiring_vtxo_blockheight(): number;
|
|
422
|
+
ubrn_uniffi_bark_ffi_checksum_method_wallet_get_next_required_refresh_blockheight(): number;
|
|
423
|
+
ubrn_uniffi_bark_ffi_checksum_method_wallet_get_vtxo_by_id(): number;
|
|
424
|
+
ubrn_uniffi_bark_ffi_checksum_method_wallet_get_vtxos_to_refresh(): number;
|
|
425
|
+
ubrn_uniffi_bark_ffi_checksum_method_wallet_has_pending_exits(): number;
|
|
426
|
+
ubrn_uniffi_bark_ffi_checksum_method_wallet_history(): number;
|
|
427
|
+
ubrn_uniffi_bark_ffi_checksum_method_wallet_lightning_receive_status(): number;
|
|
428
|
+
ubrn_uniffi_bark_ffi_checksum_method_wallet_list_claimable_exits(): number;
|
|
429
|
+
ubrn_uniffi_bark_ffi_checksum_method_wallet_maintenance(): number;
|
|
430
|
+
ubrn_uniffi_bark_ffi_checksum_method_wallet_maintenance_refresh(): number;
|
|
431
|
+
ubrn_uniffi_bark_ffi_checksum_method_wallet_maintenance_with_onchain(): number;
|
|
432
|
+
ubrn_uniffi_bark_ffi_checksum_method_wallet_maybe_schedule_maintenance_refresh(): number;
|
|
433
|
+
ubrn_uniffi_bark_ffi_checksum_method_wallet_new_address(): number;
|
|
434
|
+
ubrn_uniffi_bark_ffi_checksum_method_wallet_new_address_with_index(): number;
|
|
435
|
+
ubrn_uniffi_bark_ffi_checksum_method_wallet_offboard_all(): number;
|
|
436
|
+
ubrn_uniffi_bark_ffi_checksum_method_wallet_offboard_vtxos(): number;
|
|
437
|
+
ubrn_uniffi_bark_ffi_checksum_method_wallet_pay_lightning_address(): number;
|
|
438
|
+
ubrn_uniffi_bark_ffi_checksum_method_wallet_pay_lightning_invoice(): number;
|
|
439
|
+
ubrn_uniffi_bark_ffi_checksum_method_wallet_pay_lightning_offer(): number;
|
|
440
|
+
ubrn_uniffi_bark_ffi_checksum_method_wallet_peak_address(): number;
|
|
441
|
+
ubrn_uniffi_bark_ffi_checksum_method_wallet_pending_exits_total_sats(): number;
|
|
442
|
+
ubrn_uniffi_bark_ffi_checksum_method_wallet_pending_lightning_receives(): number;
|
|
443
|
+
ubrn_uniffi_bark_ffi_checksum_method_wallet_pending_lightning_sends(): number;
|
|
444
|
+
ubrn_uniffi_bark_ffi_checksum_method_wallet_pending_round_states(): number;
|
|
445
|
+
ubrn_uniffi_bark_ffi_checksum_method_wallet_progress_exits(): number;
|
|
446
|
+
ubrn_uniffi_bark_ffi_checksum_method_wallet_progress_pending_rounds(): number;
|
|
447
|
+
ubrn_uniffi_bark_ffi_checksum_method_wallet_properties(): number;
|
|
448
|
+
ubrn_uniffi_bark_ffi_checksum_method_wallet_refresh_server(): number;
|
|
449
|
+
ubrn_uniffi_bark_ffi_checksum_method_wallet_refresh_vtxos(): number;
|
|
450
|
+
ubrn_uniffi_bark_ffi_checksum_method_wallet_send_arkoor_payment(): number;
|
|
451
|
+
ubrn_uniffi_bark_ffi_checksum_method_wallet_send_round_onchain_payment(): number;
|
|
452
|
+
ubrn_uniffi_bark_ffi_checksum_method_wallet_sign_exit_claim_inputs(): number;
|
|
453
|
+
ubrn_uniffi_bark_ffi_checksum_method_wallet_spendable_vtxos(): number;
|
|
454
|
+
ubrn_uniffi_bark_ffi_checksum_method_wallet_start_exit_for_entire_wallet(): number;
|
|
455
|
+
ubrn_uniffi_bark_ffi_checksum_method_wallet_start_exit_for_vtxos(): number;
|
|
456
|
+
ubrn_uniffi_bark_ffi_checksum_method_wallet_sync(): number;
|
|
457
|
+
ubrn_uniffi_bark_ffi_checksum_method_wallet_sync_exits(): number;
|
|
458
|
+
ubrn_uniffi_bark_ffi_checksum_method_wallet_sync_pending_boards(): number;
|
|
459
|
+
ubrn_uniffi_bark_ffi_checksum_method_wallet_try_claim_all_lightning_receives(): number;
|
|
460
|
+
ubrn_uniffi_bark_ffi_checksum_method_wallet_try_claim_lightning_receive(): number;
|
|
461
|
+
ubrn_uniffi_bark_ffi_checksum_method_wallet_validate_arkoor_address(): number;
|
|
462
|
+
ubrn_uniffi_bark_ffi_checksum_method_wallet_vtxos(): number;
|
|
463
|
+
ubrn_uniffi_bark_ffi_checksum_constructor_onchainwallet_custom(): number;
|
|
464
|
+
ubrn_uniffi_bark_ffi_checksum_constructor_onchainwallet_default(): number;
|
|
465
|
+
ubrn_uniffi_bark_ffi_checksum_constructor_wallet_create(): number;
|
|
466
|
+
ubrn_uniffi_bark_ffi_checksum_constructor_wallet_create_with_onchain(): number;
|
|
467
|
+
ubrn_uniffi_bark_ffi_checksum_constructor_wallet_open(): number;
|
|
468
|
+
ubrn_uniffi_bark_ffi_checksum_constructor_wallet_open_with_onchain(): number;
|
|
469
|
+
ubrn_uniffi_bark_ffi_checksum_method_customonchainwalletcallbacks_get_balance(): number;
|
|
470
|
+
ubrn_uniffi_bark_ffi_checksum_method_customonchainwalletcallbacks_prepare_tx(): number;
|
|
471
|
+
ubrn_uniffi_bark_ffi_checksum_method_customonchainwalletcallbacks_prepare_drain_tx(): number;
|
|
472
|
+
ubrn_uniffi_bark_ffi_checksum_method_customonchainwalletcallbacks_finish_tx(): number;
|
|
473
|
+
ubrn_uniffi_bark_ffi_checksum_method_customonchainwalletcallbacks_get_wallet_tx(): number;
|
|
474
|
+
ubrn_uniffi_bark_ffi_checksum_method_customonchainwalletcallbacks_get_wallet_tx_confirmed_block(): number;
|
|
475
|
+
ubrn_uniffi_bark_ffi_checksum_method_customonchainwalletcallbacks_get_spending_tx(): number;
|
|
476
|
+
ubrn_uniffi_bark_ffi_checksum_method_customonchainwalletcallbacks_make_signed_p2a_cpfp(): number;
|
|
477
|
+
ubrn_uniffi_bark_ffi_checksum_method_customonchainwalletcallbacks_store_signed_p2a_cpfp(): number;
|
|
478
|
+
ubrn_ffi_bark_ffi_uniffi_contract_version(): number;
|
|
479
|
+
ubrn_uniffi_internal_fn_method_onchainwallet_ffi__bless_pointer(
|
|
480
|
+
pointer: bigint,
|
|
481
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
482
|
+
): UniffiRustArcPtr;
|
|
483
|
+
ubrn_uniffi_internal_fn_method_wallet_ffi__bless_pointer(
|
|
484
|
+
pointer: bigint,
|
|
485
|
+
uniffi_out_err: UniffiRustCallStatus
|
|
486
|
+
): UniffiRustArcPtr;
|
|
487
|
+
}
|
|
488
|
+
|
|
489
|
+
// Casting globalThis to any allows us to look for `NativeBark`
|
|
490
|
+
// if it was added via JSI.
|
|
491
|
+
//
|
|
492
|
+
// We use a getter here rather than simply `globalThis.NativeBark` so that
|
|
493
|
+
// if/when the startup sequence isn't just so, an empty value isn't inadvertantly cached.
|
|
494
|
+
const getter: () => NativeModuleInterface = () =>
|
|
495
|
+
(globalThis as any).NativeBark;
|
|
496
|
+
export default getter;
|
|
497
|
+
|
|
498
|
+
// Structs and function types for calling back into Typescript from Rust.
|
|
499
|
+
export type UniffiRustFutureContinuationCallback = (
|
|
500
|
+
data: bigint,
|
|
501
|
+
pollResult: number
|
|
502
|
+
) => void;
|
|
503
|
+
type UniffiForeignFutureFree = (handle: bigint) => void;
|
|
504
|
+
type UniffiCallbackInterfaceFree = (handle: bigint) => void;
|
|
505
|
+
export type UniffiForeignFuture = {
|
|
506
|
+
handle: bigint;
|
|
507
|
+
free: UniffiForeignFutureFree;
|
|
508
|
+
};
|
|
509
|
+
export type UniffiForeignFutureStructU8 = {
|
|
510
|
+
returnValue: number;
|
|
511
|
+
callStatus: UniffiRustCallStatus;
|
|
512
|
+
};
|
|
513
|
+
export type UniffiForeignFutureCompleteU8 = (
|
|
514
|
+
callbackData: bigint,
|
|
515
|
+
result: UniffiForeignFutureStructU8
|
|
516
|
+
) => void;
|
|
517
|
+
export type UniffiForeignFutureStructI8 = {
|
|
518
|
+
returnValue: number;
|
|
519
|
+
callStatus: UniffiRustCallStatus;
|
|
520
|
+
};
|
|
521
|
+
export type UniffiForeignFutureCompleteI8 = (
|
|
522
|
+
callbackData: bigint,
|
|
523
|
+
result: UniffiForeignFutureStructI8
|
|
524
|
+
) => void;
|
|
525
|
+
export type UniffiForeignFutureStructU16 = {
|
|
526
|
+
returnValue: number;
|
|
527
|
+
callStatus: UniffiRustCallStatus;
|
|
528
|
+
};
|
|
529
|
+
export type UniffiForeignFutureCompleteU16 = (
|
|
530
|
+
callbackData: bigint,
|
|
531
|
+
result: UniffiForeignFutureStructU16
|
|
532
|
+
) => void;
|
|
533
|
+
export type UniffiForeignFutureStructI16 = {
|
|
534
|
+
returnValue: number;
|
|
535
|
+
callStatus: UniffiRustCallStatus;
|
|
536
|
+
};
|
|
537
|
+
export type UniffiForeignFutureCompleteI16 = (
|
|
538
|
+
callbackData: bigint,
|
|
539
|
+
result: UniffiForeignFutureStructI16
|
|
540
|
+
) => void;
|
|
541
|
+
export type UniffiForeignFutureStructU32 = {
|
|
542
|
+
returnValue: number;
|
|
543
|
+
callStatus: UniffiRustCallStatus;
|
|
544
|
+
};
|
|
545
|
+
export type UniffiForeignFutureCompleteU32 = (
|
|
546
|
+
callbackData: bigint,
|
|
547
|
+
result: UniffiForeignFutureStructU32
|
|
548
|
+
) => void;
|
|
549
|
+
export type UniffiForeignFutureStructI32 = {
|
|
550
|
+
returnValue: number;
|
|
551
|
+
callStatus: UniffiRustCallStatus;
|
|
552
|
+
};
|
|
553
|
+
export type UniffiForeignFutureCompleteI32 = (
|
|
554
|
+
callbackData: bigint,
|
|
555
|
+
result: UniffiForeignFutureStructI32
|
|
556
|
+
) => void;
|
|
557
|
+
export type UniffiForeignFutureStructU64 = {
|
|
558
|
+
returnValue: bigint;
|
|
559
|
+
callStatus: UniffiRustCallStatus;
|
|
560
|
+
};
|
|
561
|
+
export type UniffiForeignFutureCompleteU64 = (
|
|
562
|
+
callbackData: bigint,
|
|
563
|
+
result: UniffiForeignFutureStructU64
|
|
564
|
+
) => void;
|
|
565
|
+
export type UniffiForeignFutureStructI64 = {
|
|
566
|
+
returnValue: bigint;
|
|
567
|
+
callStatus: UniffiRustCallStatus;
|
|
568
|
+
};
|
|
569
|
+
export type UniffiForeignFutureCompleteI64 = (
|
|
570
|
+
callbackData: bigint,
|
|
571
|
+
result: UniffiForeignFutureStructI64
|
|
572
|
+
) => void;
|
|
573
|
+
export type UniffiForeignFutureStructF32 = {
|
|
574
|
+
returnValue: number;
|
|
575
|
+
callStatus: UniffiRustCallStatus;
|
|
576
|
+
};
|
|
577
|
+
export type UniffiForeignFutureCompleteF32 = (
|
|
578
|
+
callbackData: bigint,
|
|
579
|
+
result: UniffiForeignFutureStructF32
|
|
580
|
+
) => void;
|
|
581
|
+
export type UniffiForeignFutureStructF64 = {
|
|
582
|
+
returnValue: number;
|
|
583
|
+
callStatus: UniffiRustCallStatus;
|
|
584
|
+
};
|
|
585
|
+
export type UniffiForeignFutureCompleteF64 = (
|
|
586
|
+
callbackData: bigint,
|
|
587
|
+
result: UniffiForeignFutureStructF64
|
|
588
|
+
) => void;
|
|
589
|
+
export type UniffiForeignFutureStructPointer = {
|
|
590
|
+
returnValue: bigint;
|
|
591
|
+
callStatus: UniffiRustCallStatus;
|
|
592
|
+
};
|
|
593
|
+
export type UniffiForeignFutureCompletePointer = (
|
|
594
|
+
callbackData: bigint,
|
|
595
|
+
result: UniffiForeignFutureStructPointer
|
|
596
|
+
) => void;
|
|
597
|
+
export type UniffiForeignFutureStructRustBuffer = {
|
|
598
|
+
returnValue: Uint8Array;
|
|
599
|
+
callStatus: UniffiRustCallStatus;
|
|
600
|
+
};
|
|
601
|
+
export type UniffiForeignFutureCompleteRustBuffer = (
|
|
602
|
+
callbackData: bigint,
|
|
603
|
+
result: UniffiForeignFutureStructRustBuffer
|
|
604
|
+
) => void;
|
|
605
|
+
export type UniffiForeignFutureStructVoid = {
|
|
606
|
+
callStatus: UniffiRustCallStatus;
|
|
607
|
+
};
|
|
608
|
+
export type UniffiForeignFutureCompleteVoid = (
|
|
609
|
+
callbackData: bigint,
|
|
610
|
+
result: UniffiForeignFutureStructVoid
|
|
611
|
+
) => void;
|
|
612
|
+
type UniffiCallbackInterfaceCustomOnchainWalletCallbacksMethod0 = (
|
|
613
|
+
uniffiHandle: bigint
|
|
614
|
+
) => UniffiResult<bigint>;
|
|
615
|
+
type UniffiCallbackInterfaceCustomOnchainWalletCallbacksMethod1 = (
|
|
616
|
+
uniffiHandle: bigint,
|
|
617
|
+
destinations: Uint8Array,
|
|
618
|
+
feeRateSatPerVb: bigint
|
|
619
|
+
) => UniffiResult<Uint8Array>;
|
|
620
|
+
type UniffiCallbackInterfaceCustomOnchainWalletCallbacksMethod2 = (
|
|
621
|
+
uniffiHandle: bigint,
|
|
622
|
+
address: Uint8Array,
|
|
623
|
+
feeRateSatPerVb: bigint
|
|
624
|
+
) => UniffiResult<Uint8Array>;
|
|
625
|
+
type UniffiCallbackInterfaceCustomOnchainWalletCallbacksMethod3 = (
|
|
626
|
+
uniffiHandle: bigint,
|
|
627
|
+
psbtBase64: Uint8Array
|
|
628
|
+
) => UniffiResult<Uint8Array>;
|
|
629
|
+
type UniffiCallbackInterfaceCustomOnchainWalletCallbacksMethod4 = (
|
|
630
|
+
uniffiHandle: bigint,
|
|
631
|
+
txid: Uint8Array
|
|
632
|
+
) => UniffiResult<Uint8Array>;
|
|
633
|
+
type UniffiCallbackInterfaceCustomOnchainWalletCallbacksMethod5 = (
|
|
634
|
+
uniffiHandle: bigint,
|
|
635
|
+
txid: Uint8Array
|
|
636
|
+
) => UniffiResult<Uint8Array>;
|
|
637
|
+
type UniffiCallbackInterfaceCustomOnchainWalletCallbacksMethod6 = (
|
|
638
|
+
uniffiHandle: bigint,
|
|
639
|
+
outpoint: Uint8Array
|
|
640
|
+
) => UniffiResult<Uint8Array>;
|
|
641
|
+
type UniffiCallbackInterfaceCustomOnchainWalletCallbacksMethod7 = (
|
|
642
|
+
uniffiHandle: bigint,
|
|
643
|
+
params: Uint8Array
|
|
644
|
+
) => UniffiResult<Uint8Array>;
|
|
645
|
+
type UniffiCallbackInterfaceCustomOnchainWalletCallbacksMethod8 = (
|
|
646
|
+
uniffiHandle: bigint,
|
|
647
|
+
txHex: Uint8Array
|
|
648
|
+
) => UniffiResult<void>;
|
|
649
|
+
export type UniffiVTableCallbackInterfaceCustomOnchainWalletCallbacks = {
|
|
650
|
+
getBalance: UniffiCallbackInterfaceCustomOnchainWalletCallbacksMethod0;
|
|
651
|
+
prepareTx: UniffiCallbackInterfaceCustomOnchainWalletCallbacksMethod1;
|
|
652
|
+
prepareDrainTx: UniffiCallbackInterfaceCustomOnchainWalletCallbacksMethod2;
|
|
653
|
+
finishTx: UniffiCallbackInterfaceCustomOnchainWalletCallbacksMethod3;
|
|
654
|
+
getWalletTx: UniffiCallbackInterfaceCustomOnchainWalletCallbacksMethod4;
|
|
655
|
+
getWalletTxConfirmedBlock: UniffiCallbackInterfaceCustomOnchainWalletCallbacksMethod5;
|
|
656
|
+
getSpendingTx: UniffiCallbackInterfaceCustomOnchainWalletCallbacksMethod6;
|
|
657
|
+
makeSignedP2aCpfp: UniffiCallbackInterfaceCustomOnchainWalletCallbacksMethod7;
|
|
658
|
+
storeSignedP2aCpfp: UniffiCallbackInterfaceCustomOnchainWalletCallbacksMethod8;
|
|
659
|
+
uniffiFree: UniffiCallbackInterfaceFree;
|
|
660
|
+
};
|
|
661
|
+
|
|
662
|
+
// UniffiRustFutureContinuationCallback is generated as part of the component interface's
|
|
663
|
+
// ffi_definitions. However, we need it in the runtime.
|
|
664
|
+
// We could:
|
|
665
|
+
// (a) do some complicated template logic to ensure the declaration is not generated here (possible)
|
|
666
|
+
// (b) import the generated declaration into the runtime (m a y b e) or…
|
|
667
|
+
// (c) generate the declaration anyway, and use a different declaration in the runtime.
|
|
668
|
+
//
|
|
669
|
+
// We chose (c) here as the simplest. In addition, we perform a compile time check that
|
|
670
|
+
// the two versions of `UniffiRustFutureContinuationCallback` are structurally equivalent.
|
|
671
|
+
//
|
|
672
|
+
// If you see the error:
|
|
673
|
+
// ```
|
|
674
|
+
// Type 'true' is not assignable to type 'false'.(2322)
|
|
675
|
+
// ```
|
|
676
|
+
// Then a new version of uniffi has changed the signature of the callback. Most likely, code in
|
|
677
|
+
// `typescript/src/async-rust-call.ts` will need to be changed.
|
|
678
|
+
//
|
|
679
|
+
// If you see the error:
|
|
680
|
+
// ```
|
|
681
|
+
// Cannot find name 'UniffiRustFutureContinuationCallback'. Did you mean 'RuntimeUniffiRustFutureContinuationCallback'?(2552)
|
|
682
|
+
// ```
|
|
683
|
+
// then you may not be using callbacks or promises, and uniffi is now not generating Futures and callbacks.
|
|
684
|
+
// You should not generate this if that is the case.
|
|
685
|
+
//
|
|
686
|
+
// ('You' being the bindings generator maintainer).
|
|
687
|
+
const isRustFutureContinuationCallbackTypeCompatible: UniffiStructuralEquality<
|
|
688
|
+
RuntimeUniffiRustFutureContinuationCallback,
|
|
689
|
+
UniffiRustFutureContinuationCallback
|
|
690
|
+
> = true;
|
|
691
|
+
const isUniffiForeignFutureTypeCompatible: UniffiStructuralEquality<
|
|
692
|
+
RuntimeUniffiForeignFuture,
|
|
693
|
+
UniffiForeignFuture
|
|
694
|
+
> = true;
|