react-native-bdk-sdk 0.1.4 → 0.1.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/cpp/generated/bdk_ffi.cpp +345 -12
- package/cpp/generated/bdk_ffi.hpp +17 -0
- package/lib/commonjs/generated/bdk_ffi-ffi.js.map +1 -1
- package/lib/commonjs/generated/bdk_ffi.js +1946 -1266
- package/lib/commonjs/generated/bdk_ffi.js.map +1 -1
- package/lib/commonjs/index.js +14 -0
- package/lib/commonjs/index.js.map +1 -1
- package/lib/commonjs/wrapper.js +433 -0
- package/lib/commonjs/wrapper.js.map +1 -0
- package/lib/module/generated/bdk_ffi-ffi.js.map +1 -1
- package/lib/module/generated/bdk_ffi.js +1941 -1266
- package/lib/module/generated/bdk_ffi.js.map +1 -1
- package/lib/module/index.js +3 -0
- package/lib/module/index.js.map +1 -1
- package/lib/module/wrapper.js +427 -0
- package/lib/module/wrapper.js.map +1 -0
- package/lib/typescript/commonjs/src/generated/bdk_ffi-ffi.d.ts +21 -4
- package/lib/typescript/commonjs/src/generated/bdk_ffi-ffi.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/generated/bdk_ffi.d.ts +3372 -1829
- package/lib/typescript/commonjs/src/generated/bdk_ffi.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/index.d.ts +1 -0
- package/lib/typescript/commonjs/src/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/wrapper.d.ts +168 -0
- package/lib/typescript/commonjs/src/wrapper.d.ts.map +1 -0
- package/lib/typescript/module/src/generated/bdk_ffi-ffi.d.ts +21 -4
- package/lib/typescript/module/src/generated/bdk_ffi-ffi.d.ts.map +1 -1
- package/lib/typescript/module/src/generated/bdk_ffi.d.ts +3372 -1829
- package/lib/typescript/module/src/generated/bdk_ffi.d.ts.map +1 -1
- package/lib/typescript/module/src/index.d.ts +1 -0
- package/lib/typescript/module/src/index.d.ts.map +1 -1
- package/lib/typescript/module/src/wrapper.d.ts +168 -0
- package/lib/typescript/module/src/wrapper.d.ts.map +1 -0
- package/package.json +3 -3
- package/src/generated/bdk_ffi-ffi.ts +63 -5
- package/src/generated/bdk_ffi.ts +2743 -1692
- package/src/index.tsx +3 -0
- package/src/wrapper.ts +614 -0
|
@@ -3,13 +3,17 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
exports.WordCount = exports.WalletEvent_Tags = exports.WalletEvent = exports.Wallet = exports.TxOut = exports.TxOrdering = exports.TxDetails = exports.TxBuilder = exports.SingleKeyDescriptorTemplate = exports.SentAndReceived = exports.Recipient = exports.Psbt = exports.OutPoint = exports.Network = exports.Mnemonic = exports.LocalOutput = exports.Language = exports.KeychainKind = exports.KeychainInfo = exports.DescriptorTemplate = exports.DerivationInfo = exports.ConfirmationBlockTime = exports.ChangeSpendPolicy = exports.BlockId = exports.BdkError_Tags = exports.BdkError = exports.Balance = exports.AddressInfo = void 0;
|
|
6
|
+
exports.WordCount = exports.WalletEvent_Tags = exports.WalletEvent = exports.Wallet = exports.TxOutput = exports.TxOut = exports.TxOrdering = exports.TxInput = exports.TxDetails = exports.TxBuilder = exports.SingleKeyDescriptorTemplate = exports.SentAndReceived = exports.Recipient = exports.Psbt = exports.OutPoint = exports.Network = exports.Mnemonic = exports.LocalOutput = exports.Language = exports.KeychainKind = exports.KeychainInfo = exports.ElectrumClient = exports.DescriptorTemplate = exports.DerivationInfo = exports.ConfirmationBlockTime = exports.ChangeSpendPolicy = exports.BlockId = exports.BdkError_Tags = exports.BdkError = exports.Balance = exports.AddressInfo = void 0;
|
|
7
|
+
exports.addressFromScript = addressFromScript;
|
|
7
8
|
exports.createDescriptor = createDescriptor;
|
|
9
|
+
exports.createDescriptorFromString = createDescriptorFromString;
|
|
8
10
|
exports.createPublicDescriptor = createPublicDescriptor;
|
|
9
11
|
exports.createSingleKeyDescriptor = createSingleKeyDescriptor;
|
|
12
|
+
exports.createWallet = createWallet;
|
|
10
13
|
exports.default = void 0;
|
|
11
14
|
exports.exportWallet = exportWallet;
|
|
12
15
|
exports.isValidAddress = isValidAddress;
|
|
16
|
+
exports.validateDescriptor = validateDescriptor;
|
|
13
17
|
exports.version = version;
|
|
14
18
|
exports.walletNameFromDescriptor = walletNameFromDescriptor;
|
|
15
19
|
var _bdk_ffiFfi = _interopRequireDefault(require("./bdk_ffi-ffi.js"));
|
|
@@ -33,10 +37,16 @@ typeof process !== "object" ||
|
|
|
33
37
|
process?.env?.NODE_ENV !== "production" || false;
|
|
34
38
|
// Public interface members begin here.
|
|
35
39
|
|
|
40
|
+
/**
|
|
41
|
+
* Convert a scriptPubKey (hex) to an address string for the given network.
|
|
42
|
+
*/
|
|
43
|
+
function addressFromScript(scriptHex, network) /*throws*/{
|
|
44
|
+
return FfiConverterString.lift(uniffiCaller.rustCallWithError(/*liftError:*/FfiConverterTypeBdkError.lift.bind(FfiConverterTypeBdkError), /*caller:*/callStatus => {
|
|
45
|
+
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_func_address_from_script(FfiConverterString.lower(scriptHex), FfiConverterTypeNetwork.lower(network), callStatus);
|
|
46
|
+
}, /*liftString:*/FfiConverterString.lift));
|
|
47
|
+
}
|
|
36
48
|
/**
|
|
37
49
|
* Generate an output descriptor string from a mnemonic using a standard BIP template.
|
|
38
|
-
* Returns a descriptor like "wpkh([fingerprint/84'/0'/0']xprv.../0/*)" for BIP84.
|
|
39
|
-
* Uses Bip44/49/84/86 descriptor templates.
|
|
40
50
|
*/
|
|
41
51
|
function createDescriptor(mnemonic, template, keychain, network) /*throws*/{
|
|
42
52
|
return FfiConverterString.lift(uniffiCaller.rustCallWithError(/*liftError:*/FfiConverterTypeBdkError.lift.bind(FfiConverterTypeBdkError), /*caller:*/callStatus => {
|
|
@@ -44,9 +54,15 @@ function createDescriptor(mnemonic, template, keychain, network) /*throws*/{
|
|
|
44
54
|
}, /*liftString:*/FfiConverterString.lift));
|
|
45
55
|
}
|
|
46
56
|
/**
|
|
47
|
-
* Generate
|
|
48
|
-
|
|
49
|
-
|
|
57
|
+
* Generate an output descriptor from a mnemonic string directly (convenience).
|
|
58
|
+
*/
|
|
59
|
+
function createDescriptorFromString(mnemonic, template, keychain, network) /*throws*/{
|
|
60
|
+
return FfiConverterString.lift(uniffiCaller.rustCallWithError(/*liftError:*/FfiConverterTypeBdkError.lift.bind(FfiConverterTypeBdkError), /*caller:*/callStatus => {
|
|
61
|
+
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_func_create_descriptor_from_string(FfiConverterString.lower(mnemonic), FfiConverterTypeDescriptorTemplate.lower(template), FfiConverterTypeKeychainKind.lower(keychain), FfiConverterTypeNetwork.lower(network), callStatus);
|
|
62
|
+
}, /*liftString:*/FfiConverterString.lift));
|
|
63
|
+
}
|
|
64
|
+
/**
|
|
65
|
+
* Generate a public (watch-only) descriptor from an xpub string.
|
|
50
66
|
*/
|
|
51
67
|
function createPublicDescriptor(xpub, template, keychain, network) /*throws*/{
|
|
52
68
|
return FfiConverterString.lift(uniffiCaller.rustCallWithError(/*liftError:*/FfiConverterTypeBdkError.lift.bind(FfiConverterTypeBdkError), /*caller:*/callStatus => {
|
|
@@ -55,16 +71,31 @@ function createPublicDescriptor(xpub, template, keychain, network) /*throws*/{
|
|
|
55
71
|
}
|
|
56
72
|
/**
|
|
57
73
|
* Generate a single-key descriptor from a key string.
|
|
58
|
-
* Uses P2Pkh, P2Wpkh, P2Wpkh_P2Sh, or P2TR templates.
|
|
59
74
|
*/
|
|
60
75
|
function createSingleKeyDescriptor(key, template, network) /*throws*/{
|
|
61
76
|
return FfiConverterString.lift(uniffiCaller.rustCallWithError(/*liftError:*/FfiConverterTypeBdkError.lift.bind(FfiConverterTypeBdkError), /*caller:*/callStatus => {
|
|
62
77
|
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_func_create_single_key_descriptor(FfiConverterString.lower(key), FfiConverterTypeSingleKeyDescriptorTemplate.lower(template), FfiConverterTypeNetwork.lower(network), callStatus);
|
|
63
78
|
}, /*liftString:*/FfiConverterString.lift));
|
|
64
79
|
}
|
|
80
|
+
/**
|
|
81
|
+
* Async wallet factory — creates or loads a wallet without blocking the JS thread.
|
|
82
|
+
* Pass null for change_descriptor to use the main descriptor for both keychains.
|
|
83
|
+
*/
|
|
84
|
+
async function createWallet(descriptor, changeDescriptor, network, dbPath, asyncOpts_) /*throws*/{
|
|
85
|
+
const __stack = uniffiIsDebug ? new Error().stack : undefined;
|
|
86
|
+
try {
|
|
87
|
+
return await (0, _uniffiBindgenReactNative.uniffiRustCallAsync)(/*rustCaller:*/uniffiCaller, /*rustFutureFunc:*/() => {
|
|
88
|
+
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_func_create_wallet(FfiConverterString.lower(descriptor), FfiConverterOptionalString.lower(changeDescriptor), FfiConverterTypeNetwork.lower(network), FfiConverterString.lower(dbPath));
|
|
89
|
+
}, /*pollFunc:*/(0, _bdk_ffiFfi.default)().ubrn_ffi_bdk_ffi_rust_future_poll_u64, /*cancelFunc:*/(0, _bdk_ffiFfi.default)().ubrn_ffi_bdk_ffi_rust_future_cancel_u64, /*completeFunc:*/(0, _bdk_ffiFfi.default)().ubrn_ffi_bdk_ffi_rust_future_complete_u64, /*freeFunc:*/(0, _bdk_ffiFfi.default)().ubrn_ffi_bdk_ffi_rust_future_free_u64, /*liftFunc:*/FfiConverterTypeWallet.lift.bind(FfiConverterTypeWallet), /*liftString:*/FfiConverterString.lift, /*asyncOpts:*/asyncOpts_, /*errorHandler:*/FfiConverterTypeBdkError.lift.bind(FfiConverterTypeBdkError));
|
|
90
|
+
} catch (__error) {
|
|
91
|
+
if (uniffiIsDebug && __error instanceof Error) {
|
|
92
|
+
__error.stack = __stack;
|
|
93
|
+
}
|
|
94
|
+
throw __error;
|
|
95
|
+
}
|
|
96
|
+
}
|
|
65
97
|
/**
|
|
66
98
|
* Export a wallet in FullyNoded-compatible JSON format for backup.
|
|
67
|
-
* Mirrors bdk_wallet::export::FullyNodedExport.
|
|
68
99
|
*/
|
|
69
100
|
function exportWallet(wallet, label, includeBlockHeight) /*throws*/{
|
|
70
101
|
return FfiConverterString.lift(uniffiCaller.rustCallWithError(/*liftError:*/FfiConverterTypeBdkError.lift.bind(FfiConverterTypeBdkError), /*caller:*/callStatus => {
|
|
@@ -79,6 +110,14 @@ function isValidAddress(address, network) {
|
|
|
79
110
|
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_func_is_valid_address(FfiConverterString.lower(address), FfiConverterTypeNetwork.lower(network), callStatus);
|
|
80
111
|
}, /*liftString:*/FfiConverterString.lift));
|
|
81
112
|
}
|
|
113
|
+
/**
|
|
114
|
+
* Validate a descriptor string for the given network without creating a wallet.
|
|
115
|
+
*/
|
|
116
|
+
function validateDescriptor(descriptor, network) {
|
|
117
|
+
return _uniffiBindgenReactNative.FfiConverterBool.lift(uniffiCaller.rustCall(/*caller:*/callStatus => {
|
|
118
|
+
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_func_validate_descriptor(FfiConverterString.lower(descriptor), FfiConverterTypeNetwork.lower(network), callStatus);
|
|
119
|
+
}, /*liftString:*/FfiConverterString.lift));
|
|
120
|
+
}
|
|
82
121
|
/**
|
|
83
122
|
* Runtime version of the bdk_wallet crate.
|
|
84
123
|
*/
|
|
@@ -88,19 +127,13 @@ function version() {
|
|
|
88
127
|
}, /*liftString:*/FfiConverterString.lift));
|
|
89
128
|
}
|
|
90
129
|
/**
|
|
91
|
-
* Compute a deterministic wallet name from its descriptors
|
|
92
|
-
* Mirrors bdk_wallet::wallet_name_from_descriptor().
|
|
130
|
+
* Compute a deterministic wallet name from its descriptors.
|
|
93
131
|
*/
|
|
94
132
|
function walletNameFromDescriptor(descriptor, changeDescriptor, network) /*throws*/{
|
|
95
133
|
return FfiConverterString.lift(uniffiCaller.rustCallWithError(/*liftError:*/FfiConverterTypeBdkError.lift.bind(FfiConverterTypeBdkError), /*caller:*/callStatus => {
|
|
96
134
|
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_func_wallet_name_from_descriptor(FfiConverterString.lower(descriptor), FfiConverterOptionalString.lower(changeDescriptor), FfiConverterTypeNetwork.lower(network), callStatus);
|
|
97
135
|
}, /*liftString:*/FfiConverterString.lift));
|
|
98
136
|
}
|
|
99
|
-
|
|
100
|
-
/**
|
|
101
|
-
* A derived address with its derivation index. Mirrors bdk_wallet::AddressInfo.
|
|
102
|
-
*/
|
|
103
|
-
|
|
104
137
|
/**
|
|
105
138
|
* Generated factory for {@link AddressInfo} record objects.
|
|
106
139
|
*/
|
|
@@ -135,12 +168,6 @@ const FfiConverterTypeAddressInfo = (() => {
|
|
|
135
168
|
}
|
|
136
169
|
return new FFIConverter();
|
|
137
170
|
})();
|
|
138
|
-
|
|
139
|
-
/**
|
|
140
|
-
* Wallet balance split into categories. All values in satoshis.
|
|
141
|
-
* Mirrors bdk_wallet::Balance (re-exported from bdk_chain).
|
|
142
|
-
*/
|
|
143
|
-
|
|
144
171
|
/**
|
|
145
172
|
* Generated factory for {@link Balance} record objects.
|
|
146
173
|
*/
|
|
@@ -181,11 +208,6 @@ const FfiConverterTypeBalance = (() => {
|
|
|
181
208
|
}
|
|
182
209
|
return new FFIConverter();
|
|
183
210
|
})();
|
|
184
|
-
|
|
185
|
-
/**
|
|
186
|
-
* A block identifier (height + hash). Mirrors bdk_chain::BlockId.
|
|
187
|
-
*/
|
|
188
|
-
|
|
189
211
|
/**
|
|
190
212
|
* Generated factory for {@link BlockId} record objects.
|
|
191
213
|
*/
|
|
@@ -218,12 +240,6 @@ const FfiConverterTypeBlockId = (() => {
|
|
|
218
240
|
}
|
|
219
241
|
return new FFIConverter();
|
|
220
242
|
})();
|
|
221
|
-
|
|
222
|
-
/**
|
|
223
|
-
* Block position for a confirmed transaction/output.
|
|
224
|
-
* Mirrors bdk_chain::ConfirmationBlockTime.
|
|
225
|
-
*/
|
|
226
|
-
|
|
227
243
|
/**
|
|
228
244
|
* Generated factory for {@link ConfirmationBlockTime} record objects.
|
|
229
245
|
*/
|
|
@@ -258,11 +274,6 @@ const FfiConverterTypeConfirmationBlockTime = (() => {
|
|
|
258
274
|
}
|
|
259
275
|
return new FFIConverter();
|
|
260
276
|
})();
|
|
261
|
-
|
|
262
|
-
/**
|
|
263
|
-
* Derivation info for a scriptPubKey belonging to the wallet.
|
|
264
|
-
*/
|
|
265
|
-
|
|
266
277
|
/**
|
|
267
278
|
* Generated factory for {@link DerivationInfo} record objects.
|
|
268
279
|
*/
|
|
@@ -295,11 +306,6 @@ const FfiConverterTypeDerivationInfo = (() => {
|
|
|
295
306
|
}
|
|
296
307
|
return new FFIConverter();
|
|
297
308
|
})();
|
|
298
|
-
|
|
299
|
-
/**
|
|
300
|
-
* Info about a keychain and its associated descriptor.
|
|
301
|
-
*/
|
|
302
|
-
|
|
303
309
|
/**
|
|
304
310
|
* Generated factory for {@link KeychainInfo} record objects.
|
|
305
311
|
*/
|
|
@@ -332,11 +338,6 @@ const FfiConverterTypeKeychainInfo = (() => {
|
|
|
332
338
|
}
|
|
333
339
|
return new FFIConverter();
|
|
334
340
|
})();
|
|
335
|
-
|
|
336
|
-
/**
|
|
337
|
-
* A wallet-owned output (spent or unspent). Mirrors bdk_wallet::LocalOutput.
|
|
338
|
-
*/
|
|
339
|
-
|
|
340
341
|
/**
|
|
341
342
|
* Generated factory for {@link LocalOutput} record objects.
|
|
342
343
|
*/
|
|
@@ -377,11 +378,6 @@ const FfiConverterTypeLocalOutput = (() => {
|
|
|
377
378
|
}
|
|
378
379
|
return new FFIConverter();
|
|
379
380
|
})();
|
|
380
|
-
|
|
381
|
-
/**
|
|
382
|
-
* Reference to a specific transaction output. Mirrors bitcoin::OutPoint.
|
|
383
|
-
*/
|
|
384
|
-
|
|
385
381
|
/**
|
|
386
382
|
* Generated factory for {@link OutPoint} record objects.
|
|
387
383
|
*/
|
|
@@ -414,11 +410,6 @@ const FfiConverterTypeOutPoint = (() => {
|
|
|
414
410
|
}
|
|
415
411
|
return new FFIConverter();
|
|
416
412
|
})();
|
|
417
|
-
|
|
418
|
-
/**
|
|
419
|
-
* A single payment recipient.
|
|
420
|
-
*/
|
|
421
|
-
|
|
422
413
|
/**
|
|
423
414
|
* Generated factory for {@link Recipient} record objects.
|
|
424
415
|
*/
|
|
@@ -451,11 +442,6 @@ const FfiConverterTypeRecipient = (() => {
|
|
|
451
442
|
}
|
|
452
443
|
return new FFIConverter();
|
|
453
444
|
})();
|
|
454
|
-
|
|
455
|
-
/**
|
|
456
|
-
* How much was sent from / received into the wallet for a given transaction.
|
|
457
|
-
*/
|
|
458
|
-
|
|
459
445
|
/**
|
|
460
446
|
* Generated factory for {@link SentAndReceived} record objects.
|
|
461
447
|
*/
|
|
@@ -488,11 +474,6 @@ const FfiConverterTypeSentAndReceived = (() => {
|
|
|
488
474
|
}
|
|
489
475
|
return new FFIConverter();
|
|
490
476
|
})();
|
|
491
|
-
|
|
492
|
-
/**
|
|
493
|
-
* Full details of a wallet-relevant transaction. Mirrors bdk_wallet::TxDetails.
|
|
494
|
-
*/
|
|
495
|
-
|
|
496
477
|
/**
|
|
497
478
|
* Generated factory for {@link TxDetails} record objects.
|
|
498
479
|
*/
|
|
@@ -518,7 +499,11 @@ const FfiConverterTypeTxDetails = (() => {
|
|
|
518
499
|
feeRate: FfiConverterOptionalFloat64.read(from),
|
|
519
500
|
balanceDelta: _uniffiBindgenReactNative.FfiConverterInt64.read(from),
|
|
520
501
|
confirmationBlockTime: FfiConverterOptionalTypeConfirmationBlockTime.read(from),
|
|
521
|
-
txHex: FfiConverterString.read(from)
|
|
502
|
+
txHex: FfiConverterString.read(from),
|
|
503
|
+
version: _uniffiBindgenReactNative.FfiConverterInt32.read(from),
|
|
504
|
+
locktime: _uniffiBindgenReactNative.FfiConverterUInt32.read(from),
|
|
505
|
+
inputs: FfiConverterArrayTypeTxInput.read(from),
|
|
506
|
+
outputs: FfiConverterArrayTypeTxOutput.read(from)
|
|
522
507
|
};
|
|
523
508
|
}
|
|
524
509
|
write(value, into) {
|
|
@@ -530,18 +515,55 @@ const FfiConverterTypeTxDetails = (() => {
|
|
|
530
515
|
_uniffiBindgenReactNative.FfiConverterInt64.write(value.balanceDelta, into);
|
|
531
516
|
FfiConverterOptionalTypeConfirmationBlockTime.write(value.confirmationBlockTime, into);
|
|
532
517
|
FfiConverterString.write(value.txHex, into);
|
|
518
|
+
_uniffiBindgenReactNative.FfiConverterInt32.write(value.version, into);
|
|
519
|
+
_uniffiBindgenReactNative.FfiConverterUInt32.write(value.locktime, into);
|
|
520
|
+
FfiConverterArrayTypeTxInput.write(value.inputs, into);
|
|
521
|
+
FfiConverterArrayTypeTxOutput.write(value.outputs, into);
|
|
533
522
|
}
|
|
534
523
|
allocationSize(value) {
|
|
535
|
-
return FfiConverterString.allocationSize(value.txid) + _uniffiBindgenReactNative.FfiConverterUInt64.allocationSize(value.sent) + _uniffiBindgenReactNative.FfiConverterUInt64.allocationSize(value.received) + FfiConverterOptionalUInt64.allocationSize(value.fee) + FfiConverterOptionalFloat64.allocationSize(value.feeRate) + _uniffiBindgenReactNative.FfiConverterInt64.allocationSize(value.balanceDelta) + FfiConverterOptionalTypeConfirmationBlockTime.allocationSize(value.confirmationBlockTime) + FfiConverterString.allocationSize(value.txHex);
|
|
524
|
+
return FfiConverterString.allocationSize(value.txid) + _uniffiBindgenReactNative.FfiConverterUInt64.allocationSize(value.sent) + _uniffiBindgenReactNative.FfiConverterUInt64.allocationSize(value.received) + FfiConverterOptionalUInt64.allocationSize(value.fee) + FfiConverterOptionalFloat64.allocationSize(value.feeRate) + _uniffiBindgenReactNative.FfiConverterInt64.allocationSize(value.balanceDelta) + FfiConverterOptionalTypeConfirmationBlockTime.allocationSize(value.confirmationBlockTime) + FfiConverterString.allocationSize(value.txHex) + _uniffiBindgenReactNative.FfiConverterInt32.allocationSize(value.version) + _uniffiBindgenReactNative.FfiConverterUInt32.allocationSize(value.locktime) + FfiConverterArrayTypeTxInput.allocationSize(value.inputs) + FfiConverterArrayTypeTxOutput.allocationSize(value.outputs);
|
|
536
525
|
}
|
|
537
526
|
}
|
|
538
527
|
return new FFIConverter();
|
|
539
528
|
})();
|
|
540
|
-
|
|
541
529
|
/**
|
|
542
|
-
*
|
|
530
|
+
* Generated factory for {@link TxInput} record objects.
|
|
543
531
|
*/
|
|
544
|
-
|
|
532
|
+
const TxInput = exports.TxInput = (() => {
|
|
533
|
+
const defaults = () => ({});
|
|
534
|
+
const create = (() => {
|
|
535
|
+
return (0, _uniffiBindgenReactNative.uniffiCreateRecord)(defaults);
|
|
536
|
+
})();
|
|
537
|
+
return Object.freeze({
|
|
538
|
+
create,
|
|
539
|
+
new: create,
|
|
540
|
+
defaults: () => Object.freeze(defaults())
|
|
541
|
+
});
|
|
542
|
+
})();
|
|
543
|
+
const FfiConverterTypeTxInput = (() => {
|
|
544
|
+
class FFIConverter extends _uniffiBindgenReactNative.AbstractFfiConverterByteArray {
|
|
545
|
+
read(from) {
|
|
546
|
+
return {
|
|
547
|
+
previousTxid: FfiConverterString.read(from),
|
|
548
|
+
previousVout: _uniffiBindgenReactNative.FfiConverterUInt32.read(from),
|
|
549
|
+
sequence: _uniffiBindgenReactNative.FfiConverterUInt32.read(from),
|
|
550
|
+
scriptSigHex: FfiConverterString.read(from),
|
|
551
|
+
witness: FfiConverterArrayString.read(from)
|
|
552
|
+
};
|
|
553
|
+
}
|
|
554
|
+
write(value, into) {
|
|
555
|
+
FfiConverterString.write(value.previousTxid, into);
|
|
556
|
+
_uniffiBindgenReactNative.FfiConverterUInt32.write(value.previousVout, into);
|
|
557
|
+
_uniffiBindgenReactNative.FfiConverterUInt32.write(value.sequence, into);
|
|
558
|
+
FfiConverterString.write(value.scriptSigHex, into);
|
|
559
|
+
FfiConverterArrayString.write(value.witness, into);
|
|
560
|
+
}
|
|
561
|
+
allocationSize(value) {
|
|
562
|
+
return FfiConverterString.allocationSize(value.previousTxid) + _uniffiBindgenReactNative.FfiConverterUInt32.allocationSize(value.previousVout) + _uniffiBindgenReactNative.FfiConverterUInt32.allocationSize(value.sequence) + FfiConverterString.allocationSize(value.scriptSigHex) + FfiConverterArrayString.allocationSize(value.witness);
|
|
563
|
+
}
|
|
564
|
+
}
|
|
565
|
+
return new FFIConverter();
|
|
566
|
+
})();
|
|
545
567
|
/**
|
|
546
568
|
* Generated factory for {@link TxOut} record objects.
|
|
547
569
|
*/
|
|
@@ -574,6 +596,40 @@ const FfiConverterTypeTxOut = (() => {
|
|
|
574
596
|
}
|
|
575
597
|
return new FFIConverter();
|
|
576
598
|
})();
|
|
599
|
+
/**
|
|
600
|
+
* Generated factory for {@link TxOutput} record objects.
|
|
601
|
+
*/
|
|
602
|
+
const TxOutput = exports.TxOutput = (() => {
|
|
603
|
+
const defaults = () => ({});
|
|
604
|
+
const create = (() => {
|
|
605
|
+
return (0, _uniffiBindgenReactNative.uniffiCreateRecord)(defaults);
|
|
606
|
+
})();
|
|
607
|
+
return Object.freeze({
|
|
608
|
+
create,
|
|
609
|
+
new: create,
|
|
610
|
+
defaults: () => Object.freeze(defaults())
|
|
611
|
+
});
|
|
612
|
+
})();
|
|
613
|
+
const FfiConverterTypeTxOutput = (() => {
|
|
614
|
+
class FFIConverter extends _uniffiBindgenReactNative.AbstractFfiConverterByteArray {
|
|
615
|
+
read(from) {
|
|
616
|
+
return {
|
|
617
|
+
value: _uniffiBindgenReactNative.FfiConverterUInt64.read(from),
|
|
618
|
+
scriptPubkeyHex: FfiConverterString.read(from),
|
|
619
|
+
address: FfiConverterOptionalString.read(from)
|
|
620
|
+
};
|
|
621
|
+
}
|
|
622
|
+
write(value, into) {
|
|
623
|
+
_uniffiBindgenReactNative.FfiConverterUInt64.write(value.value, into);
|
|
624
|
+
FfiConverterString.write(value.scriptPubkeyHex, into);
|
|
625
|
+
FfiConverterOptionalString.write(value.address, into);
|
|
626
|
+
}
|
|
627
|
+
allocationSize(value) {
|
|
628
|
+
return _uniffiBindgenReactNative.FfiConverterUInt64.allocationSize(value.value) + FfiConverterString.allocationSize(value.scriptPubkeyHex) + FfiConverterOptionalString.allocationSize(value.address);
|
|
629
|
+
}
|
|
630
|
+
}
|
|
631
|
+
return new FFIConverter();
|
|
632
|
+
})();
|
|
577
633
|
const stringConverter = {
|
|
578
634
|
stringToBytes: s => uniffiCaller.rustCall(status => (0, _bdk_ffiFfi.default)().ubrn_uniffi_internal_fn_func_ffi__string_to_arraybuffer(s, status)),
|
|
579
635
|
bytesToString: ab => uniffiCaller.rustCall(status => (0, _bdk_ffiFfi.default)().ubrn_uniffi_internal_fn_func_ffi__arraybuffer_to_string(ab, status)),
|
|
@@ -581,7 +637,9 @@ const stringConverter = {
|
|
|
581
637
|
};
|
|
582
638
|
const FfiConverterString = (0, _uniffiBindgenReactNative.uniffiCreateFfiConverterString)(stringConverter);
|
|
583
639
|
|
|
584
|
-
//
|
|
640
|
+
// Error type: BdkError
|
|
641
|
+
|
|
642
|
+
// Enum: BdkError
|
|
585
643
|
let BdkError_Tags = exports.BdkError_Tags = /*#__PURE__*/function (BdkError_Tags) {
|
|
586
644
|
BdkError_Tags["InvalidDescriptor"] = "InvalidDescriptor";
|
|
587
645
|
BdkError_Tags["WalletCreationFailed"] = "WalletCreationFailed";
|
|
@@ -634,1110 +692,2106 @@ let BdkError_Tags = exports.BdkError_Tags = /*#__PURE__*/function (BdkError_Tags
|
|
|
634
692
|
return BdkError_Tags;
|
|
635
693
|
}({});
|
|
636
694
|
const BdkError = exports.BdkError = (() => {
|
|
637
|
-
class
|
|
695
|
+
class InvalidDescriptor_ extends _uniffiBindgenReactNative.UniffiError {
|
|
638
696
|
/**
|
|
639
697
|
* @private
|
|
640
|
-
* This field is private and should not be used.
|
|
698
|
+
* This field is private and should not be used, use `tag` instead.
|
|
641
699
|
*/
|
|
642
700
|
[_uniffiBindgenReactNative.uniffiTypeNameSymbol] = "BdkError";
|
|
643
|
-
/**
|
|
644
|
-
* @private
|
|
645
|
-
* This field is private and should not be used.
|
|
646
|
-
*/
|
|
647
|
-
[_uniffiBindgenReactNative.variantOrdinalSymbol] = 1;
|
|
648
701
|
tag = BdkError_Tags.InvalidDescriptor;
|
|
649
|
-
constructor(
|
|
650
|
-
super("BdkError", "InvalidDescriptor"
|
|
702
|
+
constructor(inner) {
|
|
703
|
+
super("BdkError", "InvalidDescriptor");
|
|
704
|
+
this.inner = Object.freeze(inner);
|
|
705
|
+
}
|
|
706
|
+
static new(inner) {
|
|
707
|
+
return new InvalidDescriptor_(inner);
|
|
708
|
+
}
|
|
709
|
+
static instanceOf(obj) {
|
|
710
|
+
return obj.tag === BdkError_Tags.InvalidDescriptor;
|
|
711
|
+
}
|
|
712
|
+
static hasInner(obj) {
|
|
713
|
+
return InvalidDescriptor_.instanceOf(obj);
|
|
651
714
|
}
|
|
652
|
-
static
|
|
653
|
-
return
|
|
715
|
+
static getInner(obj) {
|
|
716
|
+
return obj.inner;
|
|
654
717
|
}
|
|
655
718
|
}
|
|
656
|
-
class
|
|
719
|
+
class WalletCreationFailed_ extends _uniffiBindgenReactNative.UniffiError {
|
|
657
720
|
/**
|
|
658
721
|
* @private
|
|
659
|
-
* This field is private and should not be used.
|
|
722
|
+
* This field is private and should not be used, use `tag` instead.
|
|
660
723
|
*/
|
|
661
724
|
[_uniffiBindgenReactNative.uniffiTypeNameSymbol] = "BdkError";
|
|
662
|
-
/**
|
|
663
|
-
* @private
|
|
664
|
-
* This field is private and should not be used.
|
|
665
|
-
*/
|
|
666
|
-
[_uniffiBindgenReactNative.variantOrdinalSymbol] = 2;
|
|
667
725
|
tag = BdkError_Tags.WalletCreationFailed;
|
|
668
|
-
constructor(
|
|
669
|
-
super("BdkError", "WalletCreationFailed"
|
|
726
|
+
constructor(inner) {
|
|
727
|
+
super("BdkError", "WalletCreationFailed");
|
|
728
|
+
this.inner = Object.freeze(inner);
|
|
729
|
+
}
|
|
730
|
+
static new(inner) {
|
|
731
|
+
return new WalletCreationFailed_(inner);
|
|
732
|
+
}
|
|
733
|
+
static instanceOf(obj) {
|
|
734
|
+
return obj.tag === BdkError_Tags.WalletCreationFailed;
|
|
670
735
|
}
|
|
671
|
-
static
|
|
672
|
-
return instanceOf(
|
|
736
|
+
static hasInner(obj) {
|
|
737
|
+
return WalletCreationFailed_.instanceOf(obj);
|
|
738
|
+
}
|
|
739
|
+
static getInner(obj) {
|
|
740
|
+
return obj.inner;
|
|
673
741
|
}
|
|
674
742
|
}
|
|
675
|
-
class
|
|
743
|
+
class WalletLoadFailed_ extends _uniffiBindgenReactNative.UniffiError {
|
|
676
744
|
/**
|
|
677
745
|
* @private
|
|
678
|
-
* This field is private and should not be used.
|
|
746
|
+
* This field is private and should not be used, use `tag` instead.
|
|
679
747
|
*/
|
|
680
748
|
[_uniffiBindgenReactNative.uniffiTypeNameSymbol] = "BdkError";
|
|
681
|
-
/**
|
|
682
|
-
* @private
|
|
683
|
-
* This field is private and should not be used.
|
|
684
|
-
*/
|
|
685
|
-
[_uniffiBindgenReactNative.variantOrdinalSymbol] = 3;
|
|
686
749
|
tag = BdkError_Tags.WalletLoadFailed;
|
|
687
|
-
constructor(
|
|
688
|
-
super("BdkError", "WalletLoadFailed"
|
|
750
|
+
constructor(inner) {
|
|
751
|
+
super("BdkError", "WalletLoadFailed");
|
|
752
|
+
this.inner = Object.freeze(inner);
|
|
753
|
+
}
|
|
754
|
+
static new(inner) {
|
|
755
|
+
return new WalletLoadFailed_(inner);
|
|
756
|
+
}
|
|
757
|
+
static instanceOf(obj) {
|
|
758
|
+
return obj.tag === BdkError_Tags.WalletLoadFailed;
|
|
759
|
+
}
|
|
760
|
+
static hasInner(obj) {
|
|
761
|
+
return WalletLoadFailed_.instanceOf(obj);
|
|
689
762
|
}
|
|
690
|
-
static
|
|
691
|
-
return
|
|
763
|
+
static getInner(obj) {
|
|
764
|
+
return obj.inner;
|
|
692
765
|
}
|
|
693
766
|
}
|
|
694
|
-
class
|
|
767
|
+
class WalletLoadMismatch_ extends _uniffiBindgenReactNative.UniffiError {
|
|
695
768
|
/**
|
|
696
769
|
* @private
|
|
697
|
-
* This field is private and should not be used.
|
|
770
|
+
* This field is private and should not be used, use `tag` instead.
|
|
698
771
|
*/
|
|
699
772
|
[_uniffiBindgenReactNative.uniffiTypeNameSymbol] = "BdkError";
|
|
700
|
-
/**
|
|
701
|
-
* @private
|
|
702
|
-
* This field is private and should not be used.
|
|
703
|
-
*/
|
|
704
|
-
[_uniffiBindgenReactNative.variantOrdinalSymbol] = 4;
|
|
705
773
|
tag = BdkError_Tags.WalletLoadMismatch;
|
|
706
|
-
constructor(
|
|
707
|
-
super("BdkError", "WalletLoadMismatch"
|
|
774
|
+
constructor(inner) {
|
|
775
|
+
super("BdkError", "WalletLoadMismatch");
|
|
776
|
+
this.inner = Object.freeze(inner);
|
|
777
|
+
}
|
|
778
|
+
static new(inner) {
|
|
779
|
+
return new WalletLoadMismatch_(inner);
|
|
708
780
|
}
|
|
709
|
-
static instanceOf(
|
|
710
|
-
return
|
|
781
|
+
static instanceOf(obj) {
|
|
782
|
+
return obj.tag === BdkError_Tags.WalletLoadMismatch;
|
|
783
|
+
}
|
|
784
|
+
static hasInner(obj) {
|
|
785
|
+
return WalletLoadMismatch_.instanceOf(obj);
|
|
786
|
+
}
|
|
787
|
+
static getInner(obj) {
|
|
788
|
+
return obj.inner;
|
|
711
789
|
}
|
|
712
790
|
}
|
|
713
|
-
class
|
|
791
|
+
class PersistError_ extends _uniffiBindgenReactNative.UniffiError {
|
|
714
792
|
/**
|
|
715
793
|
* @private
|
|
716
|
-
* This field is private and should not be used.
|
|
794
|
+
* This field is private and should not be used, use `tag` instead.
|
|
717
795
|
*/
|
|
718
796
|
[_uniffiBindgenReactNative.uniffiTypeNameSymbol] = "BdkError";
|
|
719
|
-
/**
|
|
720
|
-
* @private
|
|
721
|
-
* This field is private and should not be used.
|
|
722
|
-
*/
|
|
723
|
-
[_uniffiBindgenReactNative.variantOrdinalSymbol] = 5;
|
|
724
797
|
tag = BdkError_Tags.PersistError;
|
|
725
|
-
constructor(
|
|
726
|
-
super("BdkError", "PersistError"
|
|
798
|
+
constructor(inner) {
|
|
799
|
+
super("BdkError", "PersistError");
|
|
800
|
+
this.inner = Object.freeze(inner);
|
|
801
|
+
}
|
|
802
|
+
static new(inner) {
|
|
803
|
+
return new PersistError_(inner);
|
|
804
|
+
}
|
|
805
|
+
static instanceOf(obj) {
|
|
806
|
+
return obj.tag === BdkError_Tags.PersistError;
|
|
807
|
+
}
|
|
808
|
+
static hasInner(obj) {
|
|
809
|
+
return PersistError_.instanceOf(obj);
|
|
727
810
|
}
|
|
728
|
-
static
|
|
729
|
-
return
|
|
811
|
+
static getInner(obj) {
|
|
812
|
+
return obj.inner;
|
|
730
813
|
}
|
|
731
814
|
}
|
|
732
|
-
class
|
|
815
|
+
class InvalidAddress_ extends _uniffiBindgenReactNative.UniffiError {
|
|
733
816
|
/**
|
|
734
817
|
* @private
|
|
735
|
-
* This field is private and should not be used.
|
|
818
|
+
* This field is private and should not be used, use `tag` instead.
|
|
736
819
|
*/
|
|
737
820
|
[_uniffiBindgenReactNative.uniffiTypeNameSymbol] = "BdkError";
|
|
738
|
-
/**
|
|
739
|
-
* @private
|
|
740
|
-
* This field is private and should not be used.
|
|
741
|
-
*/
|
|
742
|
-
[_uniffiBindgenReactNative.variantOrdinalSymbol] = 6;
|
|
743
821
|
tag = BdkError_Tags.InvalidAddress;
|
|
744
|
-
constructor(
|
|
745
|
-
super("BdkError", "InvalidAddress"
|
|
822
|
+
constructor(inner) {
|
|
823
|
+
super("BdkError", "InvalidAddress");
|
|
824
|
+
this.inner = Object.freeze(inner);
|
|
746
825
|
}
|
|
747
|
-
static
|
|
748
|
-
return
|
|
826
|
+
static new(inner) {
|
|
827
|
+
return new InvalidAddress_(inner);
|
|
828
|
+
}
|
|
829
|
+
static instanceOf(obj) {
|
|
830
|
+
return obj.tag === BdkError_Tags.InvalidAddress;
|
|
831
|
+
}
|
|
832
|
+
static hasInner(obj) {
|
|
833
|
+
return InvalidAddress_.instanceOf(obj);
|
|
834
|
+
}
|
|
835
|
+
static getInner(obj) {
|
|
836
|
+
return obj.inner;
|
|
749
837
|
}
|
|
750
838
|
}
|
|
751
|
-
class
|
|
839
|
+
class InvalidScript_ extends _uniffiBindgenReactNative.UniffiError {
|
|
752
840
|
/**
|
|
753
841
|
* @private
|
|
754
|
-
* This field is private and should not be used.
|
|
842
|
+
* This field is private and should not be used, use `tag` instead.
|
|
755
843
|
*/
|
|
756
844
|
[_uniffiBindgenReactNative.uniffiTypeNameSymbol] = "BdkError";
|
|
757
|
-
/**
|
|
758
|
-
* @private
|
|
759
|
-
* This field is private and should not be used.
|
|
760
|
-
*/
|
|
761
|
-
[_uniffiBindgenReactNative.variantOrdinalSymbol] = 7;
|
|
762
845
|
tag = BdkError_Tags.InvalidScript;
|
|
763
|
-
constructor(
|
|
764
|
-
super("BdkError", "InvalidScript"
|
|
846
|
+
constructor(inner) {
|
|
847
|
+
super("BdkError", "InvalidScript");
|
|
848
|
+
this.inner = Object.freeze(inner);
|
|
849
|
+
}
|
|
850
|
+
static new(inner) {
|
|
851
|
+
return new InvalidScript_(inner);
|
|
852
|
+
}
|
|
853
|
+
static instanceOf(obj) {
|
|
854
|
+
return obj.tag === BdkError_Tags.InvalidScript;
|
|
855
|
+
}
|
|
856
|
+
static hasInner(obj) {
|
|
857
|
+
return InvalidScript_.instanceOf(obj);
|
|
765
858
|
}
|
|
766
|
-
static
|
|
767
|
-
return
|
|
859
|
+
static getInner(obj) {
|
|
860
|
+
return obj.inner;
|
|
768
861
|
}
|
|
769
862
|
}
|
|
770
|
-
class
|
|
863
|
+
class TransactionBuildFailed_ extends _uniffiBindgenReactNative.UniffiError {
|
|
771
864
|
/**
|
|
772
865
|
* @private
|
|
773
|
-
* This field is private and should not be used.
|
|
866
|
+
* This field is private and should not be used, use `tag` instead.
|
|
774
867
|
*/
|
|
775
868
|
[_uniffiBindgenReactNative.uniffiTypeNameSymbol] = "BdkError";
|
|
776
|
-
/**
|
|
777
|
-
* @private
|
|
778
|
-
* This field is private and should not be used.
|
|
779
|
-
*/
|
|
780
|
-
[_uniffiBindgenReactNative.variantOrdinalSymbol] = 8;
|
|
781
869
|
tag = BdkError_Tags.TransactionBuildFailed;
|
|
782
|
-
constructor(
|
|
783
|
-
super("BdkError", "TransactionBuildFailed"
|
|
870
|
+
constructor(inner) {
|
|
871
|
+
super("BdkError", "TransactionBuildFailed");
|
|
872
|
+
this.inner = Object.freeze(inner);
|
|
873
|
+
}
|
|
874
|
+
static new(inner) {
|
|
875
|
+
return new TransactionBuildFailed_(inner);
|
|
784
876
|
}
|
|
785
|
-
static instanceOf(
|
|
786
|
-
return
|
|
877
|
+
static instanceOf(obj) {
|
|
878
|
+
return obj.tag === BdkError_Tags.TransactionBuildFailed;
|
|
879
|
+
}
|
|
880
|
+
static hasInner(obj) {
|
|
881
|
+
return TransactionBuildFailed_.instanceOf(obj);
|
|
882
|
+
}
|
|
883
|
+
static getInner(obj) {
|
|
884
|
+
return obj.inner;
|
|
787
885
|
}
|
|
788
886
|
}
|
|
789
|
-
class
|
|
887
|
+
class NoRecipients_ extends _uniffiBindgenReactNative.UniffiError {
|
|
790
888
|
/**
|
|
791
889
|
* @private
|
|
792
|
-
* This field is private and should not be used.
|
|
890
|
+
* This field is private and should not be used, use `tag` instead.
|
|
793
891
|
*/
|
|
794
892
|
[_uniffiBindgenReactNative.uniffiTypeNameSymbol] = "BdkError";
|
|
795
|
-
/**
|
|
796
|
-
* @private
|
|
797
|
-
* This field is private and should not be used.
|
|
798
|
-
*/
|
|
799
|
-
[_uniffiBindgenReactNative.variantOrdinalSymbol] = 9;
|
|
800
893
|
tag = BdkError_Tags.NoRecipients;
|
|
801
|
-
constructor(
|
|
802
|
-
super("BdkError", "NoRecipients"
|
|
894
|
+
constructor(inner) {
|
|
895
|
+
super("BdkError", "NoRecipients");
|
|
896
|
+
this.inner = Object.freeze(inner);
|
|
897
|
+
}
|
|
898
|
+
static new(inner) {
|
|
899
|
+
return new NoRecipients_(inner);
|
|
900
|
+
}
|
|
901
|
+
static instanceOf(obj) {
|
|
902
|
+
return obj.tag === BdkError_Tags.NoRecipients;
|
|
903
|
+
}
|
|
904
|
+
static hasInner(obj) {
|
|
905
|
+
return NoRecipients_.instanceOf(obj);
|
|
803
906
|
}
|
|
804
|
-
static
|
|
805
|
-
return
|
|
907
|
+
static getInner(obj) {
|
|
908
|
+
return obj.inner;
|
|
806
909
|
}
|
|
807
910
|
}
|
|
808
|
-
class
|
|
911
|
+
class NoUtxosSelected_ extends _uniffiBindgenReactNative.UniffiError {
|
|
809
912
|
/**
|
|
810
913
|
* @private
|
|
811
|
-
* This field is private and should not be used.
|
|
914
|
+
* This field is private and should not be used, use `tag` instead.
|
|
812
915
|
*/
|
|
813
916
|
[_uniffiBindgenReactNative.uniffiTypeNameSymbol] = "BdkError";
|
|
814
|
-
/**
|
|
815
|
-
* @private
|
|
816
|
-
* This field is private and should not be used.
|
|
817
|
-
*/
|
|
818
|
-
[_uniffiBindgenReactNative.variantOrdinalSymbol] = 10;
|
|
819
917
|
tag = BdkError_Tags.NoUtxosSelected;
|
|
820
|
-
constructor(
|
|
821
|
-
super("BdkError", "NoUtxosSelected"
|
|
918
|
+
constructor(inner) {
|
|
919
|
+
super("BdkError", "NoUtxosSelected");
|
|
920
|
+
this.inner = Object.freeze(inner);
|
|
921
|
+
}
|
|
922
|
+
static new(inner) {
|
|
923
|
+
return new NoUtxosSelected_(inner);
|
|
924
|
+
}
|
|
925
|
+
static instanceOf(obj) {
|
|
926
|
+
return obj.tag === BdkError_Tags.NoUtxosSelected;
|
|
822
927
|
}
|
|
823
|
-
static
|
|
824
|
-
return instanceOf(
|
|
928
|
+
static hasInner(obj) {
|
|
929
|
+
return NoUtxosSelected_.instanceOf(obj);
|
|
930
|
+
}
|
|
931
|
+
static getInner(obj) {
|
|
932
|
+
return obj.inner;
|
|
825
933
|
}
|
|
826
934
|
}
|
|
827
|
-
class
|
|
935
|
+
class OutputBelowDustLimit_ extends _uniffiBindgenReactNative.UniffiError {
|
|
828
936
|
/**
|
|
829
937
|
* @private
|
|
830
|
-
* This field is private and should not be used.
|
|
938
|
+
* This field is private and should not be used, use `tag` instead.
|
|
831
939
|
*/
|
|
832
940
|
[_uniffiBindgenReactNative.uniffiTypeNameSymbol] = "BdkError";
|
|
833
|
-
/**
|
|
834
|
-
* @private
|
|
835
|
-
* This field is private and should not be used.
|
|
836
|
-
*/
|
|
837
|
-
[_uniffiBindgenReactNative.variantOrdinalSymbol] = 11;
|
|
838
941
|
tag = BdkError_Tags.OutputBelowDustLimit;
|
|
839
|
-
constructor(
|
|
840
|
-
super("BdkError", "OutputBelowDustLimit"
|
|
942
|
+
constructor(inner) {
|
|
943
|
+
super("BdkError", "OutputBelowDustLimit");
|
|
944
|
+
this.inner = Object.freeze(inner);
|
|
945
|
+
}
|
|
946
|
+
static new(inner) {
|
|
947
|
+
return new OutputBelowDustLimit_(inner);
|
|
948
|
+
}
|
|
949
|
+
static instanceOf(obj) {
|
|
950
|
+
return obj.tag === BdkError_Tags.OutputBelowDustLimit;
|
|
951
|
+
}
|
|
952
|
+
static hasInner(obj) {
|
|
953
|
+
return OutputBelowDustLimit_.instanceOf(obj);
|
|
841
954
|
}
|
|
842
|
-
static
|
|
843
|
-
return
|
|
955
|
+
static getInner(obj) {
|
|
956
|
+
return obj.inner;
|
|
844
957
|
}
|
|
845
958
|
}
|
|
846
|
-
class
|
|
959
|
+
class InsufficientFunds_ extends _uniffiBindgenReactNative.UniffiError {
|
|
847
960
|
/**
|
|
848
961
|
* @private
|
|
849
|
-
* This field is private and should not be used.
|
|
962
|
+
* This field is private and should not be used, use `tag` instead.
|
|
850
963
|
*/
|
|
851
964
|
[_uniffiBindgenReactNative.uniffiTypeNameSymbol] = "BdkError";
|
|
852
|
-
/**
|
|
853
|
-
* @private
|
|
854
|
-
* This field is private and should not be used.
|
|
855
|
-
*/
|
|
856
|
-
[_uniffiBindgenReactNative.variantOrdinalSymbol] = 12;
|
|
857
965
|
tag = BdkError_Tags.InsufficientFunds;
|
|
858
|
-
constructor(
|
|
859
|
-
super("BdkError", "InsufficientFunds"
|
|
966
|
+
constructor(inner) {
|
|
967
|
+
super("BdkError", "InsufficientFunds");
|
|
968
|
+
this.inner = Object.freeze(inner);
|
|
969
|
+
}
|
|
970
|
+
static new(inner) {
|
|
971
|
+
return new InsufficientFunds_(inner);
|
|
860
972
|
}
|
|
861
|
-
static instanceOf(
|
|
862
|
-
return
|
|
973
|
+
static instanceOf(obj) {
|
|
974
|
+
return obj.tag === BdkError_Tags.InsufficientFunds;
|
|
975
|
+
}
|
|
976
|
+
static hasInner(obj) {
|
|
977
|
+
return InsufficientFunds_.instanceOf(obj);
|
|
978
|
+
}
|
|
979
|
+
static getInner(obj) {
|
|
980
|
+
return obj.inner;
|
|
863
981
|
}
|
|
864
982
|
}
|
|
865
|
-
class
|
|
983
|
+
class FeeRateTooLow_ extends _uniffiBindgenReactNative.UniffiError {
|
|
866
984
|
/**
|
|
867
985
|
* @private
|
|
868
|
-
* This field is private and should not be used.
|
|
986
|
+
* This field is private and should not be used, use `tag` instead.
|
|
869
987
|
*/
|
|
870
988
|
[_uniffiBindgenReactNative.uniffiTypeNameSymbol] = "BdkError";
|
|
871
|
-
/**
|
|
872
|
-
* @private
|
|
873
|
-
* This field is private and should not be used.
|
|
874
|
-
*/
|
|
875
|
-
[_uniffiBindgenReactNative.variantOrdinalSymbol] = 13;
|
|
876
989
|
tag = BdkError_Tags.FeeRateTooLow;
|
|
877
|
-
constructor(
|
|
878
|
-
super("BdkError", "FeeRateTooLow"
|
|
990
|
+
constructor(inner) {
|
|
991
|
+
super("BdkError", "FeeRateTooLow");
|
|
992
|
+
this.inner = Object.freeze(inner);
|
|
879
993
|
}
|
|
880
|
-
static
|
|
881
|
-
return
|
|
994
|
+
static new(inner) {
|
|
995
|
+
return new FeeRateTooLow_(inner);
|
|
882
996
|
}
|
|
883
|
-
|
|
884
|
-
|
|
885
|
-
|
|
886
|
-
|
|
887
|
-
|
|
888
|
-
|
|
889
|
-
|
|
997
|
+
static instanceOf(obj) {
|
|
998
|
+
return obj.tag === BdkError_Tags.FeeRateTooLow;
|
|
999
|
+
}
|
|
1000
|
+
static hasInner(obj) {
|
|
1001
|
+
return FeeRateTooLow_.instanceOf(obj);
|
|
1002
|
+
}
|
|
1003
|
+
static getInner(obj) {
|
|
1004
|
+
return obj.inner;
|
|
1005
|
+
}
|
|
1006
|
+
}
|
|
1007
|
+
class FeeTooLow_ extends _uniffiBindgenReactNative.UniffiError {
|
|
890
1008
|
/**
|
|
891
1009
|
* @private
|
|
892
|
-
* This field is private and should not be used.
|
|
1010
|
+
* This field is private and should not be used, use `tag` instead.
|
|
893
1011
|
*/
|
|
894
|
-
[_uniffiBindgenReactNative.
|
|
1012
|
+
[_uniffiBindgenReactNative.uniffiTypeNameSymbol] = "BdkError";
|
|
895
1013
|
tag = BdkError_Tags.FeeTooLow;
|
|
896
|
-
constructor(
|
|
897
|
-
super("BdkError", "FeeTooLow"
|
|
1014
|
+
constructor(inner) {
|
|
1015
|
+
super("BdkError", "FeeTooLow");
|
|
1016
|
+
this.inner = Object.freeze(inner);
|
|
1017
|
+
}
|
|
1018
|
+
static new(inner) {
|
|
1019
|
+
return new FeeTooLow_(inner);
|
|
1020
|
+
}
|
|
1021
|
+
static instanceOf(obj) {
|
|
1022
|
+
return obj.tag === BdkError_Tags.FeeTooLow;
|
|
898
1023
|
}
|
|
899
|
-
static
|
|
900
|
-
return instanceOf(
|
|
1024
|
+
static hasInner(obj) {
|
|
1025
|
+
return FeeTooLow_.instanceOf(obj);
|
|
1026
|
+
}
|
|
1027
|
+
static getInner(obj) {
|
|
1028
|
+
return obj.inner;
|
|
901
1029
|
}
|
|
902
1030
|
}
|
|
903
|
-
class
|
|
1031
|
+
class LockTimeConflict_ extends _uniffiBindgenReactNative.UniffiError {
|
|
904
1032
|
/**
|
|
905
1033
|
* @private
|
|
906
|
-
* This field is private and should not be used.
|
|
1034
|
+
* This field is private and should not be used, use `tag` instead.
|
|
907
1035
|
*/
|
|
908
1036
|
[_uniffiBindgenReactNative.uniffiTypeNameSymbol] = "BdkError";
|
|
909
|
-
/**
|
|
910
|
-
* @private
|
|
911
|
-
* This field is private and should not be used.
|
|
912
|
-
*/
|
|
913
|
-
[_uniffiBindgenReactNative.variantOrdinalSymbol] = 15;
|
|
914
1037
|
tag = BdkError_Tags.LockTimeConflict;
|
|
915
|
-
constructor(
|
|
916
|
-
super("BdkError", "LockTimeConflict"
|
|
1038
|
+
constructor(inner) {
|
|
1039
|
+
super("BdkError", "LockTimeConflict");
|
|
1040
|
+
this.inner = Object.freeze(inner);
|
|
1041
|
+
}
|
|
1042
|
+
static new(inner) {
|
|
1043
|
+
return new LockTimeConflict_(inner);
|
|
1044
|
+
}
|
|
1045
|
+
static instanceOf(obj) {
|
|
1046
|
+
return obj.tag === BdkError_Tags.LockTimeConflict;
|
|
1047
|
+
}
|
|
1048
|
+
static hasInner(obj) {
|
|
1049
|
+
return LockTimeConflict_.instanceOf(obj);
|
|
917
1050
|
}
|
|
918
|
-
static
|
|
919
|
-
return
|
|
1051
|
+
static getInner(obj) {
|
|
1052
|
+
return obj.inner;
|
|
920
1053
|
}
|
|
921
1054
|
}
|
|
922
|
-
class
|
|
1055
|
+
class RbfSequenceConflict_ extends _uniffiBindgenReactNative.UniffiError {
|
|
923
1056
|
/**
|
|
924
1057
|
* @private
|
|
925
|
-
* This field is private and should not be used.
|
|
1058
|
+
* This field is private and should not be used, use `tag` instead.
|
|
926
1059
|
*/
|
|
927
1060
|
[_uniffiBindgenReactNative.uniffiTypeNameSymbol] = "BdkError";
|
|
928
|
-
/**
|
|
929
|
-
* @private
|
|
930
|
-
* This field is private and should not be used.
|
|
931
|
-
*/
|
|
932
|
-
[_uniffiBindgenReactNative.variantOrdinalSymbol] = 16;
|
|
933
1061
|
tag = BdkError_Tags.RbfSequenceConflict;
|
|
934
|
-
constructor(
|
|
935
|
-
super("BdkError", "RbfSequenceConflict"
|
|
1062
|
+
constructor(inner) {
|
|
1063
|
+
super("BdkError", "RbfSequenceConflict");
|
|
1064
|
+
this.inner = Object.freeze(inner);
|
|
1065
|
+
}
|
|
1066
|
+
static new(inner) {
|
|
1067
|
+
return new RbfSequenceConflict_(inner);
|
|
936
1068
|
}
|
|
937
|
-
static instanceOf(
|
|
938
|
-
return
|
|
1069
|
+
static instanceOf(obj) {
|
|
1070
|
+
return obj.tag === BdkError_Tags.RbfSequenceConflict;
|
|
1071
|
+
}
|
|
1072
|
+
static hasInner(obj) {
|
|
1073
|
+
return RbfSequenceConflict_.instanceOf(obj);
|
|
1074
|
+
}
|
|
1075
|
+
static getInner(obj) {
|
|
1076
|
+
return obj.inner;
|
|
939
1077
|
}
|
|
940
1078
|
}
|
|
941
|
-
class
|
|
1079
|
+
class VersionZero_ extends _uniffiBindgenReactNative.UniffiError {
|
|
942
1080
|
/**
|
|
943
1081
|
* @private
|
|
944
|
-
* This field is private and should not be used.
|
|
1082
|
+
* This field is private and should not be used, use `tag` instead.
|
|
945
1083
|
*/
|
|
946
1084
|
[_uniffiBindgenReactNative.uniffiTypeNameSymbol] = "BdkError";
|
|
947
|
-
/**
|
|
948
|
-
* @private
|
|
949
|
-
* This field is private and should not be used.
|
|
950
|
-
*/
|
|
951
|
-
[_uniffiBindgenReactNative.variantOrdinalSymbol] = 17;
|
|
952
1085
|
tag = BdkError_Tags.VersionZero;
|
|
953
|
-
constructor(
|
|
954
|
-
super("BdkError", "VersionZero"
|
|
1086
|
+
constructor(inner) {
|
|
1087
|
+
super("BdkError", "VersionZero");
|
|
1088
|
+
this.inner = Object.freeze(inner);
|
|
1089
|
+
}
|
|
1090
|
+
static new(inner) {
|
|
1091
|
+
return new VersionZero_(inner);
|
|
1092
|
+
}
|
|
1093
|
+
static instanceOf(obj) {
|
|
1094
|
+
return obj.tag === BdkError_Tags.VersionZero;
|
|
1095
|
+
}
|
|
1096
|
+
static hasInner(obj) {
|
|
1097
|
+
return VersionZero_.instanceOf(obj);
|
|
955
1098
|
}
|
|
956
|
-
static
|
|
957
|
-
return
|
|
1099
|
+
static getInner(obj) {
|
|
1100
|
+
return obj.inner;
|
|
958
1101
|
}
|
|
959
1102
|
}
|
|
960
|
-
class
|
|
1103
|
+
class VersionOneCsv_ extends _uniffiBindgenReactNative.UniffiError {
|
|
961
1104
|
/**
|
|
962
1105
|
* @private
|
|
963
|
-
* This field is private and should not be used.
|
|
1106
|
+
* This field is private and should not be used, use `tag` instead.
|
|
964
1107
|
*/
|
|
965
1108
|
[_uniffiBindgenReactNative.uniffiTypeNameSymbol] = "BdkError";
|
|
966
|
-
/**
|
|
967
|
-
* @private
|
|
968
|
-
* This field is private and should not be used.
|
|
969
|
-
*/
|
|
970
|
-
[_uniffiBindgenReactNative.variantOrdinalSymbol] = 18;
|
|
971
1109
|
tag = BdkError_Tags.VersionOneCsv;
|
|
972
|
-
constructor(
|
|
973
|
-
super("BdkError", "VersionOneCsv"
|
|
1110
|
+
constructor(inner) {
|
|
1111
|
+
super("BdkError", "VersionOneCsv");
|
|
1112
|
+
this.inner = Object.freeze(inner);
|
|
974
1113
|
}
|
|
975
|
-
static
|
|
976
|
-
return
|
|
1114
|
+
static new(inner) {
|
|
1115
|
+
return new VersionOneCsv_(inner);
|
|
1116
|
+
}
|
|
1117
|
+
static instanceOf(obj) {
|
|
1118
|
+
return obj.tag === BdkError_Tags.VersionOneCsv;
|
|
1119
|
+
}
|
|
1120
|
+
static hasInner(obj) {
|
|
1121
|
+
return VersionOneCsv_.instanceOf(obj);
|
|
1122
|
+
}
|
|
1123
|
+
static getInner(obj) {
|
|
1124
|
+
return obj.inner;
|
|
977
1125
|
}
|
|
978
1126
|
}
|
|
979
|
-
class
|
|
1127
|
+
class SpendingPolicyRequired_ extends _uniffiBindgenReactNative.UniffiError {
|
|
980
1128
|
/**
|
|
981
1129
|
* @private
|
|
982
|
-
* This field is private and should not be used.
|
|
1130
|
+
* This field is private and should not be used, use `tag` instead.
|
|
983
1131
|
*/
|
|
984
1132
|
[_uniffiBindgenReactNative.uniffiTypeNameSymbol] = "BdkError";
|
|
985
|
-
/**
|
|
986
|
-
* @private
|
|
987
|
-
* This field is private and should not be used.
|
|
988
|
-
*/
|
|
989
|
-
[_uniffiBindgenReactNative.variantOrdinalSymbol] = 19;
|
|
990
1133
|
tag = BdkError_Tags.SpendingPolicyRequired;
|
|
991
|
-
constructor(
|
|
992
|
-
super("BdkError", "SpendingPolicyRequired"
|
|
1134
|
+
constructor(inner) {
|
|
1135
|
+
super("BdkError", "SpendingPolicyRequired");
|
|
1136
|
+
this.inner = Object.freeze(inner);
|
|
1137
|
+
}
|
|
1138
|
+
static new(inner) {
|
|
1139
|
+
return new SpendingPolicyRequired_(inner);
|
|
1140
|
+
}
|
|
1141
|
+
static instanceOf(obj) {
|
|
1142
|
+
return obj.tag === BdkError_Tags.SpendingPolicyRequired;
|
|
1143
|
+
}
|
|
1144
|
+
static hasInner(obj) {
|
|
1145
|
+
return SpendingPolicyRequired_.instanceOf(obj);
|
|
993
1146
|
}
|
|
994
|
-
static
|
|
995
|
-
return
|
|
1147
|
+
static getInner(obj) {
|
|
1148
|
+
return obj.inner;
|
|
996
1149
|
}
|
|
997
1150
|
}
|
|
998
|
-
class
|
|
1151
|
+
class MissingKeyOrigin_ extends _uniffiBindgenReactNative.UniffiError {
|
|
999
1152
|
/**
|
|
1000
1153
|
* @private
|
|
1001
|
-
* This field is private and should not be used.
|
|
1154
|
+
* This field is private and should not be used, use `tag` instead.
|
|
1002
1155
|
*/
|
|
1003
1156
|
[_uniffiBindgenReactNative.uniffiTypeNameSymbol] = "BdkError";
|
|
1004
|
-
/**
|
|
1005
|
-
* @private
|
|
1006
|
-
* This field is private and should not be used.
|
|
1007
|
-
*/
|
|
1008
|
-
[_uniffiBindgenReactNative.variantOrdinalSymbol] = 20;
|
|
1009
1157
|
tag = BdkError_Tags.MissingKeyOrigin;
|
|
1010
|
-
constructor(
|
|
1011
|
-
super("BdkError", "MissingKeyOrigin"
|
|
1158
|
+
constructor(inner) {
|
|
1159
|
+
super("BdkError", "MissingKeyOrigin");
|
|
1160
|
+
this.inner = Object.freeze(inner);
|
|
1161
|
+
}
|
|
1162
|
+
static new(inner) {
|
|
1163
|
+
return new MissingKeyOrigin_(inner);
|
|
1012
1164
|
}
|
|
1013
|
-
static instanceOf(
|
|
1014
|
-
return
|
|
1165
|
+
static instanceOf(obj) {
|
|
1166
|
+
return obj.tag === BdkError_Tags.MissingKeyOrigin;
|
|
1167
|
+
}
|
|
1168
|
+
static hasInner(obj) {
|
|
1169
|
+
return MissingKeyOrigin_.instanceOf(obj);
|
|
1170
|
+
}
|
|
1171
|
+
static getInner(obj) {
|
|
1172
|
+
return obj.inner;
|
|
1015
1173
|
}
|
|
1016
1174
|
}
|
|
1017
|
-
class
|
|
1175
|
+
class MissingNonWitnessUtxo_ extends _uniffiBindgenReactNative.UniffiError {
|
|
1018
1176
|
/**
|
|
1019
1177
|
* @private
|
|
1020
|
-
* This field is private and should not be used.
|
|
1178
|
+
* This field is private and should not be used, use `tag` instead.
|
|
1021
1179
|
*/
|
|
1022
1180
|
[_uniffiBindgenReactNative.uniffiTypeNameSymbol] = "BdkError";
|
|
1023
|
-
/**
|
|
1024
|
-
* @private
|
|
1025
|
-
* This field is private and should not be used.
|
|
1026
|
-
*/
|
|
1027
|
-
[_uniffiBindgenReactNative.variantOrdinalSymbol] = 21;
|
|
1028
1181
|
tag = BdkError_Tags.MissingNonWitnessUtxo;
|
|
1029
|
-
constructor(
|
|
1030
|
-
super("BdkError", "MissingNonWitnessUtxo"
|
|
1182
|
+
constructor(inner) {
|
|
1183
|
+
super("BdkError", "MissingNonWitnessUtxo");
|
|
1184
|
+
this.inner = Object.freeze(inner);
|
|
1185
|
+
}
|
|
1186
|
+
static new(inner) {
|
|
1187
|
+
return new MissingNonWitnessUtxo_(inner);
|
|
1188
|
+
}
|
|
1189
|
+
static instanceOf(obj) {
|
|
1190
|
+
return obj.tag === BdkError_Tags.MissingNonWitnessUtxo;
|
|
1191
|
+
}
|
|
1192
|
+
static hasInner(obj) {
|
|
1193
|
+
return MissingNonWitnessUtxo_.instanceOf(obj);
|
|
1031
1194
|
}
|
|
1032
|
-
static
|
|
1033
|
-
return
|
|
1195
|
+
static getInner(obj) {
|
|
1196
|
+
return obj.inner;
|
|
1034
1197
|
}
|
|
1035
1198
|
}
|
|
1036
|
-
class
|
|
1199
|
+
class OutpointNotFound_ extends _uniffiBindgenReactNative.UniffiError {
|
|
1037
1200
|
/**
|
|
1038
1201
|
* @private
|
|
1039
|
-
* This field is private and should not be used.
|
|
1202
|
+
* This field is private and should not be used, use `tag` instead.
|
|
1040
1203
|
*/
|
|
1041
1204
|
[_uniffiBindgenReactNative.uniffiTypeNameSymbol] = "BdkError";
|
|
1042
|
-
/**
|
|
1043
|
-
* @private
|
|
1044
|
-
* This field is private and should not be used.
|
|
1045
|
-
*/
|
|
1046
|
-
[_uniffiBindgenReactNative.variantOrdinalSymbol] = 22;
|
|
1047
1205
|
tag = BdkError_Tags.OutpointNotFound;
|
|
1048
|
-
constructor(
|
|
1049
|
-
super("BdkError", "OutpointNotFound"
|
|
1206
|
+
constructor(inner) {
|
|
1207
|
+
super("BdkError", "OutpointNotFound");
|
|
1208
|
+
this.inner = Object.freeze(inner);
|
|
1209
|
+
}
|
|
1210
|
+
static new(inner) {
|
|
1211
|
+
return new OutpointNotFound_(inner);
|
|
1212
|
+
}
|
|
1213
|
+
static instanceOf(obj) {
|
|
1214
|
+
return obj.tag === BdkError_Tags.OutpointNotFound;
|
|
1050
1215
|
}
|
|
1051
|
-
static
|
|
1052
|
-
return instanceOf(
|
|
1216
|
+
static hasInner(obj) {
|
|
1217
|
+
return OutpointNotFound_.instanceOf(obj);
|
|
1218
|
+
}
|
|
1219
|
+
static getInner(obj) {
|
|
1220
|
+
return obj.inner;
|
|
1053
1221
|
}
|
|
1054
1222
|
}
|
|
1055
|
-
class
|
|
1223
|
+
class FeeBumpTargetNotFound_ extends _uniffiBindgenReactNative.UniffiError {
|
|
1056
1224
|
/**
|
|
1057
1225
|
* @private
|
|
1058
|
-
* This field is private and should not be used.
|
|
1226
|
+
* This field is private and should not be used, use `tag` instead.
|
|
1059
1227
|
*/
|
|
1060
1228
|
[_uniffiBindgenReactNative.uniffiTypeNameSymbol] = "BdkError";
|
|
1061
|
-
/**
|
|
1062
|
-
* @private
|
|
1063
|
-
* This field is private and should not be used.
|
|
1064
|
-
*/
|
|
1065
|
-
[_uniffiBindgenReactNative.variantOrdinalSymbol] = 23;
|
|
1066
1229
|
tag = BdkError_Tags.FeeBumpTargetNotFound;
|
|
1067
|
-
constructor(
|
|
1068
|
-
super("BdkError", "FeeBumpTargetNotFound"
|
|
1230
|
+
constructor(inner) {
|
|
1231
|
+
super("BdkError", "FeeBumpTargetNotFound");
|
|
1232
|
+
this.inner = Object.freeze(inner);
|
|
1233
|
+
}
|
|
1234
|
+
static new(inner) {
|
|
1235
|
+
return new FeeBumpTargetNotFound_(inner);
|
|
1236
|
+
}
|
|
1237
|
+
static instanceOf(obj) {
|
|
1238
|
+
return obj.tag === BdkError_Tags.FeeBumpTargetNotFound;
|
|
1239
|
+
}
|
|
1240
|
+
static hasInner(obj) {
|
|
1241
|
+
return FeeBumpTargetNotFound_.instanceOf(obj);
|
|
1069
1242
|
}
|
|
1070
|
-
static
|
|
1071
|
-
return
|
|
1243
|
+
static getInner(obj) {
|
|
1244
|
+
return obj.inner;
|
|
1072
1245
|
}
|
|
1073
1246
|
}
|
|
1074
|
-
class
|
|
1247
|
+
class FeeBumpAlreadyConfirmed_ extends _uniffiBindgenReactNative.UniffiError {
|
|
1075
1248
|
/**
|
|
1076
1249
|
* @private
|
|
1077
|
-
* This field is private and should not be used.
|
|
1250
|
+
* This field is private and should not be used, use `tag` instead.
|
|
1078
1251
|
*/
|
|
1079
1252
|
[_uniffiBindgenReactNative.uniffiTypeNameSymbol] = "BdkError";
|
|
1080
|
-
/**
|
|
1081
|
-
* @private
|
|
1082
|
-
* This field is private and should not be used.
|
|
1083
|
-
*/
|
|
1084
|
-
[_uniffiBindgenReactNative.variantOrdinalSymbol] = 24;
|
|
1085
1253
|
tag = BdkError_Tags.FeeBumpAlreadyConfirmed;
|
|
1086
|
-
constructor(
|
|
1087
|
-
super("BdkError", "FeeBumpAlreadyConfirmed"
|
|
1254
|
+
constructor(inner) {
|
|
1255
|
+
super("BdkError", "FeeBumpAlreadyConfirmed");
|
|
1256
|
+
this.inner = Object.freeze(inner);
|
|
1257
|
+
}
|
|
1258
|
+
static new(inner) {
|
|
1259
|
+
return new FeeBumpAlreadyConfirmed_(inner);
|
|
1088
1260
|
}
|
|
1089
|
-
static instanceOf(
|
|
1090
|
-
return
|
|
1261
|
+
static instanceOf(obj) {
|
|
1262
|
+
return obj.tag === BdkError_Tags.FeeBumpAlreadyConfirmed;
|
|
1263
|
+
}
|
|
1264
|
+
static hasInner(obj) {
|
|
1265
|
+
return FeeBumpAlreadyConfirmed_.instanceOf(obj);
|
|
1266
|
+
}
|
|
1267
|
+
static getInner(obj) {
|
|
1268
|
+
return obj.inner;
|
|
1091
1269
|
}
|
|
1092
1270
|
}
|
|
1093
|
-
class
|
|
1271
|
+
class FeeBumpIrreplaceable_ extends _uniffiBindgenReactNative.UniffiError {
|
|
1094
1272
|
/**
|
|
1095
1273
|
* @private
|
|
1096
|
-
* This field is private and should not be used.
|
|
1274
|
+
* This field is private and should not be used, use `tag` instead.
|
|
1097
1275
|
*/
|
|
1098
1276
|
[_uniffiBindgenReactNative.uniffiTypeNameSymbol] = "BdkError";
|
|
1099
|
-
/**
|
|
1100
|
-
* @private
|
|
1101
|
-
* This field is private and should not be used.
|
|
1102
|
-
*/
|
|
1103
|
-
[_uniffiBindgenReactNative.variantOrdinalSymbol] = 25;
|
|
1104
1277
|
tag = BdkError_Tags.FeeBumpIrreplaceable;
|
|
1105
|
-
constructor(
|
|
1106
|
-
super("BdkError", "FeeBumpIrreplaceable"
|
|
1278
|
+
constructor(inner) {
|
|
1279
|
+
super("BdkError", "FeeBumpIrreplaceable");
|
|
1280
|
+
this.inner = Object.freeze(inner);
|
|
1281
|
+
}
|
|
1282
|
+
static new(inner) {
|
|
1283
|
+
return new FeeBumpIrreplaceable_(inner);
|
|
1284
|
+
}
|
|
1285
|
+
static instanceOf(obj) {
|
|
1286
|
+
return obj.tag === BdkError_Tags.FeeBumpIrreplaceable;
|
|
1287
|
+
}
|
|
1288
|
+
static hasInner(obj) {
|
|
1289
|
+
return FeeBumpIrreplaceable_.instanceOf(obj);
|
|
1107
1290
|
}
|
|
1108
|
-
static
|
|
1109
|
-
return
|
|
1291
|
+
static getInner(obj) {
|
|
1292
|
+
return obj.inner;
|
|
1110
1293
|
}
|
|
1111
1294
|
}
|
|
1112
|
-
class
|
|
1295
|
+
class FeeBumpFeeRateUnavailable_ extends _uniffiBindgenReactNative.UniffiError {
|
|
1113
1296
|
/**
|
|
1114
1297
|
* @private
|
|
1115
|
-
* This field is private and should not be used.
|
|
1298
|
+
* This field is private and should not be used, use `tag` instead.
|
|
1116
1299
|
*/
|
|
1117
1300
|
[_uniffiBindgenReactNative.uniffiTypeNameSymbol] = "BdkError";
|
|
1118
|
-
/**
|
|
1119
|
-
* @private
|
|
1120
|
-
* This field is private and should not be used.
|
|
1121
|
-
*/
|
|
1122
|
-
[_uniffiBindgenReactNative.variantOrdinalSymbol] = 26;
|
|
1123
1301
|
tag = BdkError_Tags.FeeBumpFeeRateUnavailable;
|
|
1124
|
-
constructor(
|
|
1125
|
-
super("BdkError", "FeeBumpFeeRateUnavailable"
|
|
1302
|
+
constructor(inner) {
|
|
1303
|
+
super("BdkError", "FeeBumpFeeRateUnavailable");
|
|
1304
|
+
this.inner = Object.freeze(inner);
|
|
1126
1305
|
}
|
|
1127
|
-
static
|
|
1128
|
-
return
|
|
1306
|
+
static new(inner) {
|
|
1307
|
+
return new FeeBumpFeeRateUnavailable_(inner);
|
|
1308
|
+
}
|
|
1309
|
+
static instanceOf(obj) {
|
|
1310
|
+
return obj.tag === BdkError_Tags.FeeBumpFeeRateUnavailable;
|
|
1311
|
+
}
|
|
1312
|
+
static hasInner(obj) {
|
|
1313
|
+
return FeeBumpFeeRateUnavailable_.instanceOf(obj);
|
|
1314
|
+
}
|
|
1315
|
+
static getInner(obj) {
|
|
1316
|
+
return obj.inner;
|
|
1129
1317
|
}
|
|
1130
1318
|
}
|
|
1131
|
-
class
|
|
1319
|
+
class FeeBumpInvalidOutputIndex_ extends _uniffiBindgenReactNative.UniffiError {
|
|
1132
1320
|
/**
|
|
1133
1321
|
* @private
|
|
1134
|
-
* This field is private and should not be used.
|
|
1322
|
+
* This field is private and should not be used, use `tag` instead.
|
|
1135
1323
|
*/
|
|
1136
1324
|
[_uniffiBindgenReactNative.uniffiTypeNameSymbol] = "BdkError";
|
|
1137
|
-
/**
|
|
1138
|
-
* @private
|
|
1139
|
-
* This field is private and should not be used.
|
|
1140
|
-
*/
|
|
1141
|
-
[_uniffiBindgenReactNative.variantOrdinalSymbol] = 27;
|
|
1142
1325
|
tag = BdkError_Tags.FeeBumpInvalidOutputIndex;
|
|
1143
|
-
constructor(
|
|
1144
|
-
super("BdkError", "FeeBumpInvalidOutputIndex"
|
|
1326
|
+
constructor(inner) {
|
|
1327
|
+
super("BdkError", "FeeBumpInvalidOutputIndex");
|
|
1328
|
+
this.inner = Object.freeze(inner);
|
|
1329
|
+
}
|
|
1330
|
+
static new(inner) {
|
|
1331
|
+
return new FeeBumpInvalidOutputIndex_(inner);
|
|
1332
|
+
}
|
|
1333
|
+
static instanceOf(obj) {
|
|
1334
|
+
return obj.tag === BdkError_Tags.FeeBumpInvalidOutputIndex;
|
|
1335
|
+
}
|
|
1336
|
+
static hasInner(obj) {
|
|
1337
|
+
return FeeBumpInvalidOutputIndex_.instanceOf(obj);
|
|
1145
1338
|
}
|
|
1146
|
-
static
|
|
1147
|
-
return
|
|
1339
|
+
static getInner(obj) {
|
|
1340
|
+
return obj.inner;
|
|
1148
1341
|
}
|
|
1149
1342
|
}
|
|
1150
|
-
class
|
|
1343
|
+
class InvalidPsbt_ extends _uniffiBindgenReactNative.UniffiError {
|
|
1151
1344
|
/**
|
|
1152
1345
|
* @private
|
|
1153
|
-
* This field is private and should not be used.
|
|
1346
|
+
* This field is private and should not be used, use `tag` instead.
|
|
1154
1347
|
*/
|
|
1155
1348
|
[_uniffiBindgenReactNative.uniffiTypeNameSymbol] = "BdkError";
|
|
1156
|
-
/**
|
|
1157
|
-
* @private
|
|
1158
|
-
* This field is private and should not be used.
|
|
1159
|
-
*/
|
|
1160
|
-
[_uniffiBindgenReactNative.variantOrdinalSymbol] = 28;
|
|
1161
1349
|
tag = BdkError_Tags.InvalidPsbt;
|
|
1162
|
-
constructor(
|
|
1163
|
-
super("BdkError", "InvalidPsbt"
|
|
1350
|
+
constructor(inner) {
|
|
1351
|
+
super("BdkError", "InvalidPsbt");
|
|
1352
|
+
this.inner = Object.freeze(inner);
|
|
1353
|
+
}
|
|
1354
|
+
static new(inner) {
|
|
1355
|
+
return new InvalidPsbt_(inner);
|
|
1164
1356
|
}
|
|
1165
|
-
static instanceOf(
|
|
1166
|
-
return
|
|
1357
|
+
static instanceOf(obj) {
|
|
1358
|
+
return obj.tag === BdkError_Tags.InvalidPsbt;
|
|
1359
|
+
}
|
|
1360
|
+
static hasInner(obj) {
|
|
1361
|
+
return InvalidPsbt_.instanceOf(obj);
|
|
1362
|
+
}
|
|
1363
|
+
static getInner(obj) {
|
|
1364
|
+
return obj.inner;
|
|
1167
1365
|
}
|
|
1168
1366
|
}
|
|
1169
|
-
class
|
|
1367
|
+
class SignFailed_ extends _uniffiBindgenReactNative.UniffiError {
|
|
1170
1368
|
/**
|
|
1171
1369
|
* @private
|
|
1172
|
-
* This field is private and should not be used.
|
|
1370
|
+
* This field is private and should not be used, use `tag` instead.
|
|
1173
1371
|
*/
|
|
1174
1372
|
[_uniffiBindgenReactNative.uniffiTypeNameSymbol] = "BdkError";
|
|
1175
|
-
/**
|
|
1176
|
-
* @private
|
|
1177
|
-
* This field is private and should not be used.
|
|
1178
|
-
*/
|
|
1179
|
-
[_uniffiBindgenReactNative.variantOrdinalSymbol] = 29;
|
|
1180
1373
|
tag = BdkError_Tags.SignFailed;
|
|
1181
|
-
constructor(
|
|
1182
|
-
super("BdkError", "SignFailed"
|
|
1374
|
+
constructor(inner) {
|
|
1375
|
+
super("BdkError", "SignFailed");
|
|
1376
|
+
this.inner = Object.freeze(inner);
|
|
1377
|
+
}
|
|
1378
|
+
static new(inner) {
|
|
1379
|
+
return new SignFailed_(inner);
|
|
1380
|
+
}
|
|
1381
|
+
static instanceOf(obj) {
|
|
1382
|
+
return obj.tag === BdkError_Tags.SignFailed;
|
|
1383
|
+
}
|
|
1384
|
+
static hasInner(obj) {
|
|
1385
|
+
return SignFailed_.instanceOf(obj);
|
|
1183
1386
|
}
|
|
1184
|
-
static
|
|
1185
|
-
return
|
|
1387
|
+
static getInner(obj) {
|
|
1388
|
+
return obj.inner;
|
|
1186
1389
|
}
|
|
1187
1390
|
}
|
|
1188
|
-
class
|
|
1391
|
+
class SignerMissingKey_ extends _uniffiBindgenReactNative.UniffiError {
|
|
1189
1392
|
/**
|
|
1190
1393
|
* @private
|
|
1191
|
-
* This field is private and should not be used.
|
|
1394
|
+
* This field is private and should not be used, use `tag` instead.
|
|
1192
1395
|
*/
|
|
1193
1396
|
[_uniffiBindgenReactNative.uniffiTypeNameSymbol] = "BdkError";
|
|
1194
|
-
/**
|
|
1195
|
-
* @private
|
|
1196
|
-
* This field is private and should not be used.
|
|
1197
|
-
*/
|
|
1198
|
-
[_uniffiBindgenReactNative.variantOrdinalSymbol] = 30;
|
|
1199
1397
|
tag = BdkError_Tags.SignerMissingKey;
|
|
1200
|
-
constructor(
|
|
1201
|
-
super("BdkError", "SignerMissingKey"
|
|
1398
|
+
constructor(inner) {
|
|
1399
|
+
super("BdkError", "SignerMissingKey");
|
|
1400
|
+
this.inner = Object.freeze(inner);
|
|
1401
|
+
}
|
|
1402
|
+
static new(inner) {
|
|
1403
|
+
return new SignerMissingKey_(inner);
|
|
1404
|
+
}
|
|
1405
|
+
static instanceOf(obj) {
|
|
1406
|
+
return obj.tag === BdkError_Tags.SignerMissingKey;
|
|
1202
1407
|
}
|
|
1203
|
-
static
|
|
1204
|
-
return instanceOf(
|
|
1408
|
+
static hasInner(obj) {
|
|
1409
|
+
return SignerMissingKey_.instanceOf(obj);
|
|
1410
|
+
}
|
|
1411
|
+
static getInner(obj) {
|
|
1412
|
+
return obj.inner;
|
|
1205
1413
|
}
|
|
1206
1414
|
}
|
|
1207
|
-
class
|
|
1415
|
+
class SignerInvalidKey_ extends _uniffiBindgenReactNative.UniffiError {
|
|
1208
1416
|
/**
|
|
1209
1417
|
* @private
|
|
1210
|
-
* This field is private and should not be used.
|
|
1418
|
+
* This field is private and should not be used, use `tag` instead.
|
|
1211
1419
|
*/
|
|
1212
1420
|
[_uniffiBindgenReactNative.uniffiTypeNameSymbol] = "BdkError";
|
|
1213
|
-
/**
|
|
1214
|
-
* @private
|
|
1215
|
-
* This field is private and should not be used.
|
|
1216
|
-
*/
|
|
1217
|
-
[_uniffiBindgenReactNative.variantOrdinalSymbol] = 31;
|
|
1218
1421
|
tag = BdkError_Tags.SignerInvalidKey;
|
|
1219
|
-
constructor(
|
|
1220
|
-
super("BdkError", "SignerInvalidKey"
|
|
1422
|
+
constructor(inner) {
|
|
1423
|
+
super("BdkError", "SignerInvalidKey");
|
|
1424
|
+
this.inner = Object.freeze(inner);
|
|
1425
|
+
}
|
|
1426
|
+
static new(inner) {
|
|
1427
|
+
return new SignerInvalidKey_(inner);
|
|
1428
|
+
}
|
|
1429
|
+
static instanceOf(obj) {
|
|
1430
|
+
return obj.tag === BdkError_Tags.SignerInvalidKey;
|
|
1431
|
+
}
|
|
1432
|
+
static hasInner(obj) {
|
|
1433
|
+
return SignerInvalidKey_.instanceOf(obj);
|
|
1221
1434
|
}
|
|
1222
|
-
static
|
|
1223
|
-
return
|
|
1435
|
+
static getInner(obj) {
|
|
1436
|
+
return obj.inner;
|
|
1224
1437
|
}
|
|
1225
1438
|
}
|
|
1226
|
-
class
|
|
1439
|
+
class SignerUserCanceled_ extends _uniffiBindgenReactNative.UniffiError {
|
|
1227
1440
|
/**
|
|
1228
1441
|
* @private
|
|
1229
|
-
* This field is private and should not be used.
|
|
1442
|
+
* This field is private and should not be used, use `tag` instead.
|
|
1230
1443
|
*/
|
|
1231
1444
|
[_uniffiBindgenReactNative.uniffiTypeNameSymbol] = "BdkError";
|
|
1232
|
-
/**
|
|
1233
|
-
* @private
|
|
1234
|
-
* This field is private and should not be used.
|
|
1235
|
-
*/
|
|
1236
|
-
[_uniffiBindgenReactNative.variantOrdinalSymbol] = 32;
|
|
1237
1445
|
tag = BdkError_Tags.SignerUserCanceled;
|
|
1238
|
-
constructor(
|
|
1239
|
-
super("BdkError", "SignerUserCanceled"
|
|
1446
|
+
constructor(inner) {
|
|
1447
|
+
super("BdkError", "SignerUserCanceled");
|
|
1448
|
+
this.inner = Object.freeze(inner);
|
|
1449
|
+
}
|
|
1450
|
+
static new(inner) {
|
|
1451
|
+
return new SignerUserCanceled_(inner);
|
|
1240
1452
|
}
|
|
1241
|
-
static instanceOf(
|
|
1242
|
-
return
|
|
1453
|
+
static instanceOf(obj) {
|
|
1454
|
+
return obj.tag === BdkError_Tags.SignerUserCanceled;
|
|
1455
|
+
}
|
|
1456
|
+
static hasInner(obj) {
|
|
1457
|
+
return SignerUserCanceled_.instanceOf(obj);
|
|
1458
|
+
}
|
|
1459
|
+
static getInner(obj) {
|
|
1460
|
+
return obj.inner;
|
|
1243
1461
|
}
|
|
1244
1462
|
}
|
|
1245
|
-
class
|
|
1463
|
+
class SignerInputIndexOutOfRange_ extends _uniffiBindgenReactNative.UniffiError {
|
|
1246
1464
|
/**
|
|
1247
1465
|
* @private
|
|
1248
|
-
* This field is private and should not be used.
|
|
1466
|
+
* This field is private and should not be used, use `tag` instead.
|
|
1249
1467
|
*/
|
|
1250
1468
|
[_uniffiBindgenReactNative.uniffiTypeNameSymbol] = "BdkError";
|
|
1251
|
-
/**
|
|
1252
|
-
* @private
|
|
1253
|
-
* This field is private and should not be used.
|
|
1254
|
-
*/
|
|
1255
|
-
[_uniffiBindgenReactNative.variantOrdinalSymbol] = 33;
|
|
1256
1469
|
tag = BdkError_Tags.SignerInputIndexOutOfRange;
|
|
1257
|
-
constructor(
|
|
1258
|
-
super("BdkError", "SignerInputIndexOutOfRange"
|
|
1470
|
+
constructor(inner) {
|
|
1471
|
+
super("BdkError", "SignerInputIndexOutOfRange");
|
|
1472
|
+
this.inner = Object.freeze(inner);
|
|
1473
|
+
}
|
|
1474
|
+
static new(inner) {
|
|
1475
|
+
return new SignerInputIndexOutOfRange_(inner);
|
|
1476
|
+
}
|
|
1477
|
+
static instanceOf(obj) {
|
|
1478
|
+
return obj.tag === BdkError_Tags.SignerInputIndexOutOfRange;
|
|
1479
|
+
}
|
|
1480
|
+
static hasInner(obj) {
|
|
1481
|
+
return SignerInputIndexOutOfRange_.instanceOf(obj);
|
|
1259
1482
|
}
|
|
1260
|
-
static
|
|
1261
|
-
return
|
|
1483
|
+
static getInner(obj) {
|
|
1484
|
+
return obj.inner;
|
|
1262
1485
|
}
|
|
1263
1486
|
}
|
|
1264
|
-
class
|
|
1487
|
+
class SignerMissingNonWitnessUtxo_ extends _uniffiBindgenReactNative.UniffiError {
|
|
1265
1488
|
/**
|
|
1266
1489
|
* @private
|
|
1267
|
-
* This field is private and should not be used.
|
|
1490
|
+
* This field is private and should not be used, use `tag` instead.
|
|
1268
1491
|
*/
|
|
1269
1492
|
[_uniffiBindgenReactNative.uniffiTypeNameSymbol] = "BdkError";
|
|
1270
|
-
/**
|
|
1271
|
-
* @private
|
|
1272
|
-
* This field is private and should not be used.
|
|
1273
|
-
*/
|
|
1274
|
-
[_uniffiBindgenReactNative.variantOrdinalSymbol] = 34;
|
|
1275
1493
|
tag = BdkError_Tags.SignerMissingNonWitnessUtxo;
|
|
1276
|
-
constructor(
|
|
1277
|
-
super("BdkError", "SignerMissingNonWitnessUtxo"
|
|
1494
|
+
constructor(inner) {
|
|
1495
|
+
super("BdkError", "SignerMissingNonWitnessUtxo");
|
|
1496
|
+
this.inner = Object.freeze(inner);
|
|
1278
1497
|
}
|
|
1279
|
-
static
|
|
1280
|
-
return
|
|
1498
|
+
static new(inner) {
|
|
1499
|
+
return new SignerMissingNonWitnessUtxo_(inner);
|
|
1500
|
+
}
|
|
1501
|
+
static instanceOf(obj) {
|
|
1502
|
+
return obj.tag === BdkError_Tags.SignerMissingNonWitnessUtxo;
|
|
1503
|
+
}
|
|
1504
|
+
static hasInner(obj) {
|
|
1505
|
+
return SignerMissingNonWitnessUtxo_.instanceOf(obj);
|
|
1506
|
+
}
|
|
1507
|
+
static getInner(obj) {
|
|
1508
|
+
return obj.inner;
|
|
1281
1509
|
}
|
|
1282
1510
|
}
|
|
1283
|
-
class
|
|
1511
|
+
class SignerMissingWitnessUtxo_ extends _uniffiBindgenReactNative.UniffiError {
|
|
1284
1512
|
/**
|
|
1285
1513
|
* @private
|
|
1286
|
-
* This field is private and should not be used.
|
|
1514
|
+
* This field is private and should not be used, use `tag` instead.
|
|
1287
1515
|
*/
|
|
1288
1516
|
[_uniffiBindgenReactNative.uniffiTypeNameSymbol] = "BdkError";
|
|
1289
|
-
/**
|
|
1290
|
-
* @private
|
|
1291
|
-
* This field is private and should not be used.
|
|
1292
|
-
*/
|
|
1293
|
-
[_uniffiBindgenReactNative.variantOrdinalSymbol] = 35;
|
|
1294
1517
|
tag = BdkError_Tags.SignerMissingWitnessUtxo;
|
|
1295
|
-
constructor(
|
|
1296
|
-
super("BdkError", "SignerMissingWitnessUtxo"
|
|
1518
|
+
constructor(inner) {
|
|
1519
|
+
super("BdkError", "SignerMissingWitnessUtxo");
|
|
1520
|
+
this.inner = Object.freeze(inner);
|
|
1521
|
+
}
|
|
1522
|
+
static new(inner) {
|
|
1523
|
+
return new SignerMissingWitnessUtxo_(inner);
|
|
1524
|
+
}
|
|
1525
|
+
static instanceOf(obj) {
|
|
1526
|
+
return obj.tag === BdkError_Tags.SignerMissingWitnessUtxo;
|
|
1527
|
+
}
|
|
1528
|
+
static hasInner(obj) {
|
|
1529
|
+
return SignerMissingWitnessUtxo_.instanceOf(obj);
|
|
1297
1530
|
}
|
|
1298
|
-
static
|
|
1299
|
-
return
|
|
1531
|
+
static getInner(obj) {
|
|
1532
|
+
return obj.inner;
|
|
1300
1533
|
}
|
|
1301
1534
|
}
|
|
1302
|
-
class
|
|
1535
|
+
class SignerMissingWitnessScript_ extends _uniffiBindgenReactNative.UniffiError {
|
|
1303
1536
|
/**
|
|
1304
1537
|
* @private
|
|
1305
|
-
* This field is private and should not be used.
|
|
1538
|
+
* This field is private and should not be used, use `tag` instead.
|
|
1306
1539
|
*/
|
|
1307
1540
|
[_uniffiBindgenReactNative.uniffiTypeNameSymbol] = "BdkError";
|
|
1308
|
-
/**
|
|
1309
|
-
* @private
|
|
1310
|
-
* This field is private and should not be used.
|
|
1311
|
-
*/
|
|
1312
|
-
[_uniffiBindgenReactNative.variantOrdinalSymbol] = 36;
|
|
1313
1541
|
tag = BdkError_Tags.SignerMissingWitnessScript;
|
|
1314
|
-
constructor(
|
|
1315
|
-
super("BdkError", "SignerMissingWitnessScript"
|
|
1542
|
+
constructor(inner) {
|
|
1543
|
+
super("BdkError", "SignerMissingWitnessScript");
|
|
1544
|
+
this.inner = Object.freeze(inner);
|
|
1316
1545
|
}
|
|
1317
|
-
static
|
|
1318
|
-
return
|
|
1546
|
+
static new(inner) {
|
|
1547
|
+
return new SignerMissingWitnessScript_(inner);
|
|
1319
1548
|
}
|
|
1320
|
-
|
|
1321
|
-
|
|
1549
|
+
static instanceOf(obj) {
|
|
1550
|
+
return obj.tag === BdkError_Tags.SignerMissingWitnessScript;
|
|
1551
|
+
}
|
|
1552
|
+
static hasInner(obj) {
|
|
1553
|
+
return SignerMissingWitnessScript_.instanceOf(obj);
|
|
1554
|
+
}
|
|
1555
|
+
static getInner(obj) {
|
|
1556
|
+
return obj.inner;
|
|
1557
|
+
}
|
|
1558
|
+
}
|
|
1559
|
+
class SignerNonStandardSighash_ extends _uniffiBindgenReactNative.UniffiError {
|
|
1322
1560
|
/**
|
|
1323
1561
|
* @private
|
|
1324
|
-
* This field is private and should not be used.
|
|
1562
|
+
* This field is private and should not be used, use `tag` instead.
|
|
1325
1563
|
*/
|
|
1326
1564
|
[_uniffiBindgenReactNative.uniffiTypeNameSymbol] = "BdkError";
|
|
1327
|
-
/**
|
|
1328
|
-
* @private
|
|
1329
|
-
* This field is private and should not be used.
|
|
1330
|
-
*/
|
|
1331
|
-
[_uniffiBindgenReactNative.variantOrdinalSymbol] = 37;
|
|
1332
1565
|
tag = BdkError_Tags.SignerNonStandardSighash;
|
|
1333
|
-
constructor(
|
|
1334
|
-
super("BdkError", "SignerNonStandardSighash"
|
|
1566
|
+
constructor(inner) {
|
|
1567
|
+
super("BdkError", "SignerNonStandardSighash");
|
|
1568
|
+
this.inner = Object.freeze(inner);
|
|
1569
|
+
}
|
|
1570
|
+
static new(inner) {
|
|
1571
|
+
return new SignerNonStandardSighash_(inner);
|
|
1572
|
+
}
|
|
1573
|
+
static instanceOf(obj) {
|
|
1574
|
+
return obj.tag === BdkError_Tags.SignerNonStandardSighash;
|
|
1575
|
+
}
|
|
1576
|
+
static hasInner(obj) {
|
|
1577
|
+
return SignerNonStandardSighash_.instanceOf(obj);
|
|
1335
1578
|
}
|
|
1336
|
-
static
|
|
1337
|
-
return
|
|
1579
|
+
static getInner(obj) {
|
|
1580
|
+
return obj.inner;
|
|
1338
1581
|
}
|
|
1339
1582
|
}
|
|
1340
|
-
class
|
|
1583
|
+
class SignerInvalidSighash_ extends _uniffiBindgenReactNative.UniffiError {
|
|
1341
1584
|
/**
|
|
1342
1585
|
* @private
|
|
1343
|
-
* This field is private and should not be used.
|
|
1586
|
+
* This field is private and should not be used, use `tag` instead.
|
|
1344
1587
|
*/
|
|
1345
1588
|
[_uniffiBindgenReactNative.uniffiTypeNameSymbol] = "BdkError";
|
|
1346
|
-
/**
|
|
1347
|
-
* @private
|
|
1348
|
-
* This field is private and should not be used.
|
|
1349
|
-
*/
|
|
1350
|
-
[_uniffiBindgenReactNative.variantOrdinalSymbol] = 38;
|
|
1351
1589
|
tag = BdkError_Tags.SignerInvalidSighash;
|
|
1352
|
-
constructor(
|
|
1353
|
-
super("BdkError", "SignerInvalidSighash"
|
|
1590
|
+
constructor(inner) {
|
|
1591
|
+
super("BdkError", "SignerInvalidSighash");
|
|
1592
|
+
this.inner = Object.freeze(inner);
|
|
1593
|
+
}
|
|
1594
|
+
static new(inner) {
|
|
1595
|
+
return new SignerInvalidSighash_(inner);
|
|
1354
1596
|
}
|
|
1355
|
-
static instanceOf(
|
|
1356
|
-
return
|
|
1597
|
+
static instanceOf(obj) {
|
|
1598
|
+
return obj.tag === BdkError_Tags.SignerInvalidSighash;
|
|
1599
|
+
}
|
|
1600
|
+
static hasInner(obj) {
|
|
1601
|
+
return SignerInvalidSighash_.instanceOf(obj);
|
|
1602
|
+
}
|
|
1603
|
+
static getInner(obj) {
|
|
1604
|
+
return obj.inner;
|
|
1357
1605
|
}
|
|
1358
1606
|
}
|
|
1359
|
-
class
|
|
1607
|
+
class SyncFailed_ extends _uniffiBindgenReactNative.UniffiError {
|
|
1360
1608
|
/**
|
|
1361
1609
|
* @private
|
|
1362
|
-
* This field is private and should not be used.
|
|
1610
|
+
* This field is private and should not be used, use `tag` instead.
|
|
1363
1611
|
*/
|
|
1364
1612
|
[_uniffiBindgenReactNative.uniffiTypeNameSymbol] = "BdkError";
|
|
1365
|
-
/**
|
|
1366
|
-
* @private
|
|
1367
|
-
* This field is private and should not be used.
|
|
1368
|
-
*/
|
|
1369
|
-
[_uniffiBindgenReactNative.variantOrdinalSymbol] = 39;
|
|
1370
1613
|
tag = BdkError_Tags.SyncFailed;
|
|
1371
|
-
constructor(
|
|
1372
|
-
super("BdkError", "SyncFailed"
|
|
1614
|
+
constructor(inner) {
|
|
1615
|
+
super("BdkError", "SyncFailed");
|
|
1616
|
+
this.inner = Object.freeze(inner);
|
|
1617
|
+
}
|
|
1618
|
+
static new(inner) {
|
|
1619
|
+
return new SyncFailed_(inner);
|
|
1620
|
+
}
|
|
1621
|
+
static instanceOf(obj) {
|
|
1622
|
+
return obj.tag === BdkError_Tags.SyncFailed;
|
|
1623
|
+
}
|
|
1624
|
+
static hasInner(obj) {
|
|
1625
|
+
return SyncFailed_.instanceOf(obj);
|
|
1373
1626
|
}
|
|
1374
|
-
static
|
|
1375
|
-
return
|
|
1627
|
+
static getInner(obj) {
|
|
1628
|
+
return obj.inner;
|
|
1376
1629
|
}
|
|
1377
1630
|
}
|
|
1378
|
-
class
|
|
1631
|
+
class BroadcastFailed_ extends _uniffiBindgenReactNative.UniffiError {
|
|
1379
1632
|
/**
|
|
1380
1633
|
* @private
|
|
1381
|
-
* This field is private and should not be used.
|
|
1634
|
+
* This field is private and should not be used, use `tag` instead.
|
|
1382
1635
|
*/
|
|
1383
1636
|
[_uniffiBindgenReactNative.uniffiTypeNameSymbol] = "BdkError";
|
|
1384
|
-
/**
|
|
1385
|
-
* @private
|
|
1386
|
-
* This field is private and should not be used.
|
|
1387
|
-
*/
|
|
1388
|
-
[_uniffiBindgenReactNative.variantOrdinalSymbol] = 40;
|
|
1389
1637
|
tag = BdkError_Tags.BroadcastFailed;
|
|
1390
|
-
constructor(
|
|
1391
|
-
super("BdkError", "BroadcastFailed"
|
|
1638
|
+
constructor(inner) {
|
|
1639
|
+
super("BdkError", "BroadcastFailed");
|
|
1640
|
+
this.inner = Object.freeze(inner);
|
|
1641
|
+
}
|
|
1642
|
+
static new(inner) {
|
|
1643
|
+
return new BroadcastFailed_(inner);
|
|
1644
|
+
}
|
|
1645
|
+
static instanceOf(obj) {
|
|
1646
|
+
return obj.tag === BdkError_Tags.BroadcastFailed;
|
|
1392
1647
|
}
|
|
1393
|
-
static
|
|
1394
|
-
return instanceOf(
|
|
1648
|
+
static hasInner(obj) {
|
|
1649
|
+
return BroadcastFailed_.instanceOf(obj);
|
|
1650
|
+
}
|
|
1651
|
+
static getInner(obj) {
|
|
1652
|
+
return obj.inner;
|
|
1395
1653
|
}
|
|
1396
1654
|
}
|
|
1397
|
-
class
|
|
1655
|
+
class InvalidTransaction_ extends _uniffiBindgenReactNative.UniffiError {
|
|
1398
1656
|
/**
|
|
1399
1657
|
* @private
|
|
1400
|
-
* This field is private and should not be used.
|
|
1658
|
+
* This field is private and should not be used, use `tag` instead.
|
|
1401
1659
|
*/
|
|
1402
1660
|
[_uniffiBindgenReactNative.uniffiTypeNameSymbol] = "BdkError";
|
|
1403
|
-
/**
|
|
1404
|
-
* @private
|
|
1405
|
-
* This field is private and should not be used.
|
|
1406
|
-
*/
|
|
1407
|
-
[_uniffiBindgenReactNative.variantOrdinalSymbol] = 41;
|
|
1408
1661
|
tag = BdkError_Tags.InvalidTransaction;
|
|
1409
|
-
constructor(
|
|
1410
|
-
super("BdkError", "InvalidTransaction"
|
|
1662
|
+
constructor(inner) {
|
|
1663
|
+
super("BdkError", "InvalidTransaction");
|
|
1664
|
+
this.inner = Object.freeze(inner);
|
|
1665
|
+
}
|
|
1666
|
+
static new(inner) {
|
|
1667
|
+
return new InvalidTransaction_(inner);
|
|
1668
|
+
}
|
|
1669
|
+
static instanceOf(obj) {
|
|
1670
|
+
return obj.tag === BdkError_Tags.InvalidTransaction;
|
|
1671
|
+
}
|
|
1672
|
+
static hasInner(obj) {
|
|
1673
|
+
return InvalidTransaction_.instanceOf(obj);
|
|
1411
1674
|
}
|
|
1412
|
-
static
|
|
1413
|
-
return
|
|
1675
|
+
static getInner(obj) {
|
|
1676
|
+
return obj.inner;
|
|
1414
1677
|
}
|
|
1415
1678
|
}
|
|
1416
|
-
class
|
|
1679
|
+
class TransactionNotFound_ extends _uniffiBindgenReactNative.UniffiError {
|
|
1417
1680
|
/**
|
|
1418
1681
|
* @private
|
|
1419
|
-
* This field is private and should not be used.
|
|
1682
|
+
* This field is private and should not be used, use `tag` instead.
|
|
1420
1683
|
*/
|
|
1421
1684
|
[_uniffiBindgenReactNative.uniffiTypeNameSymbol] = "BdkError";
|
|
1422
|
-
/**
|
|
1423
|
-
* @private
|
|
1424
|
-
* This field is private and should not be used.
|
|
1425
|
-
*/
|
|
1426
|
-
[_uniffiBindgenReactNative.variantOrdinalSymbol] = 42;
|
|
1427
1685
|
tag = BdkError_Tags.TransactionNotFound;
|
|
1428
|
-
constructor(
|
|
1429
|
-
super("BdkError", "TransactionNotFound"
|
|
1686
|
+
constructor(inner) {
|
|
1687
|
+
super("BdkError", "TransactionNotFound");
|
|
1688
|
+
this.inner = Object.freeze(inner);
|
|
1689
|
+
}
|
|
1690
|
+
static new(inner) {
|
|
1691
|
+
return new TransactionNotFound_(inner);
|
|
1430
1692
|
}
|
|
1431
|
-
static instanceOf(
|
|
1432
|
-
return
|
|
1693
|
+
static instanceOf(obj) {
|
|
1694
|
+
return obj.tag === BdkError_Tags.TransactionNotFound;
|
|
1695
|
+
}
|
|
1696
|
+
static hasInner(obj) {
|
|
1697
|
+
return TransactionNotFound_.instanceOf(obj);
|
|
1698
|
+
}
|
|
1699
|
+
static getInner(obj) {
|
|
1700
|
+
return obj.inner;
|
|
1433
1701
|
}
|
|
1434
1702
|
}
|
|
1435
|
-
class
|
|
1703
|
+
class CannotConnect_ extends _uniffiBindgenReactNative.UniffiError {
|
|
1436
1704
|
/**
|
|
1437
1705
|
* @private
|
|
1438
|
-
* This field is private and should not be used.
|
|
1706
|
+
* This field is private and should not be used, use `tag` instead.
|
|
1439
1707
|
*/
|
|
1440
1708
|
[_uniffiBindgenReactNative.uniffiTypeNameSymbol] = "BdkError";
|
|
1441
|
-
/**
|
|
1442
|
-
* @private
|
|
1443
|
-
* This field is private and should not be used.
|
|
1444
|
-
*/
|
|
1445
|
-
[_uniffiBindgenReactNative.variantOrdinalSymbol] = 43;
|
|
1446
1709
|
tag = BdkError_Tags.CannotConnect;
|
|
1447
|
-
constructor(
|
|
1448
|
-
super("BdkError", "CannotConnect"
|
|
1710
|
+
constructor(inner) {
|
|
1711
|
+
super("BdkError", "CannotConnect");
|
|
1712
|
+
this.inner = Object.freeze(inner);
|
|
1713
|
+
}
|
|
1714
|
+
static new(inner) {
|
|
1715
|
+
return new CannotConnect_(inner);
|
|
1716
|
+
}
|
|
1717
|
+
static instanceOf(obj) {
|
|
1718
|
+
return obj.tag === BdkError_Tags.CannotConnect;
|
|
1719
|
+
}
|
|
1720
|
+
static hasInner(obj) {
|
|
1721
|
+
return CannotConnect_.instanceOf(obj);
|
|
1449
1722
|
}
|
|
1450
|
-
static
|
|
1451
|
-
return
|
|
1723
|
+
static getInner(obj) {
|
|
1724
|
+
return obj.inner;
|
|
1452
1725
|
}
|
|
1453
1726
|
}
|
|
1454
|
-
class
|
|
1727
|
+
class CalculateFeeError_ extends _uniffiBindgenReactNative.UniffiError {
|
|
1455
1728
|
/**
|
|
1456
1729
|
* @private
|
|
1457
|
-
* This field is private and should not be used.
|
|
1730
|
+
* This field is private and should not be used, use `tag` instead.
|
|
1458
1731
|
*/
|
|
1459
1732
|
[_uniffiBindgenReactNative.uniffiTypeNameSymbol] = "BdkError";
|
|
1460
|
-
/**
|
|
1461
|
-
* @private
|
|
1462
|
-
* This field is private and should not be used.
|
|
1463
|
-
*/
|
|
1464
|
-
[_uniffiBindgenReactNative.variantOrdinalSymbol] = 44;
|
|
1465
1733
|
tag = BdkError_Tags.CalculateFeeError;
|
|
1466
|
-
constructor(
|
|
1467
|
-
super("BdkError", "CalculateFeeError"
|
|
1734
|
+
constructor(inner) {
|
|
1735
|
+
super("BdkError", "CalculateFeeError");
|
|
1736
|
+
this.inner = Object.freeze(inner);
|
|
1468
1737
|
}
|
|
1469
|
-
static
|
|
1470
|
-
return
|
|
1738
|
+
static new(inner) {
|
|
1739
|
+
return new CalculateFeeError_(inner);
|
|
1740
|
+
}
|
|
1741
|
+
static instanceOf(obj) {
|
|
1742
|
+
return obj.tag === BdkError_Tags.CalculateFeeError;
|
|
1743
|
+
}
|
|
1744
|
+
static hasInner(obj) {
|
|
1745
|
+
return CalculateFeeError_.instanceOf(obj);
|
|
1746
|
+
}
|
|
1747
|
+
static getInner(obj) {
|
|
1748
|
+
return obj.inner;
|
|
1471
1749
|
}
|
|
1472
1750
|
}
|
|
1473
|
-
class
|
|
1751
|
+
class InvalidMnemonic_ extends _uniffiBindgenReactNative.UniffiError {
|
|
1474
1752
|
/**
|
|
1475
1753
|
* @private
|
|
1476
|
-
* This field is private and should not be used.
|
|
1754
|
+
* This field is private and should not be used, use `tag` instead.
|
|
1477
1755
|
*/
|
|
1478
1756
|
[_uniffiBindgenReactNative.uniffiTypeNameSymbol] = "BdkError";
|
|
1479
|
-
/**
|
|
1480
|
-
* @private
|
|
1481
|
-
* This field is private and should not be used.
|
|
1482
|
-
*/
|
|
1483
|
-
[_uniffiBindgenReactNative.variantOrdinalSymbol] = 45;
|
|
1484
1757
|
tag = BdkError_Tags.InvalidMnemonic;
|
|
1485
|
-
constructor(
|
|
1486
|
-
super("BdkError", "InvalidMnemonic"
|
|
1758
|
+
constructor(inner) {
|
|
1759
|
+
super("BdkError", "InvalidMnemonic");
|
|
1760
|
+
this.inner = Object.freeze(inner);
|
|
1761
|
+
}
|
|
1762
|
+
static new(inner) {
|
|
1763
|
+
return new InvalidMnemonic_(inner);
|
|
1764
|
+
}
|
|
1765
|
+
static instanceOf(obj) {
|
|
1766
|
+
return obj.tag === BdkError_Tags.InvalidMnemonic;
|
|
1767
|
+
}
|
|
1768
|
+
static hasInner(obj) {
|
|
1769
|
+
return InvalidMnemonic_.instanceOf(obj);
|
|
1487
1770
|
}
|
|
1488
|
-
static
|
|
1489
|
-
return
|
|
1771
|
+
static getInner(obj) {
|
|
1772
|
+
return obj.inner;
|
|
1490
1773
|
}
|
|
1491
1774
|
}
|
|
1492
|
-
class
|
|
1775
|
+
class InvalidEntropy_ extends _uniffiBindgenReactNative.UniffiError {
|
|
1493
1776
|
/**
|
|
1494
1777
|
* @private
|
|
1495
|
-
* This field is private and should not be used.
|
|
1778
|
+
* This field is private and should not be used, use `tag` instead.
|
|
1496
1779
|
*/
|
|
1497
1780
|
[_uniffiBindgenReactNative.uniffiTypeNameSymbol] = "BdkError";
|
|
1498
|
-
/**
|
|
1499
|
-
* @private
|
|
1500
|
-
* This field is private and should not be used.
|
|
1501
|
-
*/
|
|
1502
|
-
[_uniffiBindgenReactNative.variantOrdinalSymbol] = 46;
|
|
1503
1781
|
tag = BdkError_Tags.InvalidEntropy;
|
|
1504
|
-
constructor(
|
|
1505
|
-
super("BdkError", "InvalidEntropy"
|
|
1782
|
+
constructor(inner) {
|
|
1783
|
+
super("BdkError", "InvalidEntropy");
|
|
1784
|
+
this.inner = Object.freeze(inner);
|
|
1785
|
+
}
|
|
1786
|
+
static new(inner) {
|
|
1787
|
+
return new InvalidEntropy_(inner);
|
|
1506
1788
|
}
|
|
1507
|
-
static instanceOf(
|
|
1508
|
-
return
|
|
1789
|
+
static instanceOf(obj) {
|
|
1790
|
+
return obj.tag === BdkError_Tags.InvalidEntropy;
|
|
1791
|
+
}
|
|
1792
|
+
static hasInner(obj) {
|
|
1793
|
+
return InvalidEntropy_.instanceOf(obj);
|
|
1794
|
+
}
|
|
1795
|
+
static getInner(obj) {
|
|
1796
|
+
return obj.inner;
|
|
1509
1797
|
}
|
|
1510
1798
|
}
|
|
1511
|
-
class
|
|
1799
|
+
class KeyError_ extends _uniffiBindgenReactNative.UniffiError {
|
|
1512
1800
|
/**
|
|
1513
1801
|
* @private
|
|
1514
|
-
* This field is private and should not be used.
|
|
1802
|
+
* This field is private and should not be used, use `tag` instead.
|
|
1515
1803
|
*/
|
|
1516
1804
|
[_uniffiBindgenReactNative.uniffiTypeNameSymbol] = "BdkError";
|
|
1517
|
-
/**
|
|
1518
|
-
* @private
|
|
1519
|
-
* This field is private and should not be used.
|
|
1520
|
-
*/
|
|
1521
|
-
[_uniffiBindgenReactNative.variantOrdinalSymbol] = 47;
|
|
1522
1805
|
tag = BdkError_Tags.KeyError;
|
|
1523
|
-
constructor(
|
|
1524
|
-
super("BdkError", "KeyError"
|
|
1806
|
+
constructor(inner) {
|
|
1807
|
+
super("BdkError", "KeyError");
|
|
1808
|
+
this.inner = Object.freeze(inner);
|
|
1809
|
+
}
|
|
1810
|
+
static new(inner) {
|
|
1811
|
+
return new KeyError_(inner);
|
|
1812
|
+
}
|
|
1813
|
+
static instanceOf(obj) {
|
|
1814
|
+
return obj.tag === BdkError_Tags.KeyError;
|
|
1815
|
+
}
|
|
1816
|
+
static hasInner(obj) {
|
|
1817
|
+
return KeyError_.instanceOf(obj);
|
|
1525
1818
|
}
|
|
1526
|
-
static
|
|
1527
|
-
return
|
|
1819
|
+
static getInner(obj) {
|
|
1820
|
+
return obj.inner;
|
|
1528
1821
|
}
|
|
1529
1822
|
}
|
|
1530
|
-
class
|
|
1823
|
+
class Generic_ extends _uniffiBindgenReactNative.UniffiError {
|
|
1531
1824
|
/**
|
|
1532
1825
|
* @private
|
|
1533
|
-
* This field is private and should not be used.
|
|
1826
|
+
* This field is private and should not be used, use `tag` instead.
|
|
1534
1827
|
*/
|
|
1535
1828
|
[_uniffiBindgenReactNative.uniffiTypeNameSymbol] = "BdkError";
|
|
1536
|
-
/**
|
|
1537
|
-
* @private
|
|
1538
|
-
* This field is private and should not be used.
|
|
1539
|
-
*/
|
|
1540
|
-
[_uniffiBindgenReactNative.variantOrdinalSymbol] = 48;
|
|
1541
1829
|
tag = BdkError_Tags.Generic;
|
|
1542
|
-
constructor(
|
|
1543
|
-
super("BdkError", "Generic"
|
|
1830
|
+
constructor(inner) {
|
|
1831
|
+
super("BdkError", "Generic");
|
|
1832
|
+
this.inner = Object.freeze(inner);
|
|
1833
|
+
}
|
|
1834
|
+
static new(inner) {
|
|
1835
|
+
return new Generic_(inner);
|
|
1836
|
+
}
|
|
1837
|
+
static instanceOf(obj) {
|
|
1838
|
+
return obj.tag === BdkError_Tags.Generic;
|
|
1544
1839
|
}
|
|
1545
|
-
static
|
|
1546
|
-
return instanceOf(
|
|
1840
|
+
static hasInner(obj) {
|
|
1841
|
+
return Generic_.instanceOf(obj);
|
|
1842
|
+
}
|
|
1843
|
+
static getInner(obj) {
|
|
1844
|
+
return obj.inner;
|
|
1547
1845
|
}
|
|
1548
1846
|
}
|
|
1549
|
-
|
|
1550
|
-
|
|
1551
|
-
function instanceOf(e) {
|
|
1552
|
-
return e[_uniffiBindgenReactNative.uniffiTypeNameSymbol] === "BdkError";
|
|
1847
|
+
function instanceOf(obj) {
|
|
1848
|
+
return obj[_uniffiBindgenReactNative.uniffiTypeNameSymbol] === "BdkError";
|
|
1553
1849
|
}
|
|
1554
|
-
return {
|
|
1555
|
-
|
|
1556
|
-
|
|
1557
|
-
|
|
1558
|
-
|
|
1559
|
-
|
|
1560
|
-
|
|
1561
|
-
|
|
1562
|
-
|
|
1563
|
-
|
|
1564
|
-
|
|
1565
|
-
|
|
1566
|
-
|
|
1567
|
-
|
|
1568
|
-
|
|
1569
|
-
|
|
1570
|
-
|
|
1571
|
-
|
|
1572
|
-
|
|
1573
|
-
|
|
1574
|
-
|
|
1575
|
-
|
|
1576
|
-
|
|
1577
|
-
|
|
1578
|
-
|
|
1579
|
-
|
|
1580
|
-
|
|
1581
|
-
|
|
1582
|
-
|
|
1583
|
-
|
|
1584
|
-
|
|
1585
|
-
|
|
1586
|
-
|
|
1587
|
-
|
|
1588
|
-
|
|
1589
|
-
|
|
1590
|
-
|
|
1591
|
-
|
|
1592
|
-
|
|
1593
|
-
|
|
1594
|
-
|
|
1595
|
-
|
|
1596
|
-
|
|
1597
|
-
|
|
1598
|
-
|
|
1599
|
-
|
|
1600
|
-
|
|
1601
|
-
|
|
1602
|
-
|
|
1603
|
-
|
|
1604
|
-
};
|
|
1850
|
+
return Object.freeze({
|
|
1851
|
+
instanceOf,
|
|
1852
|
+
InvalidDescriptor: InvalidDescriptor_,
|
|
1853
|
+
WalletCreationFailed: WalletCreationFailed_,
|
|
1854
|
+
WalletLoadFailed: WalletLoadFailed_,
|
|
1855
|
+
WalletLoadMismatch: WalletLoadMismatch_,
|
|
1856
|
+
PersistError: PersistError_,
|
|
1857
|
+
InvalidAddress: InvalidAddress_,
|
|
1858
|
+
InvalidScript: InvalidScript_,
|
|
1859
|
+
TransactionBuildFailed: TransactionBuildFailed_,
|
|
1860
|
+
NoRecipients: NoRecipients_,
|
|
1861
|
+
NoUtxosSelected: NoUtxosSelected_,
|
|
1862
|
+
OutputBelowDustLimit: OutputBelowDustLimit_,
|
|
1863
|
+
InsufficientFunds: InsufficientFunds_,
|
|
1864
|
+
FeeRateTooLow: FeeRateTooLow_,
|
|
1865
|
+
FeeTooLow: FeeTooLow_,
|
|
1866
|
+
LockTimeConflict: LockTimeConflict_,
|
|
1867
|
+
RbfSequenceConflict: RbfSequenceConflict_,
|
|
1868
|
+
VersionZero: VersionZero_,
|
|
1869
|
+
VersionOneCsv: VersionOneCsv_,
|
|
1870
|
+
SpendingPolicyRequired: SpendingPolicyRequired_,
|
|
1871
|
+
MissingKeyOrigin: MissingKeyOrigin_,
|
|
1872
|
+
MissingNonWitnessUtxo: MissingNonWitnessUtxo_,
|
|
1873
|
+
OutpointNotFound: OutpointNotFound_,
|
|
1874
|
+
FeeBumpTargetNotFound: FeeBumpTargetNotFound_,
|
|
1875
|
+
FeeBumpAlreadyConfirmed: FeeBumpAlreadyConfirmed_,
|
|
1876
|
+
FeeBumpIrreplaceable: FeeBumpIrreplaceable_,
|
|
1877
|
+
FeeBumpFeeRateUnavailable: FeeBumpFeeRateUnavailable_,
|
|
1878
|
+
FeeBumpInvalidOutputIndex: FeeBumpInvalidOutputIndex_,
|
|
1879
|
+
InvalidPsbt: InvalidPsbt_,
|
|
1880
|
+
SignFailed: SignFailed_,
|
|
1881
|
+
SignerMissingKey: SignerMissingKey_,
|
|
1882
|
+
SignerInvalidKey: SignerInvalidKey_,
|
|
1883
|
+
SignerUserCanceled: SignerUserCanceled_,
|
|
1884
|
+
SignerInputIndexOutOfRange: SignerInputIndexOutOfRange_,
|
|
1885
|
+
SignerMissingNonWitnessUtxo: SignerMissingNonWitnessUtxo_,
|
|
1886
|
+
SignerMissingWitnessUtxo: SignerMissingWitnessUtxo_,
|
|
1887
|
+
SignerMissingWitnessScript: SignerMissingWitnessScript_,
|
|
1888
|
+
SignerNonStandardSighash: SignerNonStandardSighash_,
|
|
1889
|
+
SignerInvalidSighash: SignerInvalidSighash_,
|
|
1890
|
+
SyncFailed: SyncFailed_,
|
|
1891
|
+
BroadcastFailed: BroadcastFailed_,
|
|
1892
|
+
InvalidTransaction: InvalidTransaction_,
|
|
1893
|
+
TransactionNotFound: TransactionNotFound_,
|
|
1894
|
+
CannotConnect: CannotConnect_,
|
|
1895
|
+
CalculateFeeError: CalculateFeeError_,
|
|
1896
|
+
InvalidMnemonic: InvalidMnemonic_,
|
|
1897
|
+
InvalidEntropy: InvalidEntropy_,
|
|
1898
|
+
KeyError: KeyError_,
|
|
1899
|
+
Generic: Generic_
|
|
1900
|
+
});
|
|
1605
1901
|
})();
|
|
1606
|
-
|
|
1607
|
-
// Union type for BdkError error type.
|
|
1608
|
-
|
|
1902
|
+
// FfiConverter for enum BdkError
|
|
1609
1903
|
const FfiConverterTypeBdkError = (() => {
|
|
1610
|
-
const
|
|
1611
|
-
class
|
|
1904
|
+
const ordinalConverter = _uniffiBindgenReactNative.FfiConverterInt32;
|
|
1905
|
+
class FFIConverter extends _uniffiBindgenReactNative.AbstractFfiConverterByteArray {
|
|
1612
1906
|
read(from) {
|
|
1613
|
-
switch (
|
|
1907
|
+
switch (ordinalConverter.read(from)) {
|
|
1614
1908
|
case 1:
|
|
1615
|
-
return new BdkError.InvalidDescriptor(
|
|
1909
|
+
return new BdkError.InvalidDescriptor({
|
|
1910
|
+
message: FfiConverterString.read(from)
|
|
1911
|
+
});
|
|
1616
1912
|
case 2:
|
|
1617
|
-
return new BdkError.WalletCreationFailed(
|
|
1913
|
+
return new BdkError.WalletCreationFailed({
|
|
1914
|
+
message: FfiConverterString.read(from)
|
|
1915
|
+
});
|
|
1618
1916
|
case 3:
|
|
1619
|
-
return new BdkError.WalletLoadFailed(
|
|
1917
|
+
return new BdkError.WalletLoadFailed({
|
|
1918
|
+
message: FfiConverterString.read(from)
|
|
1919
|
+
});
|
|
1620
1920
|
case 4:
|
|
1621
|
-
return new BdkError.WalletLoadMismatch(
|
|
1921
|
+
return new BdkError.WalletLoadMismatch({
|
|
1922
|
+
message: FfiConverterString.read(from)
|
|
1923
|
+
});
|
|
1622
1924
|
case 5:
|
|
1623
|
-
return new BdkError.PersistError(
|
|
1925
|
+
return new BdkError.PersistError({
|
|
1926
|
+
message: FfiConverterString.read(from)
|
|
1927
|
+
});
|
|
1624
1928
|
case 6:
|
|
1625
|
-
return new BdkError.InvalidAddress(
|
|
1929
|
+
return new BdkError.InvalidAddress({
|
|
1930
|
+
message: FfiConverterString.read(from)
|
|
1931
|
+
});
|
|
1626
1932
|
case 7:
|
|
1627
|
-
return new BdkError.InvalidScript(
|
|
1933
|
+
return new BdkError.InvalidScript({
|
|
1934
|
+
message: FfiConverterString.read(from)
|
|
1935
|
+
});
|
|
1628
1936
|
case 8:
|
|
1629
|
-
return new BdkError.TransactionBuildFailed(
|
|
1937
|
+
return new BdkError.TransactionBuildFailed({
|
|
1938
|
+
message: FfiConverterString.read(from)
|
|
1939
|
+
});
|
|
1630
1940
|
case 9:
|
|
1631
|
-
return new BdkError.NoRecipients(
|
|
1941
|
+
return new BdkError.NoRecipients({
|
|
1942
|
+
message: FfiConverterString.read(from)
|
|
1943
|
+
});
|
|
1632
1944
|
case 10:
|
|
1633
|
-
return new BdkError.NoUtxosSelected(
|
|
1945
|
+
return new BdkError.NoUtxosSelected({
|
|
1946
|
+
message: FfiConverterString.read(from)
|
|
1947
|
+
});
|
|
1634
1948
|
case 11:
|
|
1635
|
-
return new BdkError.OutputBelowDustLimit(
|
|
1949
|
+
return new BdkError.OutputBelowDustLimit({
|
|
1950
|
+
message: FfiConverterString.read(from)
|
|
1951
|
+
});
|
|
1636
1952
|
case 12:
|
|
1637
|
-
return new BdkError.InsufficientFunds(
|
|
1953
|
+
return new BdkError.InsufficientFunds({
|
|
1954
|
+
message: FfiConverterString.read(from)
|
|
1955
|
+
});
|
|
1638
1956
|
case 13:
|
|
1639
|
-
return new BdkError.FeeRateTooLow(
|
|
1957
|
+
return new BdkError.FeeRateTooLow({
|
|
1958
|
+
message: FfiConverterString.read(from)
|
|
1959
|
+
});
|
|
1640
1960
|
case 14:
|
|
1641
|
-
return new BdkError.FeeTooLow(
|
|
1961
|
+
return new BdkError.FeeTooLow({
|
|
1962
|
+
message: FfiConverterString.read(from)
|
|
1963
|
+
});
|
|
1642
1964
|
case 15:
|
|
1643
|
-
return new BdkError.LockTimeConflict(
|
|
1965
|
+
return new BdkError.LockTimeConflict({
|
|
1966
|
+
message: FfiConverterString.read(from)
|
|
1967
|
+
});
|
|
1644
1968
|
case 16:
|
|
1645
|
-
return new BdkError.RbfSequenceConflict(
|
|
1969
|
+
return new BdkError.RbfSequenceConflict({
|
|
1970
|
+
message: FfiConverterString.read(from)
|
|
1971
|
+
});
|
|
1646
1972
|
case 17:
|
|
1647
|
-
return new BdkError.VersionZero(
|
|
1973
|
+
return new BdkError.VersionZero({
|
|
1974
|
+
message: FfiConverterString.read(from)
|
|
1975
|
+
});
|
|
1648
1976
|
case 18:
|
|
1649
|
-
return new BdkError.VersionOneCsv(
|
|
1977
|
+
return new BdkError.VersionOneCsv({
|
|
1978
|
+
message: FfiConverterString.read(from)
|
|
1979
|
+
});
|
|
1650
1980
|
case 19:
|
|
1651
|
-
return new BdkError.SpendingPolicyRequired(
|
|
1981
|
+
return new BdkError.SpendingPolicyRequired({
|
|
1982
|
+
message: FfiConverterString.read(from)
|
|
1983
|
+
});
|
|
1652
1984
|
case 20:
|
|
1653
|
-
return new BdkError.MissingKeyOrigin(
|
|
1985
|
+
return new BdkError.MissingKeyOrigin({
|
|
1986
|
+
message: FfiConverterString.read(from)
|
|
1987
|
+
});
|
|
1654
1988
|
case 21:
|
|
1655
|
-
return new BdkError.MissingNonWitnessUtxo(
|
|
1989
|
+
return new BdkError.MissingNonWitnessUtxo({
|
|
1990
|
+
message: FfiConverterString.read(from)
|
|
1991
|
+
});
|
|
1656
1992
|
case 22:
|
|
1657
|
-
return new BdkError.OutpointNotFound(
|
|
1993
|
+
return new BdkError.OutpointNotFound({
|
|
1994
|
+
message: FfiConverterString.read(from)
|
|
1995
|
+
});
|
|
1658
1996
|
case 23:
|
|
1659
|
-
return new BdkError.FeeBumpTargetNotFound(
|
|
1997
|
+
return new BdkError.FeeBumpTargetNotFound({
|
|
1998
|
+
message: FfiConverterString.read(from)
|
|
1999
|
+
});
|
|
1660
2000
|
case 24:
|
|
1661
|
-
return new BdkError.FeeBumpAlreadyConfirmed(
|
|
2001
|
+
return new BdkError.FeeBumpAlreadyConfirmed({
|
|
2002
|
+
message: FfiConverterString.read(from)
|
|
2003
|
+
});
|
|
1662
2004
|
case 25:
|
|
1663
|
-
return new BdkError.FeeBumpIrreplaceable(
|
|
2005
|
+
return new BdkError.FeeBumpIrreplaceable({
|
|
2006
|
+
message: FfiConverterString.read(from)
|
|
2007
|
+
});
|
|
1664
2008
|
case 26:
|
|
1665
|
-
return new BdkError.FeeBumpFeeRateUnavailable(
|
|
2009
|
+
return new BdkError.FeeBumpFeeRateUnavailable({
|
|
2010
|
+
message: FfiConverterString.read(from)
|
|
2011
|
+
});
|
|
1666
2012
|
case 27:
|
|
1667
|
-
return new BdkError.FeeBumpInvalidOutputIndex(
|
|
2013
|
+
return new BdkError.FeeBumpInvalidOutputIndex({
|
|
2014
|
+
message: FfiConverterString.read(from)
|
|
2015
|
+
});
|
|
1668
2016
|
case 28:
|
|
1669
|
-
return new BdkError.InvalidPsbt(
|
|
2017
|
+
return new BdkError.InvalidPsbt({
|
|
2018
|
+
message: FfiConverterString.read(from)
|
|
2019
|
+
});
|
|
1670
2020
|
case 29:
|
|
1671
|
-
return new BdkError.SignFailed(
|
|
2021
|
+
return new BdkError.SignFailed({
|
|
2022
|
+
message: FfiConverterString.read(from)
|
|
2023
|
+
});
|
|
1672
2024
|
case 30:
|
|
1673
|
-
return new BdkError.SignerMissingKey(
|
|
2025
|
+
return new BdkError.SignerMissingKey({
|
|
2026
|
+
message: FfiConverterString.read(from)
|
|
2027
|
+
});
|
|
1674
2028
|
case 31:
|
|
1675
|
-
return new BdkError.SignerInvalidKey(
|
|
2029
|
+
return new BdkError.SignerInvalidKey({
|
|
2030
|
+
message: FfiConverterString.read(from)
|
|
2031
|
+
});
|
|
1676
2032
|
case 32:
|
|
1677
|
-
return new BdkError.SignerUserCanceled(
|
|
2033
|
+
return new BdkError.SignerUserCanceled({
|
|
2034
|
+
message: FfiConverterString.read(from)
|
|
2035
|
+
});
|
|
1678
2036
|
case 33:
|
|
1679
|
-
return new BdkError.SignerInputIndexOutOfRange(
|
|
2037
|
+
return new BdkError.SignerInputIndexOutOfRange({
|
|
2038
|
+
message: FfiConverterString.read(from)
|
|
2039
|
+
});
|
|
1680
2040
|
case 34:
|
|
1681
|
-
return new BdkError.SignerMissingNonWitnessUtxo(
|
|
2041
|
+
return new BdkError.SignerMissingNonWitnessUtxo({
|
|
2042
|
+
message: FfiConverterString.read(from)
|
|
2043
|
+
});
|
|
1682
2044
|
case 35:
|
|
1683
|
-
return new BdkError.SignerMissingWitnessUtxo(
|
|
2045
|
+
return new BdkError.SignerMissingWitnessUtxo({
|
|
2046
|
+
message: FfiConverterString.read(from)
|
|
2047
|
+
});
|
|
1684
2048
|
case 36:
|
|
1685
|
-
return new BdkError.SignerMissingWitnessScript(
|
|
2049
|
+
return new BdkError.SignerMissingWitnessScript({
|
|
2050
|
+
message: FfiConverterString.read(from)
|
|
2051
|
+
});
|
|
1686
2052
|
case 37:
|
|
1687
|
-
return new BdkError.SignerNonStandardSighash(
|
|
2053
|
+
return new BdkError.SignerNonStandardSighash({
|
|
2054
|
+
message: FfiConverterString.read(from)
|
|
2055
|
+
});
|
|
1688
2056
|
case 38:
|
|
1689
|
-
return new BdkError.SignerInvalidSighash(
|
|
2057
|
+
return new BdkError.SignerInvalidSighash({
|
|
2058
|
+
message: FfiConverterString.read(from)
|
|
2059
|
+
});
|
|
1690
2060
|
case 39:
|
|
1691
|
-
return new BdkError.SyncFailed(
|
|
2061
|
+
return new BdkError.SyncFailed({
|
|
2062
|
+
message: FfiConverterString.read(from)
|
|
2063
|
+
});
|
|
1692
2064
|
case 40:
|
|
1693
|
-
return new BdkError.BroadcastFailed(
|
|
2065
|
+
return new BdkError.BroadcastFailed({
|
|
2066
|
+
message: FfiConverterString.read(from)
|
|
2067
|
+
});
|
|
1694
2068
|
case 41:
|
|
1695
|
-
return new BdkError.InvalidTransaction(
|
|
2069
|
+
return new BdkError.InvalidTransaction({
|
|
2070
|
+
message: FfiConverterString.read(from)
|
|
2071
|
+
});
|
|
1696
2072
|
case 42:
|
|
1697
|
-
return new BdkError.TransactionNotFound(
|
|
2073
|
+
return new BdkError.TransactionNotFound({
|
|
2074
|
+
message: FfiConverterString.read(from)
|
|
2075
|
+
});
|
|
1698
2076
|
case 43:
|
|
1699
|
-
return new BdkError.CannotConnect(
|
|
2077
|
+
return new BdkError.CannotConnect({
|
|
2078
|
+
message: FfiConverterString.read(from)
|
|
2079
|
+
});
|
|
1700
2080
|
case 44:
|
|
1701
|
-
return new BdkError.CalculateFeeError(
|
|
2081
|
+
return new BdkError.CalculateFeeError({
|
|
2082
|
+
message: FfiConverterString.read(from)
|
|
2083
|
+
});
|
|
1702
2084
|
case 45:
|
|
1703
|
-
return new BdkError.InvalidMnemonic(
|
|
2085
|
+
return new BdkError.InvalidMnemonic({
|
|
2086
|
+
message: FfiConverterString.read(from)
|
|
2087
|
+
});
|
|
1704
2088
|
case 46:
|
|
1705
|
-
return new BdkError.InvalidEntropy(
|
|
2089
|
+
return new BdkError.InvalidEntropy({
|
|
2090
|
+
message: FfiConverterString.read(from)
|
|
2091
|
+
});
|
|
1706
2092
|
case 47:
|
|
1707
|
-
return new BdkError.KeyError(
|
|
2093
|
+
return new BdkError.KeyError({
|
|
2094
|
+
message: FfiConverterString.read(from)
|
|
2095
|
+
});
|
|
1708
2096
|
case 48:
|
|
1709
|
-
return new BdkError.Generic(
|
|
2097
|
+
return new BdkError.Generic({
|
|
2098
|
+
message: FfiConverterString.read(from)
|
|
2099
|
+
});
|
|
2100
|
+
default:
|
|
2101
|
+
throw new _uniffiBindgenReactNative.UniffiInternalError.UnexpectedEnumCase();
|
|
2102
|
+
}
|
|
2103
|
+
}
|
|
2104
|
+
write(value, into) {
|
|
2105
|
+
switch (value.tag) {
|
|
2106
|
+
case BdkError_Tags.InvalidDescriptor:
|
|
2107
|
+
{
|
|
2108
|
+
ordinalConverter.write(1, into);
|
|
2109
|
+
const inner = value.inner;
|
|
2110
|
+
FfiConverterString.write(inner.message, into);
|
|
2111
|
+
return;
|
|
2112
|
+
}
|
|
2113
|
+
case BdkError_Tags.WalletCreationFailed:
|
|
2114
|
+
{
|
|
2115
|
+
ordinalConverter.write(2, into);
|
|
2116
|
+
const inner = value.inner;
|
|
2117
|
+
FfiConverterString.write(inner.message, into);
|
|
2118
|
+
return;
|
|
2119
|
+
}
|
|
2120
|
+
case BdkError_Tags.WalletLoadFailed:
|
|
2121
|
+
{
|
|
2122
|
+
ordinalConverter.write(3, into);
|
|
2123
|
+
const inner = value.inner;
|
|
2124
|
+
FfiConverterString.write(inner.message, into);
|
|
2125
|
+
return;
|
|
2126
|
+
}
|
|
2127
|
+
case BdkError_Tags.WalletLoadMismatch:
|
|
2128
|
+
{
|
|
2129
|
+
ordinalConverter.write(4, into);
|
|
2130
|
+
const inner = value.inner;
|
|
2131
|
+
FfiConverterString.write(inner.message, into);
|
|
2132
|
+
return;
|
|
2133
|
+
}
|
|
2134
|
+
case BdkError_Tags.PersistError:
|
|
2135
|
+
{
|
|
2136
|
+
ordinalConverter.write(5, into);
|
|
2137
|
+
const inner = value.inner;
|
|
2138
|
+
FfiConverterString.write(inner.message, into);
|
|
2139
|
+
return;
|
|
2140
|
+
}
|
|
2141
|
+
case BdkError_Tags.InvalidAddress:
|
|
2142
|
+
{
|
|
2143
|
+
ordinalConverter.write(6, into);
|
|
2144
|
+
const inner = value.inner;
|
|
2145
|
+
FfiConverterString.write(inner.message, into);
|
|
2146
|
+
return;
|
|
2147
|
+
}
|
|
2148
|
+
case BdkError_Tags.InvalidScript:
|
|
2149
|
+
{
|
|
2150
|
+
ordinalConverter.write(7, into);
|
|
2151
|
+
const inner = value.inner;
|
|
2152
|
+
FfiConverterString.write(inner.message, into);
|
|
2153
|
+
return;
|
|
2154
|
+
}
|
|
2155
|
+
case BdkError_Tags.TransactionBuildFailed:
|
|
2156
|
+
{
|
|
2157
|
+
ordinalConverter.write(8, into);
|
|
2158
|
+
const inner = value.inner;
|
|
2159
|
+
FfiConverterString.write(inner.message, into);
|
|
2160
|
+
return;
|
|
2161
|
+
}
|
|
2162
|
+
case BdkError_Tags.NoRecipients:
|
|
2163
|
+
{
|
|
2164
|
+
ordinalConverter.write(9, into);
|
|
2165
|
+
const inner = value.inner;
|
|
2166
|
+
FfiConverterString.write(inner.message, into);
|
|
2167
|
+
return;
|
|
2168
|
+
}
|
|
2169
|
+
case BdkError_Tags.NoUtxosSelected:
|
|
2170
|
+
{
|
|
2171
|
+
ordinalConverter.write(10, into);
|
|
2172
|
+
const inner = value.inner;
|
|
2173
|
+
FfiConverterString.write(inner.message, into);
|
|
2174
|
+
return;
|
|
2175
|
+
}
|
|
2176
|
+
case BdkError_Tags.OutputBelowDustLimit:
|
|
2177
|
+
{
|
|
2178
|
+
ordinalConverter.write(11, into);
|
|
2179
|
+
const inner = value.inner;
|
|
2180
|
+
FfiConverterString.write(inner.message, into);
|
|
2181
|
+
return;
|
|
2182
|
+
}
|
|
2183
|
+
case BdkError_Tags.InsufficientFunds:
|
|
2184
|
+
{
|
|
2185
|
+
ordinalConverter.write(12, into);
|
|
2186
|
+
const inner = value.inner;
|
|
2187
|
+
FfiConverterString.write(inner.message, into);
|
|
2188
|
+
return;
|
|
2189
|
+
}
|
|
2190
|
+
case BdkError_Tags.FeeRateTooLow:
|
|
2191
|
+
{
|
|
2192
|
+
ordinalConverter.write(13, into);
|
|
2193
|
+
const inner = value.inner;
|
|
2194
|
+
FfiConverterString.write(inner.message, into);
|
|
2195
|
+
return;
|
|
2196
|
+
}
|
|
2197
|
+
case BdkError_Tags.FeeTooLow:
|
|
2198
|
+
{
|
|
2199
|
+
ordinalConverter.write(14, into);
|
|
2200
|
+
const inner = value.inner;
|
|
2201
|
+
FfiConverterString.write(inner.message, into);
|
|
2202
|
+
return;
|
|
2203
|
+
}
|
|
2204
|
+
case BdkError_Tags.LockTimeConflict:
|
|
2205
|
+
{
|
|
2206
|
+
ordinalConverter.write(15, into);
|
|
2207
|
+
const inner = value.inner;
|
|
2208
|
+
FfiConverterString.write(inner.message, into);
|
|
2209
|
+
return;
|
|
2210
|
+
}
|
|
2211
|
+
case BdkError_Tags.RbfSequenceConflict:
|
|
2212
|
+
{
|
|
2213
|
+
ordinalConverter.write(16, into);
|
|
2214
|
+
const inner = value.inner;
|
|
2215
|
+
FfiConverterString.write(inner.message, into);
|
|
2216
|
+
return;
|
|
2217
|
+
}
|
|
2218
|
+
case BdkError_Tags.VersionZero:
|
|
2219
|
+
{
|
|
2220
|
+
ordinalConverter.write(17, into);
|
|
2221
|
+
const inner = value.inner;
|
|
2222
|
+
FfiConverterString.write(inner.message, into);
|
|
2223
|
+
return;
|
|
2224
|
+
}
|
|
2225
|
+
case BdkError_Tags.VersionOneCsv:
|
|
2226
|
+
{
|
|
2227
|
+
ordinalConverter.write(18, into);
|
|
2228
|
+
const inner = value.inner;
|
|
2229
|
+
FfiConverterString.write(inner.message, into);
|
|
2230
|
+
return;
|
|
2231
|
+
}
|
|
2232
|
+
case BdkError_Tags.SpendingPolicyRequired:
|
|
2233
|
+
{
|
|
2234
|
+
ordinalConverter.write(19, into);
|
|
2235
|
+
const inner = value.inner;
|
|
2236
|
+
FfiConverterString.write(inner.message, into);
|
|
2237
|
+
return;
|
|
2238
|
+
}
|
|
2239
|
+
case BdkError_Tags.MissingKeyOrigin:
|
|
2240
|
+
{
|
|
2241
|
+
ordinalConverter.write(20, into);
|
|
2242
|
+
const inner = value.inner;
|
|
2243
|
+
FfiConverterString.write(inner.message, into);
|
|
2244
|
+
return;
|
|
2245
|
+
}
|
|
2246
|
+
case BdkError_Tags.MissingNonWitnessUtxo:
|
|
2247
|
+
{
|
|
2248
|
+
ordinalConverter.write(21, into);
|
|
2249
|
+
const inner = value.inner;
|
|
2250
|
+
FfiConverterString.write(inner.message, into);
|
|
2251
|
+
return;
|
|
2252
|
+
}
|
|
2253
|
+
case BdkError_Tags.OutpointNotFound:
|
|
2254
|
+
{
|
|
2255
|
+
ordinalConverter.write(22, into);
|
|
2256
|
+
const inner = value.inner;
|
|
2257
|
+
FfiConverterString.write(inner.message, into);
|
|
2258
|
+
return;
|
|
2259
|
+
}
|
|
2260
|
+
case BdkError_Tags.FeeBumpTargetNotFound:
|
|
2261
|
+
{
|
|
2262
|
+
ordinalConverter.write(23, into);
|
|
2263
|
+
const inner = value.inner;
|
|
2264
|
+
FfiConverterString.write(inner.message, into);
|
|
2265
|
+
return;
|
|
2266
|
+
}
|
|
2267
|
+
case BdkError_Tags.FeeBumpAlreadyConfirmed:
|
|
2268
|
+
{
|
|
2269
|
+
ordinalConverter.write(24, into);
|
|
2270
|
+
const inner = value.inner;
|
|
2271
|
+
FfiConverterString.write(inner.message, into);
|
|
2272
|
+
return;
|
|
2273
|
+
}
|
|
2274
|
+
case BdkError_Tags.FeeBumpIrreplaceable:
|
|
2275
|
+
{
|
|
2276
|
+
ordinalConverter.write(25, into);
|
|
2277
|
+
const inner = value.inner;
|
|
2278
|
+
FfiConverterString.write(inner.message, into);
|
|
2279
|
+
return;
|
|
2280
|
+
}
|
|
2281
|
+
case BdkError_Tags.FeeBumpFeeRateUnavailable:
|
|
2282
|
+
{
|
|
2283
|
+
ordinalConverter.write(26, into);
|
|
2284
|
+
const inner = value.inner;
|
|
2285
|
+
FfiConverterString.write(inner.message, into);
|
|
2286
|
+
return;
|
|
2287
|
+
}
|
|
2288
|
+
case BdkError_Tags.FeeBumpInvalidOutputIndex:
|
|
2289
|
+
{
|
|
2290
|
+
ordinalConverter.write(27, into);
|
|
2291
|
+
const inner = value.inner;
|
|
2292
|
+
FfiConverterString.write(inner.message, into);
|
|
2293
|
+
return;
|
|
2294
|
+
}
|
|
2295
|
+
case BdkError_Tags.InvalidPsbt:
|
|
2296
|
+
{
|
|
2297
|
+
ordinalConverter.write(28, into);
|
|
2298
|
+
const inner = value.inner;
|
|
2299
|
+
FfiConverterString.write(inner.message, into);
|
|
2300
|
+
return;
|
|
2301
|
+
}
|
|
2302
|
+
case BdkError_Tags.SignFailed:
|
|
2303
|
+
{
|
|
2304
|
+
ordinalConverter.write(29, into);
|
|
2305
|
+
const inner = value.inner;
|
|
2306
|
+
FfiConverterString.write(inner.message, into);
|
|
2307
|
+
return;
|
|
2308
|
+
}
|
|
2309
|
+
case BdkError_Tags.SignerMissingKey:
|
|
2310
|
+
{
|
|
2311
|
+
ordinalConverter.write(30, into);
|
|
2312
|
+
const inner = value.inner;
|
|
2313
|
+
FfiConverterString.write(inner.message, into);
|
|
2314
|
+
return;
|
|
2315
|
+
}
|
|
2316
|
+
case BdkError_Tags.SignerInvalidKey:
|
|
2317
|
+
{
|
|
2318
|
+
ordinalConverter.write(31, into);
|
|
2319
|
+
const inner = value.inner;
|
|
2320
|
+
FfiConverterString.write(inner.message, into);
|
|
2321
|
+
return;
|
|
2322
|
+
}
|
|
2323
|
+
case BdkError_Tags.SignerUserCanceled:
|
|
2324
|
+
{
|
|
2325
|
+
ordinalConverter.write(32, into);
|
|
2326
|
+
const inner = value.inner;
|
|
2327
|
+
FfiConverterString.write(inner.message, into);
|
|
2328
|
+
return;
|
|
2329
|
+
}
|
|
2330
|
+
case BdkError_Tags.SignerInputIndexOutOfRange:
|
|
2331
|
+
{
|
|
2332
|
+
ordinalConverter.write(33, into);
|
|
2333
|
+
const inner = value.inner;
|
|
2334
|
+
FfiConverterString.write(inner.message, into);
|
|
2335
|
+
return;
|
|
2336
|
+
}
|
|
2337
|
+
case BdkError_Tags.SignerMissingNonWitnessUtxo:
|
|
2338
|
+
{
|
|
2339
|
+
ordinalConverter.write(34, into);
|
|
2340
|
+
const inner = value.inner;
|
|
2341
|
+
FfiConverterString.write(inner.message, into);
|
|
2342
|
+
return;
|
|
2343
|
+
}
|
|
2344
|
+
case BdkError_Tags.SignerMissingWitnessUtxo:
|
|
2345
|
+
{
|
|
2346
|
+
ordinalConverter.write(35, into);
|
|
2347
|
+
const inner = value.inner;
|
|
2348
|
+
FfiConverterString.write(inner.message, into);
|
|
2349
|
+
return;
|
|
2350
|
+
}
|
|
2351
|
+
case BdkError_Tags.SignerMissingWitnessScript:
|
|
2352
|
+
{
|
|
2353
|
+
ordinalConverter.write(36, into);
|
|
2354
|
+
const inner = value.inner;
|
|
2355
|
+
FfiConverterString.write(inner.message, into);
|
|
2356
|
+
return;
|
|
2357
|
+
}
|
|
2358
|
+
case BdkError_Tags.SignerNonStandardSighash:
|
|
2359
|
+
{
|
|
2360
|
+
ordinalConverter.write(37, into);
|
|
2361
|
+
const inner = value.inner;
|
|
2362
|
+
FfiConverterString.write(inner.message, into);
|
|
2363
|
+
return;
|
|
2364
|
+
}
|
|
2365
|
+
case BdkError_Tags.SignerInvalidSighash:
|
|
2366
|
+
{
|
|
2367
|
+
ordinalConverter.write(38, into);
|
|
2368
|
+
const inner = value.inner;
|
|
2369
|
+
FfiConverterString.write(inner.message, into);
|
|
2370
|
+
return;
|
|
2371
|
+
}
|
|
2372
|
+
case BdkError_Tags.SyncFailed:
|
|
2373
|
+
{
|
|
2374
|
+
ordinalConverter.write(39, into);
|
|
2375
|
+
const inner = value.inner;
|
|
2376
|
+
FfiConverterString.write(inner.message, into);
|
|
2377
|
+
return;
|
|
2378
|
+
}
|
|
2379
|
+
case BdkError_Tags.BroadcastFailed:
|
|
2380
|
+
{
|
|
2381
|
+
ordinalConverter.write(40, into);
|
|
2382
|
+
const inner = value.inner;
|
|
2383
|
+
FfiConverterString.write(inner.message, into);
|
|
2384
|
+
return;
|
|
2385
|
+
}
|
|
2386
|
+
case BdkError_Tags.InvalidTransaction:
|
|
2387
|
+
{
|
|
2388
|
+
ordinalConverter.write(41, into);
|
|
2389
|
+
const inner = value.inner;
|
|
2390
|
+
FfiConverterString.write(inner.message, into);
|
|
2391
|
+
return;
|
|
2392
|
+
}
|
|
2393
|
+
case BdkError_Tags.TransactionNotFound:
|
|
2394
|
+
{
|
|
2395
|
+
ordinalConverter.write(42, into);
|
|
2396
|
+
const inner = value.inner;
|
|
2397
|
+
FfiConverterString.write(inner.message, into);
|
|
2398
|
+
return;
|
|
2399
|
+
}
|
|
2400
|
+
case BdkError_Tags.CannotConnect:
|
|
2401
|
+
{
|
|
2402
|
+
ordinalConverter.write(43, into);
|
|
2403
|
+
const inner = value.inner;
|
|
2404
|
+
FfiConverterString.write(inner.message, into);
|
|
2405
|
+
return;
|
|
2406
|
+
}
|
|
2407
|
+
case BdkError_Tags.CalculateFeeError:
|
|
2408
|
+
{
|
|
2409
|
+
ordinalConverter.write(44, into);
|
|
2410
|
+
const inner = value.inner;
|
|
2411
|
+
FfiConverterString.write(inner.message, into);
|
|
2412
|
+
return;
|
|
2413
|
+
}
|
|
2414
|
+
case BdkError_Tags.InvalidMnemonic:
|
|
2415
|
+
{
|
|
2416
|
+
ordinalConverter.write(45, into);
|
|
2417
|
+
const inner = value.inner;
|
|
2418
|
+
FfiConverterString.write(inner.message, into);
|
|
2419
|
+
return;
|
|
2420
|
+
}
|
|
2421
|
+
case BdkError_Tags.InvalidEntropy:
|
|
2422
|
+
{
|
|
2423
|
+
ordinalConverter.write(46, into);
|
|
2424
|
+
const inner = value.inner;
|
|
2425
|
+
FfiConverterString.write(inner.message, into);
|
|
2426
|
+
return;
|
|
2427
|
+
}
|
|
2428
|
+
case BdkError_Tags.KeyError:
|
|
2429
|
+
{
|
|
2430
|
+
ordinalConverter.write(47, into);
|
|
2431
|
+
const inner = value.inner;
|
|
2432
|
+
FfiConverterString.write(inner.message, into);
|
|
2433
|
+
return;
|
|
2434
|
+
}
|
|
2435
|
+
case BdkError_Tags.Generic:
|
|
2436
|
+
{
|
|
2437
|
+
ordinalConverter.write(48, into);
|
|
2438
|
+
const inner = value.inner;
|
|
2439
|
+
FfiConverterString.write(inner.message, into);
|
|
2440
|
+
return;
|
|
2441
|
+
}
|
|
2442
|
+
default:
|
|
2443
|
+
// Throwing from here means that BdkError_Tags hasn't matched an ordinal.
|
|
2444
|
+
throw new _uniffiBindgenReactNative.UniffiInternalError.UnexpectedEnumCase();
|
|
2445
|
+
}
|
|
2446
|
+
}
|
|
2447
|
+
allocationSize(value) {
|
|
2448
|
+
switch (value.tag) {
|
|
2449
|
+
case BdkError_Tags.InvalidDescriptor:
|
|
2450
|
+
{
|
|
2451
|
+
const inner = value.inner;
|
|
2452
|
+
let size = ordinalConverter.allocationSize(1);
|
|
2453
|
+
size += FfiConverterString.allocationSize(inner.message);
|
|
2454
|
+
return size;
|
|
2455
|
+
}
|
|
2456
|
+
case BdkError_Tags.WalletCreationFailed:
|
|
2457
|
+
{
|
|
2458
|
+
const inner = value.inner;
|
|
2459
|
+
let size = ordinalConverter.allocationSize(2);
|
|
2460
|
+
size += FfiConverterString.allocationSize(inner.message);
|
|
2461
|
+
return size;
|
|
2462
|
+
}
|
|
2463
|
+
case BdkError_Tags.WalletLoadFailed:
|
|
2464
|
+
{
|
|
2465
|
+
const inner = value.inner;
|
|
2466
|
+
let size = ordinalConverter.allocationSize(3);
|
|
2467
|
+
size += FfiConverterString.allocationSize(inner.message);
|
|
2468
|
+
return size;
|
|
2469
|
+
}
|
|
2470
|
+
case BdkError_Tags.WalletLoadMismatch:
|
|
2471
|
+
{
|
|
2472
|
+
const inner = value.inner;
|
|
2473
|
+
let size = ordinalConverter.allocationSize(4);
|
|
2474
|
+
size += FfiConverterString.allocationSize(inner.message);
|
|
2475
|
+
return size;
|
|
2476
|
+
}
|
|
2477
|
+
case BdkError_Tags.PersistError:
|
|
2478
|
+
{
|
|
2479
|
+
const inner = value.inner;
|
|
2480
|
+
let size = ordinalConverter.allocationSize(5);
|
|
2481
|
+
size += FfiConverterString.allocationSize(inner.message);
|
|
2482
|
+
return size;
|
|
2483
|
+
}
|
|
2484
|
+
case BdkError_Tags.InvalidAddress:
|
|
2485
|
+
{
|
|
2486
|
+
const inner = value.inner;
|
|
2487
|
+
let size = ordinalConverter.allocationSize(6);
|
|
2488
|
+
size += FfiConverterString.allocationSize(inner.message);
|
|
2489
|
+
return size;
|
|
2490
|
+
}
|
|
2491
|
+
case BdkError_Tags.InvalidScript:
|
|
2492
|
+
{
|
|
2493
|
+
const inner = value.inner;
|
|
2494
|
+
let size = ordinalConverter.allocationSize(7);
|
|
2495
|
+
size += FfiConverterString.allocationSize(inner.message);
|
|
2496
|
+
return size;
|
|
2497
|
+
}
|
|
2498
|
+
case BdkError_Tags.TransactionBuildFailed:
|
|
2499
|
+
{
|
|
2500
|
+
const inner = value.inner;
|
|
2501
|
+
let size = ordinalConverter.allocationSize(8);
|
|
2502
|
+
size += FfiConverterString.allocationSize(inner.message);
|
|
2503
|
+
return size;
|
|
2504
|
+
}
|
|
2505
|
+
case BdkError_Tags.NoRecipients:
|
|
2506
|
+
{
|
|
2507
|
+
const inner = value.inner;
|
|
2508
|
+
let size = ordinalConverter.allocationSize(9);
|
|
2509
|
+
size += FfiConverterString.allocationSize(inner.message);
|
|
2510
|
+
return size;
|
|
2511
|
+
}
|
|
2512
|
+
case BdkError_Tags.NoUtxosSelected:
|
|
2513
|
+
{
|
|
2514
|
+
const inner = value.inner;
|
|
2515
|
+
let size = ordinalConverter.allocationSize(10);
|
|
2516
|
+
size += FfiConverterString.allocationSize(inner.message);
|
|
2517
|
+
return size;
|
|
2518
|
+
}
|
|
2519
|
+
case BdkError_Tags.OutputBelowDustLimit:
|
|
2520
|
+
{
|
|
2521
|
+
const inner = value.inner;
|
|
2522
|
+
let size = ordinalConverter.allocationSize(11);
|
|
2523
|
+
size += FfiConverterString.allocationSize(inner.message);
|
|
2524
|
+
return size;
|
|
2525
|
+
}
|
|
2526
|
+
case BdkError_Tags.InsufficientFunds:
|
|
2527
|
+
{
|
|
2528
|
+
const inner = value.inner;
|
|
2529
|
+
let size = ordinalConverter.allocationSize(12);
|
|
2530
|
+
size += FfiConverterString.allocationSize(inner.message);
|
|
2531
|
+
return size;
|
|
2532
|
+
}
|
|
2533
|
+
case BdkError_Tags.FeeRateTooLow:
|
|
2534
|
+
{
|
|
2535
|
+
const inner = value.inner;
|
|
2536
|
+
let size = ordinalConverter.allocationSize(13);
|
|
2537
|
+
size += FfiConverterString.allocationSize(inner.message);
|
|
2538
|
+
return size;
|
|
2539
|
+
}
|
|
2540
|
+
case BdkError_Tags.FeeTooLow:
|
|
2541
|
+
{
|
|
2542
|
+
const inner = value.inner;
|
|
2543
|
+
let size = ordinalConverter.allocationSize(14);
|
|
2544
|
+
size += FfiConverterString.allocationSize(inner.message);
|
|
2545
|
+
return size;
|
|
2546
|
+
}
|
|
2547
|
+
case BdkError_Tags.LockTimeConflict:
|
|
2548
|
+
{
|
|
2549
|
+
const inner = value.inner;
|
|
2550
|
+
let size = ordinalConverter.allocationSize(15);
|
|
2551
|
+
size += FfiConverterString.allocationSize(inner.message);
|
|
2552
|
+
return size;
|
|
2553
|
+
}
|
|
2554
|
+
case BdkError_Tags.RbfSequenceConflict:
|
|
2555
|
+
{
|
|
2556
|
+
const inner = value.inner;
|
|
2557
|
+
let size = ordinalConverter.allocationSize(16);
|
|
2558
|
+
size += FfiConverterString.allocationSize(inner.message);
|
|
2559
|
+
return size;
|
|
2560
|
+
}
|
|
2561
|
+
case BdkError_Tags.VersionZero:
|
|
2562
|
+
{
|
|
2563
|
+
const inner = value.inner;
|
|
2564
|
+
let size = ordinalConverter.allocationSize(17);
|
|
2565
|
+
size += FfiConverterString.allocationSize(inner.message);
|
|
2566
|
+
return size;
|
|
2567
|
+
}
|
|
2568
|
+
case BdkError_Tags.VersionOneCsv:
|
|
2569
|
+
{
|
|
2570
|
+
const inner = value.inner;
|
|
2571
|
+
let size = ordinalConverter.allocationSize(18);
|
|
2572
|
+
size += FfiConverterString.allocationSize(inner.message);
|
|
2573
|
+
return size;
|
|
2574
|
+
}
|
|
2575
|
+
case BdkError_Tags.SpendingPolicyRequired:
|
|
2576
|
+
{
|
|
2577
|
+
const inner = value.inner;
|
|
2578
|
+
let size = ordinalConverter.allocationSize(19);
|
|
2579
|
+
size += FfiConverterString.allocationSize(inner.message);
|
|
2580
|
+
return size;
|
|
2581
|
+
}
|
|
2582
|
+
case BdkError_Tags.MissingKeyOrigin:
|
|
2583
|
+
{
|
|
2584
|
+
const inner = value.inner;
|
|
2585
|
+
let size = ordinalConverter.allocationSize(20);
|
|
2586
|
+
size += FfiConverterString.allocationSize(inner.message);
|
|
2587
|
+
return size;
|
|
2588
|
+
}
|
|
2589
|
+
case BdkError_Tags.MissingNonWitnessUtxo:
|
|
2590
|
+
{
|
|
2591
|
+
const inner = value.inner;
|
|
2592
|
+
let size = ordinalConverter.allocationSize(21);
|
|
2593
|
+
size += FfiConverterString.allocationSize(inner.message);
|
|
2594
|
+
return size;
|
|
2595
|
+
}
|
|
2596
|
+
case BdkError_Tags.OutpointNotFound:
|
|
2597
|
+
{
|
|
2598
|
+
const inner = value.inner;
|
|
2599
|
+
let size = ordinalConverter.allocationSize(22);
|
|
2600
|
+
size += FfiConverterString.allocationSize(inner.message);
|
|
2601
|
+
return size;
|
|
2602
|
+
}
|
|
2603
|
+
case BdkError_Tags.FeeBumpTargetNotFound:
|
|
2604
|
+
{
|
|
2605
|
+
const inner = value.inner;
|
|
2606
|
+
let size = ordinalConverter.allocationSize(23);
|
|
2607
|
+
size += FfiConverterString.allocationSize(inner.message);
|
|
2608
|
+
return size;
|
|
2609
|
+
}
|
|
2610
|
+
case BdkError_Tags.FeeBumpAlreadyConfirmed:
|
|
2611
|
+
{
|
|
2612
|
+
const inner = value.inner;
|
|
2613
|
+
let size = ordinalConverter.allocationSize(24);
|
|
2614
|
+
size += FfiConverterString.allocationSize(inner.message);
|
|
2615
|
+
return size;
|
|
2616
|
+
}
|
|
2617
|
+
case BdkError_Tags.FeeBumpIrreplaceable:
|
|
2618
|
+
{
|
|
2619
|
+
const inner = value.inner;
|
|
2620
|
+
let size = ordinalConverter.allocationSize(25);
|
|
2621
|
+
size += FfiConverterString.allocationSize(inner.message);
|
|
2622
|
+
return size;
|
|
2623
|
+
}
|
|
2624
|
+
case BdkError_Tags.FeeBumpFeeRateUnavailable:
|
|
2625
|
+
{
|
|
2626
|
+
const inner = value.inner;
|
|
2627
|
+
let size = ordinalConverter.allocationSize(26);
|
|
2628
|
+
size += FfiConverterString.allocationSize(inner.message);
|
|
2629
|
+
return size;
|
|
2630
|
+
}
|
|
2631
|
+
case BdkError_Tags.FeeBumpInvalidOutputIndex:
|
|
2632
|
+
{
|
|
2633
|
+
const inner = value.inner;
|
|
2634
|
+
let size = ordinalConverter.allocationSize(27);
|
|
2635
|
+
size += FfiConverterString.allocationSize(inner.message);
|
|
2636
|
+
return size;
|
|
2637
|
+
}
|
|
2638
|
+
case BdkError_Tags.InvalidPsbt:
|
|
2639
|
+
{
|
|
2640
|
+
const inner = value.inner;
|
|
2641
|
+
let size = ordinalConverter.allocationSize(28);
|
|
2642
|
+
size += FfiConverterString.allocationSize(inner.message);
|
|
2643
|
+
return size;
|
|
2644
|
+
}
|
|
2645
|
+
case BdkError_Tags.SignFailed:
|
|
2646
|
+
{
|
|
2647
|
+
const inner = value.inner;
|
|
2648
|
+
let size = ordinalConverter.allocationSize(29);
|
|
2649
|
+
size += FfiConverterString.allocationSize(inner.message);
|
|
2650
|
+
return size;
|
|
2651
|
+
}
|
|
2652
|
+
case BdkError_Tags.SignerMissingKey:
|
|
2653
|
+
{
|
|
2654
|
+
const inner = value.inner;
|
|
2655
|
+
let size = ordinalConverter.allocationSize(30);
|
|
2656
|
+
size += FfiConverterString.allocationSize(inner.message);
|
|
2657
|
+
return size;
|
|
2658
|
+
}
|
|
2659
|
+
case BdkError_Tags.SignerInvalidKey:
|
|
2660
|
+
{
|
|
2661
|
+
const inner = value.inner;
|
|
2662
|
+
let size = ordinalConverter.allocationSize(31);
|
|
2663
|
+
size += FfiConverterString.allocationSize(inner.message);
|
|
2664
|
+
return size;
|
|
2665
|
+
}
|
|
2666
|
+
case BdkError_Tags.SignerUserCanceled:
|
|
2667
|
+
{
|
|
2668
|
+
const inner = value.inner;
|
|
2669
|
+
let size = ordinalConverter.allocationSize(32);
|
|
2670
|
+
size += FfiConverterString.allocationSize(inner.message);
|
|
2671
|
+
return size;
|
|
2672
|
+
}
|
|
2673
|
+
case BdkError_Tags.SignerInputIndexOutOfRange:
|
|
2674
|
+
{
|
|
2675
|
+
const inner = value.inner;
|
|
2676
|
+
let size = ordinalConverter.allocationSize(33);
|
|
2677
|
+
size += FfiConverterString.allocationSize(inner.message);
|
|
2678
|
+
return size;
|
|
2679
|
+
}
|
|
2680
|
+
case BdkError_Tags.SignerMissingNonWitnessUtxo:
|
|
2681
|
+
{
|
|
2682
|
+
const inner = value.inner;
|
|
2683
|
+
let size = ordinalConverter.allocationSize(34);
|
|
2684
|
+
size += FfiConverterString.allocationSize(inner.message);
|
|
2685
|
+
return size;
|
|
2686
|
+
}
|
|
2687
|
+
case BdkError_Tags.SignerMissingWitnessUtxo:
|
|
2688
|
+
{
|
|
2689
|
+
const inner = value.inner;
|
|
2690
|
+
let size = ordinalConverter.allocationSize(35);
|
|
2691
|
+
size += FfiConverterString.allocationSize(inner.message);
|
|
2692
|
+
return size;
|
|
2693
|
+
}
|
|
2694
|
+
case BdkError_Tags.SignerMissingWitnessScript:
|
|
2695
|
+
{
|
|
2696
|
+
const inner = value.inner;
|
|
2697
|
+
let size = ordinalConverter.allocationSize(36);
|
|
2698
|
+
size += FfiConverterString.allocationSize(inner.message);
|
|
2699
|
+
return size;
|
|
2700
|
+
}
|
|
2701
|
+
case BdkError_Tags.SignerNonStandardSighash:
|
|
2702
|
+
{
|
|
2703
|
+
const inner = value.inner;
|
|
2704
|
+
let size = ordinalConverter.allocationSize(37);
|
|
2705
|
+
size += FfiConverterString.allocationSize(inner.message);
|
|
2706
|
+
return size;
|
|
2707
|
+
}
|
|
2708
|
+
case BdkError_Tags.SignerInvalidSighash:
|
|
2709
|
+
{
|
|
2710
|
+
const inner = value.inner;
|
|
2711
|
+
let size = ordinalConverter.allocationSize(38);
|
|
2712
|
+
size += FfiConverterString.allocationSize(inner.message);
|
|
2713
|
+
return size;
|
|
2714
|
+
}
|
|
2715
|
+
case BdkError_Tags.SyncFailed:
|
|
2716
|
+
{
|
|
2717
|
+
const inner = value.inner;
|
|
2718
|
+
let size = ordinalConverter.allocationSize(39);
|
|
2719
|
+
size += FfiConverterString.allocationSize(inner.message);
|
|
2720
|
+
return size;
|
|
2721
|
+
}
|
|
2722
|
+
case BdkError_Tags.BroadcastFailed:
|
|
2723
|
+
{
|
|
2724
|
+
const inner = value.inner;
|
|
2725
|
+
let size = ordinalConverter.allocationSize(40);
|
|
2726
|
+
size += FfiConverterString.allocationSize(inner.message);
|
|
2727
|
+
return size;
|
|
2728
|
+
}
|
|
2729
|
+
case BdkError_Tags.InvalidTransaction:
|
|
2730
|
+
{
|
|
2731
|
+
const inner = value.inner;
|
|
2732
|
+
let size = ordinalConverter.allocationSize(41);
|
|
2733
|
+
size += FfiConverterString.allocationSize(inner.message);
|
|
2734
|
+
return size;
|
|
2735
|
+
}
|
|
2736
|
+
case BdkError_Tags.TransactionNotFound:
|
|
2737
|
+
{
|
|
2738
|
+
const inner = value.inner;
|
|
2739
|
+
let size = ordinalConverter.allocationSize(42);
|
|
2740
|
+
size += FfiConverterString.allocationSize(inner.message);
|
|
2741
|
+
return size;
|
|
2742
|
+
}
|
|
2743
|
+
case BdkError_Tags.CannotConnect:
|
|
2744
|
+
{
|
|
2745
|
+
const inner = value.inner;
|
|
2746
|
+
let size = ordinalConverter.allocationSize(43);
|
|
2747
|
+
size += FfiConverterString.allocationSize(inner.message);
|
|
2748
|
+
return size;
|
|
2749
|
+
}
|
|
2750
|
+
case BdkError_Tags.CalculateFeeError:
|
|
2751
|
+
{
|
|
2752
|
+
const inner = value.inner;
|
|
2753
|
+
let size = ordinalConverter.allocationSize(44);
|
|
2754
|
+
size += FfiConverterString.allocationSize(inner.message);
|
|
2755
|
+
return size;
|
|
2756
|
+
}
|
|
2757
|
+
case BdkError_Tags.InvalidMnemonic:
|
|
2758
|
+
{
|
|
2759
|
+
const inner = value.inner;
|
|
2760
|
+
let size = ordinalConverter.allocationSize(45);
|
|
2761
|
+
size += FfiConverterString.allocationSize(inner.message);
|
|
2762
|
+
return size;
|
|
2763
|
+
}
|
|
2764
|
+
case BdkError_Tags.InvalidEntropy:
|
|
2765
|
+
{
|
|
2766
|
+
const inner = value.inner;
|
|
2767
|
+
let size = ordinalConverter.allocationSize(46);
|
|
2768
|
+
size += FfiConverterString.allocationSize(inner.message);
|
|
2769
|
+
return size;
|
|
2770
|
+
}
|
|
2771
|
+
case BdkError_Tags.KeyError:
|
|
2772
|
+
{
|
|
2773
|
+
const inner = value.inner;
|
|
2774
|
+
let size = ordinalConverter.allocationSize(47);
|
|
2775
|
+
size += FfiConverterString.allocationSize(inner.message);
|
|
2776
|
+
return size;
|
|
2777
|
+
}
|
|
2778
|
+
case BdkError_Tags.Generic:
|
|
2779
|
+
{
|
|
2780
|
+
const inner = value.inner;
|
|
2781
|
+
let size = ordinalConverter.allocationSize(48);
|
|
2782
|
+
size += FfiConverterString.allocationSize(inner.message);
|
|
2783
|
+
return size;
|
|
2784
|
+
}
|
|
1710
2785
|
default:
|
|
1711
2786
|
throw new _uniffiBindgenReactNative.UniffiInternalError.UnexpectedEnumCase();
|
|
1712
2787
|
}
|
|
1713
2788
|
}
|
|
1714
|
-
write(value, into) {
|
|
1715
|
-
const obj = value;
|
|
1716
|
-
const index = obj[_uniffiBindgenReactNative.variantOrdinalSymbol];
|
|
1717
|
-
intConverter.write(index, into);
|
|
1718
|
-
}
|
|
1719
|
-
allocationSize(value) {
|
|
1720
|
-
return intConverter.allocationSize(0);
|
|
1721
|
-
}
|
|
1722
2789
|
}
|
|
1723
|
-
return new
|
|
2790
|
+
return new FFIConverter();
|
|
1724
2791
|
})();
|
|
1725
|
-
|
|
1726
|
-
/**
|
|
1727
|
-
* Controls which UTXOs the wallet may spend as change inputs.
|
|
1728
|
-
*/
|
|
1729
2792
|
let ChangeSpendPolicy = exports.ChangeSpendPolicy = /*#__PURE__*/function (ChangeSpendPolicy) {
|
|
1730
|
-
/**
|
|
1731
|
-
* Both change and non-change outputs may be spent (default).
|
|
1732
|
-
*/
|
|
1733
2793
|
ChangeSpendPolicy[ChangeSpendPolicy["ChangeAllowed"] = 0] = "ChangeAllowed";
|
|
1734
|
-
/**
|
|
1735
|
-
* Only change outputs may be spent as inputs.
|
|
1736
|
-
*/
|
|
1737
2794
|
ChangeSpendPolicy[ChangeSpendPolicy["OnlyChange"] = 1] = "OnlyChange";
|
|
1738
|
-
/**
|
|
1739
|
-
* Only non-change outputs may be spent as inputs.
|
|
1740
|
-
*/
|
|
1741
2795
|
ChangeSpendPolicy[ChangeSpendPolicy["ChangeForbidden"] = 2] = "ChangeForbidden";
|
|
1742
2796
|
return ChangeSpendPolicy;
|
|
1743
2797
|
}({});
|
|
@@ -1772,28 +2826,10 @@ const FfiConverterTypeChangeSpendPolicy = (() => {
|
|
|
1772
2826
|
}
|
|
1773
2827
|
return new FFIConverter();
|
|
1774
2828
|
})();
|
|
1775
|
-
|
|
1776
|
-
/**
|
|
1777
|
-
* Standard BIP descriptor templates for generating wallet descriptors
|
|
1778
|
-
* from a mnemonic/xprv (also usable for xpub via create_public_descriptor).
|
|
1779
|
-
* Mirrors descriptor::template::{Bip44, Bip49, Bip84, Bip86}.
|
|
1780
|
-
*/
|
|
1781
2829
|
let DescriptorTemplate = exports.DescriptorTemplate = /*#__PURE__*/function (DescriptorTemplate) {
|
|
1782
|
-
/**
|
|
1783
|
-
* BIP44 — Legacy P2PKH (1…)
|
|
1784
|
-
*/
|
|
1785
2830
|
DescriptorTemplate[DescriptorTemplate["Bip44"] = 0] = "Bip44";
|
|
1786
|
-
/**
|
|
1787
|
-
* BIP49 — Nested SegWit P2SH-P2WPKH (3…)
|
|
1788
|
-
*/
|
|
1789
2831
|
DescriptorTemplate[DescriptorTemplate["Bip49"] = 1] = "Bip49";
|
|
1790
|
-
/**
|
|
1791
|
-
* BIP84 — Native SegWit P2WPKH (bc1q…)
|
|
1792
|
-
*/
|
|
1793
2832
|
DescriptorTemplate[DescriptorTemplate["Bip84"] = 2] = "Bip84";
|
|
1794
|
-
/**
|
|
1795
|
-
* BIP86 — Taproot P2TR (bc1p…)
|
|
1796
|
-
*/
|
|
1797
2833
|
DescriptorTemplate[DescriptorTemplate["Bip86"] = 3] = "Bip86";
|
|
1798
2834
|
return DescriptorTemplate;
|
|
1799
2835
|
}({});
|
|
@@ -1833,13 +2869,7 @@ const FfiConverterTypeDescriptorTemplate = (() => {
|
|
|
1833
2869
|
return new FFIConverter();
|
|
1834
2870
|
})();
|
|
1835
2871
|
let KeychainKind = exports.KeychainKind = /*#__PURE__*/function (KeychainKind) {
|
|
1836
|
-
/**
|
|
1837
|
-
* External keychain — used for deriving recipient addresses.
|
|
1838
|
-
*/
|
|
1839
2872
|
KeychainKind[KeychainKind["External"] = 0] = "External";
|
|
1840
|
-
/**
|
|
1841
|
-
* Internal keychain — used for deriving change addresses.
|
|
1842
|
-
*/
|
|
1843
2873
|
KeychainKind[KeychainKind["Internal"] = 1] = "Internal";
|
|
1844
2874
|
return KeychainKind;
|
|
1845
2875
|
}({});
|
|
@@ -1870,11 +2900,6 @@ const FfiConverterTypeKeychainKind = (() => {
|
|
|
1870
2900
|
}
|
|
1871
2901
|
return new FFIConverter();
|
|
1872
2902
|
})();
|
|
1873
|
-
|
|
1874
|
-
/**
|
|
1875
|
-
* BIP-39 mnemonic language. Mirrors bip39::Language.
|
|
1876
|
-
* Requires `all-languages` feature on the bip39 crate.
|
|
1877
|
-
*/
|
|
1878
2903
|
let Language = exports.Language = /*#__PURE__*/function (Language) {
|
|
1879
2904
|
Language[Language["English"] = 0] = "English";
|
|
1880
2905
|
Language[Language["SimplifiedChinese"] = 1] = "SimplifiedChinese";
|
|
@@ -1989,27 +3014,10 @@ const FfiConverterTypeNetwork = (() => {
|
|
|
1989
3014
|
}
|
|
1990
3015
|
return new FFIConverter();
|
|
1991
3016
|
})();
|
|
1992
|
-
|
|
1993
|
-
/**
|
|
1994
|
-
* Single-key descriptor templates.
|
|
1995
|
-
* Mirrors descriptor::template::{P2Pkh, P2Wpkh, P2Wpkh_P2Sh, P2TR}.
|
|
1996
|
-
*/
|
|
1997
3017
|
let SingleKeyDescriptorTemplate = exports.SingleKeyDescriptorTemplate = /*#__PURE__*/function (SingleKeyDescriptorTemplate) {
|
|
1998
|
-
/**
|
|
1999
|
-
* Pay-to-PubKey-Hash — Legacy (1…)
|
|
2000
|
-
*/
|
|
2001
3018
|
SingleKeyDescriptorTemplate[SingleKeyDescriptorTemplate["P2Pkh"] = 0] = "P2Pkh";
|
|
2002
|
-
/**
|
|
2003
|
-
* Pay-to-Witness-PubKey-Hash — Native SegWit (bc1q…)
|
|
2004
|
-
*/
|
|
2005
3019
|
SingleKeyDescriptorTemplate[SingleKeyDescriptorTemplate["P2Wpkh"] = 1] = "P2Wpkh";
|
|
2006
|
-
/**
|
|
2007
|
-
* P2Wpkh wrapped in P2SH — Nested SegWit (3…)
|
|
2008
|
-
*/
|
|
2009
3020
|
SingleKeyDescriptorTemplate[SingleKeyDescriptorTemplate["P2WpkhP2Sh"] = 2] = "P2WpkhP2Sh";
|
|
2010
|
-
/**
|
|
2011
|
-
* Pay-to-Taproot (bc1p…)
|
|
2012
|
-
*/
|
|
2013
3021
|
SingleKeyDescriptorTemplate[SingleKeyDescriptorTemplate["P2tr"] = 3] = "P2tr";
|
|
2014
3022
|
return SingleKeyDescriptorTemplate;
|
|
2015
3023
|
}({});
|
|
@@ -2048,19 +3056,8 @@ const FfiConverterTypeSingleKeyDescriptorTemplate = (() => {
|
|
|
2048
3056
|
}
|
|
2049
3057
|
return new FFIConverter();
|
|
2050
3058
|
})();
|
|
2051
|
-
|
|
2052
|
-
/**
|
|
2053
|
-
* Ordering applied to inputs and outputs when building a transaction.
|
|
2054
|
-
* Note: bdk_wallet also has a Custom variant (with closures) that cannot cross FFI.
|
|
2055
|
-
*/
|
|
2056
3059
|
let TxOrdering = exports.TxOrdering = /*#__PURE__*/function (TxOrdering) {
|
|
2057
|
-
/**
|
|
2058
|
-
* Randomise input and output order (default, good for privacy).
|
|
2059
|
-
*/
|
|
2060
3060
|
TxOrdering[TxOrdering["Shuffle"] = 0] = "Shuffle";
|
|
2061
|
-
/**
|
|
2062
|
-
* Preserve insertion order of recipients and manually added UTXOs.
|
|
2063
|
-
*/
|
|
2064
3061
|
TxOrdering[TxOrdering["Untouched"] = 1] = "Untouched";
|
|
2065
3062
|
return TxOrdering;
|
|
2066
3063
|
}({});
|
|
@@ -2101,14 +3098,7 @@ let WalletEvent_Tags = exports.WalletEvent_Tags = /*#__PURE__*/function (WalletE
|
|
|
2101
3098
|
WalletEvent_Tags["TxDropped"] = "TxDropped";
|
|
2102
3099
|
return WalletEvent_Tags;
|
|
2103
3100
|
}({});
|
|
2104
|
-
/**
|
|
2105
|
-
* Events emitted when applying chain updates to the wallet.
|
|
2106
|
-
* Mirrors bdk_wallet::event::WalletEvent (non-exhaustive in upstream).
|
|
2107
|
-
*/
|
|
2108
3101
|
const WalletEvent = exports.WalletEvent = (() => {
|
|
2109
|
-
/**
|
|
2110
|
-
* The local chain tip has changed.
|
|
2111
|
-
*/
|
|
2112
3102
|
class ChainTipChanged_ extends _uniffiBindgenReactNative.UniffiEnum {
|
|
2113
3103
|
/**
|
|
2114
3104
|
* @private
|
|
@@ -2127,9 +3117,6 @@ const WalletEvent = exports.WalletEvent = (() => {
|
|
|
2127
3117
|
return obj.tag === WalletEvent_Tags.ChainTipChanged;
|
|
2128
3118
|
}
|
|
2129
3119
|
}
|
|
2130
|
-
/**
|
|
2131
|
-
* A transaction has been confirmed.
|
|
2132
|
-
*/
|
|
2133
3120
|
class TxConfirmed_ extends _uniffiBindgenReactNative.UniffiEnum {
|
|
2134
3121
|
/**
|
|
2135
3122
|
* @private
|
|
@@ -2148,9 +3135,6 @@ const WalletEvent = exports.WalletEvent = (() => {
|
|
|
2148
3135
|
return obj.tag === WalletEvent_Tags.TxConfirmed;
|
|
2149
3136
|
}
|
|
2150
3137
|
}
|
|
2151
|
-
/**
|
|
2152
|
-
* A previously confirmed transaction has been unconfirmed (reorg).
|
|
2153
|
-
*/
|
|
2154
3138
|
class TxUnconfirmed_ extends _uniffiBindgenReactNative.UniffiEnum {
|
|
2155
3139
|
/**
|
|
2156
3140
|
* @private
|
|
@@ -2169,9 +3153,6 @@ const WalletEvent = exports.WalletEvent = (() => {
|
|
|
2169
3153
|
return obj.tag === WalletEvent_Tags.TxUnconfirmed;
|
|
2170
3154
|
}
|
|
2171
3155
|
}
|
|
2172
|
-
/**
|
|
2173
|
-
* A transaction has been replaced (RBF or conflict).
|
|
2174
|
-
*/
|
|
2175
3156
|
class TxReplaced_ extends _uniffiBindgenReactNative.UniffiEnum {
|
|
2176
3157
|
/**
|
|
2177
3158
|
* @private
|
|
@@ -2190,9 +3171,6 @@ const WalletEvent = exports.WalletEvent = (() => {
|
|
|
2190
3171
|
return obj.tag === WalletEvent_Tags.TxReplaced;
|
|
2191
3172
|
}
|
|
2192
3173
|
}
|
|
2193
|
-
/**
|
|
2194
|
-
* A transaction has been dropped from the mempool / evicted.
|
|
2195
|
-
*/
|
|
2196
3174
|
class TxDropped_ extends _uniffiBindgenReactNative.UniffiEnum {
|
|
2197
3175
|
/**
|
|
2198
3176
|
* @private
|
|
@@ -2223,12 +3201,6 @@ const WalletEvent = exports.WalletEvent = (() => {
|
|
|
2223
3201
|
TxDropped: TxDropped_
|
|
2224
3202
|
});
|
|
2225
3203
|
})();
|
|
2226
|
-
|
|
2227
|
-
/**
|
|
2228
|
-
* Events emitted when applying chain updates to the wallet.
|
|
2229
|
-
* Mirrors bdk_wallet::event::WalletEvent (non-exhaustive in upstream).
|
|
2230
|
-
*/
|
|
2231
|
-
|
|
2232
3204
|
// FfiConverter for enum WalletEvent
|
|
2233
3205
|
const FfiConverterTypeWalletEvent = (() => {
|
|
2234
3206
|
const ordinalConverter = _uniffiBindgenReactNative.FfiConverterInt32;
|
|
@@ -2354,10 +3326,6 @@ const FfiConverterTypeWalletEvent = (() => {
|
|
|
2354
3326
|
}
|
|
2355
3327
|
return new FFIConverter();
|
|
2356
3328
|
})();
|
|
2357
|
-
|
|
2358
|
-
/**
|
|
2359
|
-
* BIP-39 mnemonic word count (determines entropy length).
|
|
2360
|
-
*/
|
|
2361
3329
|
let WordCount = exports.WordCount = /*#__PURE__*/function (WordCount) {
|
|
2362
3330
|
WordCount[WordCount["Words12"] = 0] = "Words12";
|
|
2363
3331
|
WordCount[WordCount["Words15"] = 1] = "Words15";
|
|
@@ -2407,107 +3375,137 @@ const FfiConverterTypeWordCount = (() => {
|
|
|
2407
3375
|
})();
|
|
2408
3376
|
|
|
2409
3377
|
/**
|
|
2410
|
-
*
|
|
2411
|
-
* Backed by bdk_wallet::keys::bip39::Mnemonic (requires `keys-bip39` feature).
|
|
3378
|
+
* A reusable Electrum client that holds a persistent TCP/TLS connection.
|
|
2412
3379
|
*/
|
|
2413
3380
|
|
|
2414
3381
|
/**
|
|
2415
|
-
* @deprecated Use `
|
|
3382
|
+
* @deprecated Use `ElectrumClientLike` instead.
|
|
2416
3383
|
*/
|
|
2417
3384
|
|
|
2418
3385
|
/**
|
|
2419
|
-
*
|
|
2420
|
-
* Backed by bdk_wallet::keys::bip39::Mnemonic (requires `keys-bip39` feature).
|
|
3386
|
+
* A reusable Electrum client that holds a persistent TCP/TLS connection.
|
|
2421
3387
|
*/
|
|
2422
|
-
class
|
|
2423
|
-
[_uniffiBindgenReactNative.uniffiTypeNameSymbol] = "
|
|
3388
|
+
class ElectrumClient extends _uniffiBindgenReactNative.UniffiAbstractObject {
|
|
3389
|
+
[_uniffiBindgenReactNative.uniffiTypeNameSymbol] = "ElectrumClient";
|
|
2424
3390
|
/**
|
|
2425
|
-
*
|
|
3391
|
+
* Connect to an Electrum server.
|
|
2426
3392
|
*/
|
|
2427
|
-
constructor(
|
|
3393
|
+
constructor(url) /*throws*/{
|
|
2428
3394
|
super();
|
|
2429
3395
|
const pointer = uniffiCaller.rustCallWithError(/*liftError:*/FfiConverterTypeBdkError.lift.bind(FfiConverterTypeBdkError), /*caller:*/callStatus => {
|
|
2430
|
-
return (0, _bdk_ffiFfi.default)().
|
|
3396
|
+
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_constructor_electrumclient_new(FfiConverterString.lower(url), callStatus);
|
|
2431
3397
|
}, /*liftString:*/FfiConverterString.lift);
|
|
2432
3398
|
this[_uniffiBindgenReactNative.pointerLiteralSymbol] = pointer;
|
|
2433
|
-
this[_uniffiBindgenReactNative.destructorGuardSymbol] =
|
|
3399
|
+
this[_uniffiBindgenReactNative.destructorGuardSymbol] = uniffiTypeElectrumClientObjectFactory.bless(pointer);
|
|
2434
3400
|
}
|
|
2435
3401
|
|
|
2436
3402
|
/**
|
|
2437
|
-
*
|
|
3403
|
+
* {@inheritDoc uniffi-bindgen-react-native#UniffiAbstractObject.uniffiDestroy}
|
|
2438
3404
|
*/
|
|
3405
|
+
uniffiDestroy() {
|
|
3406
|
+
const ptr = this[_uniffiBindgenReactNative.destructorGuardSymbol];
|
|
3407
|
+
if (ptr !== undefined) {
|
|
3408
|
+
const pointer = uniffiTypeElectrumClientObjectFactory.pointer(this);
|
|
3409
|
+
uniffiTypeElectrumClientObjectFactory.freePointer(pointer);
|
|
3410
|
+
uniffiTypeElectrumClientObjectFactory.unbless(ptr);
|
|
3411
|
+
delete this[_uniffiBindgenReactNative.destructorGuardSymbol];
|
|
3412
|
+
}
|
|
3413
|
+
}
|
|
3414
|
+
static instanceOf(obj) {
|
|
3415
|
+
return uniffiTypeElectrumClientObjectFactory.isConcreteType(obj);
|
|
3416
|
+
}
|
|
3417
|
+
}
|
|
3418
|
+
exports.ElectrumClient = ElectrumClient;
|
|
3419
|
+
const uniffiTypeElectrumClientObjectFactory = (() => {
|
|
3420
|
+
return {
|
|
3421
|
+
create(pointer) {
|
|
3422
|
+
const instance = Object.create(ElectrumClient.prototype);
|
|
3423
|
+
instance[_uniffiBindgenReactNative.pointerLiteralSymbol] = pointer;
|
|
3424
|
+
instance[_uniffiBindgenReactNative.destructorGuardSymbol] = this.bless(pointer);
|
|
3425
|
+
instance[_uniffiBindgenReactNative.uniffiTypeNameSymbol] = "ElectrumClient";
|
|
3426
|
+
return instance;
|
|
3427
|
+
},
|
|
3428
|
+
bless(p) {
|
|
3429
|
+
return uniffiCaller.rustCall(/*caller:*/status => (0, _bdk_ffiFfi.default)().ubrn_uniffi_internal_fn_method_electrumclient_ffi__bless_pointer(p, status), /*liftString:*/FfiConverterString.lift);
|
|
3430
|
+
},
|
|
3431
|
+
unbless(ptr) {
|
|
3432
|
+
ptr.markDestroyed();
|
|
3433
|
+
},
|
|
3434
|
+
pointer(obj) {
|
|
3435
|
+
if (obj[_uniffiBindgenReactNative.destructorGuardSymbol] === undefined) {
|
|
3436
|
+
throw new _uniffiBindgenReactNative.UniffiInternalError.UnexpectedNullPointer();
|
|
3437
|
+
}
|
|
3438
|
+
return obj[_uniffiBindgenReactNative.pointerLiteralSymbol];
|
|
3439
|
+
},
|
|
3440
|
+
clonePointer(obj) {
|
|
3441
|
+
const pointer = this.pointer(obj);
|
|
3442
|
+
return uniffiCaller.rustCall(/*caller:*/callStatus => (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_clone_electrumclient(pointer, callStatus), /*liftString:*/FfiConverterString.lift);
|
|
3443
|
+
},
|
|
3444
|
+
freePointer(pointer) {
|
|
3445
|
+
uniffiCaller.rustCall(/*caller:*/callStatus => (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_free_electrumclient(pointer, callStatus), /*liftString:*/FfiConverterString.lift);
|
|
3446
|
+
},
|
|
3447
|
+
isConcreteType(obj) {
|
|
3448
|
+
return obj[_uniffiBindgenReactNative.destructorGuardSymbol] && obj[_uniffiBindgenReactNative.uniffiTypeNameSymbol] === "ElectrumClient";
|
|
3449
|
+
}
|
|
3450
|
+
};
|
|
3451
|
+
})();
|
|
3452
|
+
// FfiConverter for ElectrumClientLike
|
|
3453
|
+
const FfiConverterTypeElectrumClient = new _uniffiBindgenReactNative.FfiConverterObject(uniffiTypeElectrumClientObjectFactory);
|
|
3454
|
+
|
|
3455
|
+
/**
|
|
3456
|
+
* @deprecated Use `MnemonicLike` instead.
|
|
3457
|
+
*/
|
|
3458
|
+
|
|
3459
|
+
class Mnemonic extends _uniffiBindgenReactNative.UniffiAbstractObject {
|
|
3460
|
+
[_uniffiBindgenReactNative.uniffiTypeNameSymbol] = "Mnemonic";
|
|
3461
|
+
constructor(wordCount) /*throws*/{
|
|
3462
|
+
super();
|
|
3463
|
+
const pointer = uniffiCaller.rustCallWithError(/*liftError:*/FfiConverterTypeBdkError.lift.bind(FfiConverterTypeBdkError), /*caller:*/callStatus => {
|
|
3464
|
+
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_constructor_mnemonic_new(FfiConverterTypeWordCount.lower(wordCount), callStatus);
|
|
3465
|
+
}, /*liftString:*/FfiConverterString.lift);
|
|
3466
|
+
this[_uniffiBindgenReactNative.pointerLiteralSymbol] = pointer;
|
|
3467
|
+
this[_uniffiBindgenReactNative.destructorGuardSymbol] = uniffiTypeMnemonicObjectFactory.bless(pointer);
|
|
3468
|
+
}
|
|
2439
3469
|
static fromEntropy(entropy) /*throws*/{
|
|
2440
3470
|
return FfiConverterTypeMnemonic.lift(uniffiCaller.rustCallWithError(/*liftError:*/FfiConverterTypeBdkError.lift.bind(FfiConverterTypeBdkError), /*caller:*/callStatus => {
|
|
2441
3471
|
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_constructor_mnemonic_from_entropy(FfiConverterArrayUInt8.lower(entropy), callStatus);
|
|
2442
3472
|
}, /*liftString:*/FfiConverterString.lift));
|
|
2443
3473
|
}
|
|
2444
|
-
|
|
2445
|
-
/**
|
|
2446
|
-
* Create a mnemonic from raw entropy bytes in a specific language.
|
|
2447
|
-
*/
|
|
2448
3474
|
static fromEntropyIn(entropy, language) /*throws*/{
|
|
2449
3475
|
return FfiConverterTypeMnemonic.lift(uniffiCaller.rustCallWithError(/*liftError:*/FfiConverterTypeBdkError.lift.bind(FfiConverterTypeBdkError), /*caller:*/callStatus => {
|
|
2450
3476
|
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_constructor_mnemonic_from_entropy_in(FfiConverterArrayUInt8.lower(entropy), FfiConverterTypeLanguage.lower(language), callStatus);
|
|
2451
3477
|
}, /*liftString:*/FfiConverterString.lift));
|
|
2452
3478
|
}
|
|
2453
|
-
|
|
2454
|
-
/**
|
|
2455
|
-
* Parse an existing mnemonic string (auto-detects language).
|
|
2456
|
-
*/
|
|
2457
3479
|
static fromString(mnemonic) /*throws*/{
|
|
2458
3480
|
return FfiConverterTypeMnemonic.lift(uniffiCaller.rustCallWithError(/*liftError:*/FfiConverterTypeBdkError.lift.bind(FfiConverterTypeBdkError), /*caller:*/callStatus => {
|
|
2459
3481
|
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_constructor_mnemonic_from_string(FfiConverterString.lower(mnemonic), callStatus);
|
|
2460
3482
|
}, /*liftString:*/FfiConverterString.lift));
|
|
2461
3483
|
}
|
|
2462
|
-
|
|
2463
|
-
/**
|
|
2464
|
-
* Parse a mnemonic string in a specific language.
|
|
2465
|
-
*/
|
|
2466
3484
|
static fromStringIn(mnemonic, language) /*throws*/{
|
|
2467
3485
|
return FfiConverterTypeMnemonic.lift(uniffiCaller.rustCallWithError(/*liftError:*/FfiConverterTypeBdkError.lift.bind(FfiConverterTypeBdkError), /*caller:*/callStatus => {
|
|
2468
3486
|
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_constructor_mnemonic_from_string_in(FfiConverterString.lower(mnemonic), FfiConverterTypeLanguage.lower(language), callStatus);
|
|
2469
3487
|
}, /*liftString:*/FfiConverterString.lift));
|
|
2470
3488
|
}
|
|
2471
|
-
|
|
2472
|
-
/**
|
|
2473
|
-
* The language of this mnemonic.
|
|
2474
|
-
*/
|
|
2475
3489
|
language() {
|
|
2476
3490
|
return FfiConverterTypeLanguage.lift(uniffiCaller.rustCall(/*caller:*/callStatus => {
|
|
2477
3491
|
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_mnemonic_language(uniffiTypeMnemonicObjectFactory.clonePointer(this), callStatus);
|
|
2478
3492
|
}, /*liftString:*/FfiConverterString.lift));
|
|
2479
3493
|
}
|
|
2480
|
-
|
|
2481
|
-
/**
|
|
2482
|
-
* Derive the 64-byte seed as hex. Pass an empty string for no passphrase.
|
|
2483
|
-
*/
|
|
2484
3494
|
toSeedHex(passphrase) {
|
|
2485
3495
|
return FfiConverterString.lift(uniffiCaller.rustCall(/*caller:*/callStatus => {
|
|
2486
3496
|
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_mnemonic_to_seed_hex(uniffiTypeMnemonicObjectFactory.clonePointer(this), FfiConverterString.lower(passphrase), callStatus);
|
|
2487
3497
|
}, /*liftString:*/FfiConverterString.lift));
|
|
2488
3498
|
}
|
|
2489
|
-
|
|
2490
|
-
/**
|
|
2491
|
-
* The mnemonic as a space-separated word string.
|
|
2492
|
-
*/
|
|
2493
3499
|
toString() {
|
|
2494
3500
|
return FfiConverterString.lift(uniffiCaller.rustCall(/*caller:*/callStatus => {
|
|
2495
3501
|
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_mnemonic_to_string(uniffiTypeMnemonicObjectFactory.clonePointer(this), callStatus);
|
|
2496
3502
|
}, /*liftString:*/FfiConverterString.lift));
|
|
2497
3503
|
}
|
|
2498
|
-
|
|
2499
|
-
/**
|
|
2500
|
-
* Number of words (12, 15, 18, 21, or 24).
|
|
2501
|
-
*/
|
|
2502
3504
|
wordCount() {
|
|
2503
3505
|
return _uniffiBindgenReactNative.FfiConverterUInt32.lift(uniffiCaller.rustCall(/*caller:*/callStatus => {
|
|
2504
3506
|
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_mnemonic_word_count(uniffiTypeMnemonicObjectFactory.clonePointer(this), callStatus);
|
|
2505
3507
|
}, /*liftString:*/FfiConverterString.lift));
|
|
2506
3508
|
}
|
|
2507
|
-
|
|
2508
|
-
/**
|
|
2509
|
-
* List the individual words.
|
|
2510
|
-
*/
|
|
2511
3509
|
words() {
|
|
2512
3510
|
return FfiConverterArrayString.lift(uniffiCaller.rustCall(/*caller:*/callStatus => {
|
|
2513
3511
|
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_mnemonic_words(uniffiTypeMnemonicObjectFactory.clonePointer(this), callStatus);
|
|
@@ -2567,24 +3565,12 @@ const uniffiTypeMnemonicObjectFactory = (() => {
|
|
|
2567
3565
|
// FfiConverter for MnemonicLike
|
|
2568
3566
|
const FfiConverterTypeMnemonic = new _uniffiBindgenReactNative.FfiConverterObject(uniffiTypeMnemonicObjectFactory);
|
|
2569
3567
|
|
|
2570
|
-
/**
|
|
2571
|
-
* A Partially Signed Bitcoin Transaction (BIP-174 / BIP-370).
|
|
2572
|
-
* Mirrors bitcoin::Psbt with added PsbtUtils trait methods.
|
|
2573
|
-
*/
|
|
2574
|
-
|
|
2575
3568
|
/**
|
|
2576
3569
|
* @deprecated Use `PsbtLike` instead.
|
|
2577
3570
|
*/
|
|
2578
3571
|
|
|
2579
|
-
/**
|
|
2580
|
-
* A Partially Signed Bitcoin Transaction (BIP-174 / BIP-370).
|
|
2581
|
-
* Mirrors bitcoin::Psbt with added PsbtUtils trait methods.
|
|
2582
|
-
*/
|
|
2583
3572
|
class Psbt extends _uniffiBindgenReactNative.UniffiAbstractObject {
|
|
2584
3573
|
[_uniffiBindgenReactNative.uniffiTypeNameSymbol] = "Psbt";
|
|
2585
|
-
/**
|
|
2586
|
-
* Deserialize from a base64-encoded string.
|
|
2587
|
-
*/
|
|
2588
3574
|
constructor(psbtBase64) /*throws*/{
|
|
2589
3575
|
super();
|
|
2590
3576
|
const pointer = uniffiCaller.rustCallWithError(/*liftError:*/FfiConverterTypeBdkError.lift.bind(FfiConverterTypeBdkError), /*caller:*/callStatus => {
|
|
@@ -2593,59 +3579,31 @@ class Psbt extends _uniffiBindgenReactNative.UniffiAbstractObject {
|
|
|
2593
3579
|
this[_uniffiBindgenReactNative.pointerLiteralSymbol] = pointer;
|
|
2594
3580
|
this[_uniffiBindgenReactNative.destructorGuardSymbol] = uniffiTypePsbtObjectFactory.bless(pointer);
|
|
2595
3581
|
}
|
|
2596
|
-
|
|
2597
|
-
/**
|
|
2598
|
-
* Extract the fully-signed transaction as raw hex.
|
|
2599
|
-
* Only valid after all inputs are finalized.
|
|
2600
|
-
*/
|
|
2601
3582
|
extractTxHex() /*throws*/{
|
|
2602
3583
|
return FfiConverterString.lift(uniffiCaller.rustCallWithError(/*liftError:*/FfiConverterTypeBdkError.lift.bind(FfiConverterTypeBdkError), /*caller:*/callStatus => {
|
|
2603
3584
|
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_psbt_extract_tx_hex(uniffiTypePsbtObjectFactory.clonePointer(this), callStatus);
|
|
2604
3585
|
}, /*liftString:*/FfiConverterString.lift));
|
|
2605
3586
|
}
|
|
2606
|
-
|
|
2607
|
-
/**
|
|
2608
|
-
* Total fee in satoshis. None if any input UTXO value is unknown.
|
|
2609
|
-
* From PsbtUtils::fee_amount().
|
|
2610
|
-
*/
|
|
2611
3587
|
feeAmount() {
|
|
2612
3588
|
return FfiConverterOptionalUInt64.lift(uniffiCaller.rustCall(/*caller:*/callStatus => {
|
|
2613
3589
|
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_psbt_fee_amount(uniffiTypePsbtObjectFactory.clonePointer(this), callStatus);
|
|
2614
3590
|
}, /*liftString:*/FfiConverterString.lift));
|
|
2615
3591
|
}
|
|
2616
|
-
|
|
2617
|
-
/**
|
|
2618
|
-
* Fee rate in sat/vbyte. None if any input UTXO value is unknown.
|
|
2619
|
-
* From PsbtUtils::fee_rate().
|
|
2620
|
-
*/
|
|
2621
3592
|
feeRate() {
|
|
2622
3593
|
return FfiConverterOptionalFloat64.lift(uniffiCaller.rustCall(/*caller:*/callStatus => {
|
|
2623
3594
|
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_psbt_fee_rate(uniffiTypePsbtObjectFactory.clonePointer(this), callStatus);
|
|
2624
3595
|
}, /*liftString:*/FfiConverterString.lift));
|
|
2625
3596
|
}
|
|
2626
|
-
|
|
2627
|
-
/**
|
|
2628
|
-
* Retrieve the UTXO for a given input index. Returns None if unavailable.
|
|
2629
|
-
* From PsbtUtils::get_utxo_for().
|
|
2630
|
-
*/
|
|
2631
3597
|
getUtxoFor(inputIndex) {
|
|
2632
3598
|
return FfiConverterOptionalTypeTxOut.lift(uniffiCaller.rustCall(/*caller:*/callStatus => {
|
|
2633
3599
|
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_psbt_get_utxo_for(uniffiTypePsbtObjectFactory.clonePointer(this), _uniffiBindgenReactNative.FfiConverterUInt64.lower(inputIndex), callStatus);
|
|
2634
3600
|
}, /*liftString:*/FfiConverterString.lift));
|
|
2635
3601
|
}
|
|
2636
|
-
|
|
2637
|
-
/**
|
|
2638
|
-
* Serialize to a base64-encoded string.
|
|
2639
|
-
*/
|
|
2640
3602
|
toBase64() {
|
|
2641
3603
|
return FfiConverterString.lift(uniffiCaller.rustCall(/*caller:*/callStatus => {
|
|
2642
3604
|
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_psbt_to_base64(uniffiTypePsbtObjectFactory.clonePointer(this), callStatus);
|
|
2643
3605
|
}, /*liftString:*/FfiConverterString.lift));
|
|
2644
3606
|
}
|
|
2645
|
-
|
|
2646
|
-
/**
|
|
2647
|
-
* The unsigned txid (available before finalization).
|
|
2648
|
-
*/
|
|
2649
3607
|
txid() /*throws*/{
|
|
2650
3608
|
return FfiConverterString.lift(uniffiCaller.rustCallWithError(/*liftError:*/FfiConverterTypeBdkError.lift.bind(FfiConverterTypeBdkError), /*caller:*/callStatus => {
|
|
2651
3609
|
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_psbt_txid(uniffiTypePsbtObjectFactory.clonePointer(this), callStatus);
|
|
@@ -2705,21 +3663,10 @@ const uniffiTypePsbtObjectFactory = (() => {
|
|
|
2705
3663
|
// FfiConverter for PsbtLike
|
|
2706
3664
|
const FfiConverterTypePsbt = new _uniffiBindgenReactNative.FfiConverterObject(uniffiTypePsbtObjectFactory);
|
|
2707
3665
|
|
|
2708
|
-
/**
|
|
2709
|
-
* Fluent builder for constructing Bitcoin transactions.
|
|
2710
|
-
* Create one, configure it, then call finish(wallet) to produce a PSBT.
|
|
2711
|
-
* Mirrors bdk_wallet::TxBuilder (without lifetime / generic coin selection).
|
|
2712
|
-
*/
|
|
2713
|
-
|
|
2714
3666
|
/**
|
|
2715
3667
|
* @deprecated Use `TxBuilderLike` instead.
|
|
2716
3668
|
*/
|
|
2717
3669
|
|
|
2718
|
-
/**
|
|
2719
|
-
* Fluent builder for constructing Bitcoin transactions.
|
|
2720
|
-
* Create one, configure it, then call finish(wallet) to produce a PSBT.
|
|
2721
|
-
* Mirrors bdk_wallet::TxBuilder (without lifetime / generic coin selection).
|
|
2722
|
-
*/
|
|
2723
3670
|
class TxBuilder extends _uniffiBindgenReactNative.UniffiAbstractObject {
|
|
2724
3671
|
[_uniffiBindgenReactNative.uniffiTypeNameSymbol] = "TxBuilder";
|
|
2725
3672
|
constructor() {
|
|
@@ -2729,164 +3676,92 @@ class TxBuilder extends _uniffiBindgenReactNative.UniffiAbstractObject {
|
|
|
2729
3676
|
}, /*liftString:*/FfiConverterString.lift);
|
|
2730
3677
|
this[_uniffiBindgenReactNative.pointerLiteralSymbol] = pointer;
|
|
2731
3678
|
this[_uniffiBindgenReactNative.destructorGuardSymbol] = uniffiTypeTxBuilderObjectFactory.bless(pointer);
|
|
2732
|
-
}
|
|
2733
|
-
|
|
2734
|
-
/**
|
|
2735
|
-
* Attach OP_RETURN data to the transaction.
|
|
2736
|
-
*/
|
|
3679
|
+
}
|
|
2737
3680
|
addData(data) {
|
|
2738
3681
|
uniffiCaller.rustCall(/*caller:*/callStatus => {
|
|
2739
3682
|
(0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_txbuilder_add_data(uniffiTypeTxBuilderObjectFactory.clonePointer(this), FfiConverterArrayUInt8.lower(data), callStatus);
|
|
2740
3683
|
}, /*liftString:*/FfiConverterString.lift);
|
|
2741
3684
|
}
|
|
2742
|
-
|
|
2743
|
-
/**
|
|
2744
|
-
* Include BIP-32 global xpubs in the PSBT.
|
|
2745
|
-
*/
|
|
2746
3685
|
addGlobalXpubs() {
|
|
2747
3686
|
uniffiCaller.rustCall(/*caller:*/callStatus => {
|
|
2748
3687
|
(0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_txbuilder_add_global_xpubs(uniffiTypeTxBuilderObjectFactory.clonePointer(this), callStatus);
|
|
2749
3688
|
}, /*liftString:*/FfiConverterString.lift);
|
|
2750
3689
|
}
|
|
2751
|
-
|
|
2752
|
-
/**
|
|
2753
|
-
* Add a single recipient (address + amount).
|
|
2754
|
-
*/
|
|
2755
3690
|
addRecipient(address, amountSats) {
|
|
2756
3691
|
uniffiCaller.rustCall(/*caller:*/callStatus => {
|
|
2757
3692
|
(0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_txbuilder_add_recipient(uniffiTypeTxBuilderObjectFactory.clonePointer(this), FfiConverterString.lower(address), _uniffiBindgenReactNative.FfiConverterUInt64.lower(amountSats), callStatus);
|
|
2758
3693
|
}, /*liftString:*/FfiConverterString.lift);
|
|
2759
3694
|
}
|
|
2760
|
-
|
|
2761
|
-
/**
|
|
2762
|
-
* Mark a single UTXO as unspendable.
|
|
2763
|
-
*/
|
|
2764
3695
|
addUnspendable(outpoint) {
|
|
2765
3696
|
uniffiCaller.rustCall(/*caller:*/callStatus => {
|
|
2766
3697
|
(0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_txbuilder_add_unspendable(uniffiTypeTxBuilderObjectFactory.clonePointer(this), FfiConverterTypeOutPoint.lower(outpoint), callStatus);
|
|
2767
3698
|
}, /*liftString:*/FfiConverterString.lift);
|
|
2768
3699
|
}
|
|
2769
|
-
|
|
2770
|
-
/**
|
|
2771
|
-
* Add a specific UTXO to spend.
|
|
2772
|
-
*/
|
|
2773
3700
|
addUtxo(outpoint) /*throws*/{
|
|
2774
3701
|
uniffiCaller.rustCallWithError(/*liftError:*/FfiConverterTypeBdkError.lift.bind(FfiConverterTypeBdkError), /*caller:*/callStatus => {
|
|
2775
3702
|
(0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_txbuilder_add_utxo(uniffiTypeTxBuilderObjectFactory.clonePointer(this), FfiConverterTypeOutPoint.lower(outpoint), callStatus);
|
|
2776
3703
|
}, /*liftString:*/FfiConverterString.lift);
|
|
2777
3704
|
}
|
|
2778
|
-
|
|
2779
|
-
/**
|
|
2780
|
-
* Add multiple specific UTXOs to spend.
|
|
2781
|
-
*/
|
|
2782
3705
|
addUtxos(outpoints) /*throws*/{
|
|
2783
3706
|
uniffiCaller.rustCallWithError(/*liftError:*/FfiConverterTypeBdkError.lift.bind(FfiConverterTypeBdkError), /*caller:*/callStatus => {
|
|
2784
3707
|
(0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_txbuilder_add_utxos(uniffiTypeTxBuilderObjectFactory.clonePointer(this), FfiConverterArrayTypeOutPoint.lower(outpoints), callStatus);
|
|
2785
3708
|
}, /*liftString:*/FfiConverterString.lift);
|
|
2786
3709
|
}
|
|
2787
|
-
|
|
2788
|
-
/**
|
|
2789
|
-
* Allow outputs below the dust threshold.
|
|
2790
|
-
*/
|
|
2791
3710
|
allowDust(allow) {
|
|
2792
3711
|
uniffiCaller.rustCall(/*caller:*/callStatus => {
|
|
2793
3712
|
(0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_txbuilder_allow_dust(uniffiTypeTxBuilderObjectFactory.clonePointer(this), _uniffiBindgenReactNative.FfiConverterBool.lower(allow), callStatus);
|
|
2794
3713
|
}, /*liftString:*/FfiConverterString.lift);
|
|
2795
3714
|
}
|
|
2796
|
-
|
|
2797
|
-
/**
|
|
2798
|
-
* Set the change spend policy explicitly.
|
|
2799
|
-
*/
|
|
2800
3715
|
changePolicy(policy) {
|
|
2801
3716
|
uniffiCaller.rustCall(/*caller:*/callStatus => {
|
|
2802
3717
|
(0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_txbuilder_change_policy(uniffiTypeTxBuilderObjectFactory.clonePointer(this), FfiConverterTypeChangeSpendPolicy.lower(policy), callStatus);
|
|
2803
3718
|
}, /*liftString:*/FfiConverterString.lift);
|
|
2804
3719
|
}
|
|
2805
|
-
|
|
2806
|
-
/**
|
|
2807
|
-
* Set the assumed current block height (for relative timelock evaluation).
|
|
2808
|
-
*/
|
|
2809
3720
|
currentHeight(height) {
|
|
2810
3721
|
uniffiCaller.rustCall(/*caller:*/callStatus => {
|
|
2811
3722
|
(0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_txbuilder_current_height(uniffiTypeTxBuilderObjectFactory.clonePointer(this), _uniffiBindgenReactNative.FfiConverterUInt32.lower(height), callStatus);
|
|
2812
3723
|
}, /*liftString:*/FfiConverterString.lift);
|
|
2813
3724
|
}
|
|
2814
|
-
|
|
2815
|
-
/**
|
|
2816
|
-
* Forbid spending from change outputs.
|
|
2817
|
-
*/
|
|
2818
3725
|
doNotSpendChange() {
|
|
2819
3726
|
uniffiCaller.rustCall(/*caller:*/callStatus => {
|
|
2820
3727
|
(0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_txbuilder_do_not_spend_change(uniffiTypeTxBuilderObjectFactory.clonePointer(this), callStatus);
|
|
2821
3728
|
}, /*liftString:*/FfiConverterString.lift);
|
|
2822
3729
|
}
|
|
2823
|
-
|
|
2824
|
-
/**
|
|
2825
|
-
* Set the script to receive the remaining change (use with drain_wallet).
|
|
2826
|
-
*/
|
|
2827
3730
|
drainTo(address) /*throws*/{
|
|
2828
3731
|
uniffiCaller.rustCallWithError(/*liftError:*/FfiConverterTypeBdkError.lift.bind(FfiConverterTypeBdkError), /*caller:*/callStatus => {
|
|
2829
3732
|
(0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_txbuilder_drain_to(uniffiTypeTxBuilderObjectFactory.clonePointer(this), FfiConverterString.lower(address), callStatus);
|
|
2830
3733
|
}, /*liftString:*/FfiConverterString.lift);
|
|
2831
3734
|
}
|
|
2832
|
-
|
|
2833
|
-
/**
|
|
2834
|
-
* Spend all spendable UTXOs (send remaining to the drain_to address).
|
|
2835
|
-
*/
|
|
2836
3735
|
drainWallet() {
|
|
2837
3736
|
uniffiCaller.rustCall(/*caller:*/callStatus => {
|
|
2838
3737
|
(0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_txbuilder_drain_wallet(uniffiTypeTxBuilderObjectFactory.clonePointer(this), callStatus);
|
|
2839
3738
|
}, /*liftString:*/FfiConverterString.lift);
|
|
2840
3739
|
}
|
|
2841
|
-
|
|
2842
|
-
/**
|
|
2843
|
-
* Enable RBF signalling with the default nSequence (0xFFFFFFFD).
|
|
2844
|
-
*/
|
|
2845
3740
|
enableRbf() {
|
|
2846
3741
|
uniffiCaller.rustCall(/*caller:*/callStatus => {
|
|
2847
3742
|
(0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_txbuilder_enable_rbf(uniffiTypeTxBuilderObjectFactory.clonePointer(this), callStatus);
|
|
2848
3743
|
}, /*liftString:*/FfiConverterString.lift);
|
|
2849
3744
|
}
|
|
2850
|
-
|
|
2851
|
-
/**
|
|
2852
|
-
* Enable RBF signalling with a specific nSequence value (must be < 0xFFFFFFFE).
|
|
2853
|
-
*/
|
|
2854
3745
|
enableRbfWithSequence(nsequence) {
|
|
2855
3746
|
uniffiCaller.rustCall(/*caller:*/callStatus => {
|
|
2856
3747
|
(0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_txbuilder_enable_rbf_with_sequence(uniffiTypeTxBuilderObjectFactory.clonePointer(this), _uniffiBindgenReactNative.FfiConverterUInt32.lower(nsequence), callStatus);
|
|
2857
3748
|
}, /*liftString:*/FfiConverterString.lift);
|
|
2858
3749
|
}
|
|
2859
|
-
|
|
2860
|
-
/**
|
|
2861
|
-
* Exclude UTXOs with fewer than min_confirms confirmations.
|
|
2862
|
-
*/
|
|
2863
3750
|
excludeBelowConfirmations(minConfirms) {
|
|
2864
3751
|
uniffiCaller.rustCall(/*caller:*/callStatus => {
|
|
2865
3752
|
(0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_txbuilder_exclude_below_confirmations(uniffiTypeTxBuilderObjectFactory.clonePointer(this), _uniffiBindgenReactNative.FfiConverterUInt32.lower(minConfirms), callStatus);
|
|
2866
3753
|
}, /*liftString:*/FfiConverterString.lift);
|
|
2867
3754
|
}
|
|
2868
|
-
|
|
2869
|
-
/**
|
|
2870
|
-
* Exclude all unconfirmed UTXOs.
|
|
2871
|
-
*/
|
|
2872
3755
|
excludeUnconfirmed() {
|
|
2873
3756
|
uniffiCaller.rustCall(/*caller:*/callStatus => {
|
|
2874
3757
|
(0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_txbuilder_exclude_unconfirmed(uniffiTypeTxBuilderObjectFactory.clonePointer(this), callStatus);
|
|
2875
3758
|
}, /*liftString:*/FfiConverterString.lift);
|
|
2876
3759
|
}
|
|
2877
|
-
|
|
2878
|
-
/**
|
|
2879
|
-
* Set an absolute fee in satoshis (overrides fee_rate).
|
|
2880
|
-
*/
|
|
2881
3760
|
feeAbsolute(feeSats) {
|
|
2882
3761
|
uniffiCaller.rustCall(/*caller:*/callStatus => {
|
|
2883
3762
|
(0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_txbuilder_fee_absolute(uniffiTypeTxBuilderObjectFactory.clonePointer(this), _uniffiBindgenReactNative.FfiConverterUInt64.lower(feeSats), callStatus);
|
|
2884
3763
|
}, /*liftString:*/FfiConverterString.lift);
|
|
2885
3764
|
}
|
|
2886
|
-
|
|
2887
|
-
/**
|
|
2888
|
-
* Set a fee rate target in sat/vbyte.
|
|
2889
|
-
*/
|
|
2890
3765
|
feeRate(satPerVbyte) {
|
|
2891
3766
|
uniffiCaller.rustCall(/*caller:*/callStatus => {
|
|
2892
3767
|
(0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_txbuilder_fee_rate(uniffiTypeTxBuilderObjectFactory.clonePointer(this), _uniffiBindgenReactNative.FfiConverterFloat64.lower(satPerVbyte), callStatus);
|
|
@@ -2894,118 +3769,76 @@ class TxBuilder extends _uniffiBindgenReactNative.UniffiAbstractObject {
|
|
|
2894
3769
|
}
|
|
2895
3770
|
|
|
2896
3771
|
/**
|
|
2897
|
-
* Build the transaction into a PSBT
|
|
2898
|
-
* selection and script resolution — the PSBT is NOT signed here.
|
|
3772
|
+
* Build the transaction into a PSBT (async — runs on background thread).
|
|
2899
3773
|
*/
|
|
2900
|
-
finish(wallet) /*throws*/{
|
|
2901
|
-
|
|
2902
|
-
|
|
2903
|
-
|
|
3774
|
+
async finish(wallet, asyncOpts_) /*throws*/{
|
|
3775
|
+
const __stack = uniffiIsDebug ? new Error().stack : undefined;
|
|
3776
|
+
try {
|
|
3777
|
+
return await (0, _uniffiBindgenReactNative.uniffiRustCallAsync)(/*rustCaller:*/uniffiCaller, /*rustFutureFunc:*/() => {
|
|
3778
|
+
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_txbuilder_finish(uniffiTypeTxBuilderObjectFactory.clonePointer(this), FfiConverterTypeWallet.lower(wallet));
|
|
3779
|
+
}, /*pollFunc:*/(0, _bdk_ffiFfi.default)().ubrn_ffi_bdk_ffi_rust_future_poll_u64, /*cancelFunc:*/(0, _bdk_ffiFfi.default)().ubrn_ffi_bdk_ffi_rust_future_cancel_u64, /*completeFunc:*/(0, _bdk_ffiFfi.default)().ubrn_ffi_bdk_ffi_rust_future_complete_u64, /*freeFunc:*/(0, _bdk_ffiFfi.default)().ubrn_ffi_bdk_ffi_rust_future_free_u64, /*liftFunc:*/FfiConverterTypePsbt.lift.bind(FfiConverterTypePsbt), /*liftString:*/FfiConverterString.lift, /*asyncOpts:*/asyncOpts_, /*errorHandler:*/FfiConverterTypeBdkError.lift.bind(FfiConverterTypeBdkError));
|
|
3780
|
+
} catch (__error) {
|
|
3781
|
+
if (uniffiIsDebug && __error instanceof Error) {
|
|
3782
|
+
__error.stack = __stack;
|
|
3783
|
+
}
|
|
3784
|
+
throw __error;
|
|
3785
|
+
}
|
|
2904
3786
|
}
|
|
2905
|
-
|
|
2906
|
-
/**
|
|
2907
|
-
* Include the redeemScript / witnessScript in PSBT outputs.
|
|
2908
|
-
*/
|
|
2909
3787
|
includeOutputRedeemWitnessScript() {
|
|
2910
3788
|
uniffiCaller.rustCall(/*caller:*/callStatus => {
|
|
2911
3789
|
(0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_txbuilder_include_output_redeem_witness_script(uniffiTypeTxBuilderObjectFactory.clonePointer(this), callStatus);
|
|
2912
3790
|
}, /*liftString:*/FfiConverterString.lift);
|
|
2913
3791
|
}
|
|
2914
|
-
|
|
2915
|
-
/**
|
|
2916
|
-
* Only use the UTXOs explicitly added with add_utxo / add_utxos.
|
|
2917
|
-
*/
|
|
2918
3792
|
manuallySelectedOnly() {
|
|
2919
3793
|
uniffiCaller.rustCall(/*caller:*/callStatus => {
|
|
2920
3794
|
(0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_txbuilder_manually_selected_only(uniffiTypeTxBuilderObjectFactory.clonePointer(this), callStatus);
|
|
2921
3795
|
}, /*liftString:*/FfiConverterString.lift);
|
|
2922
3796
|
}
|
|
2923
|
-
|
|
2924
|
-
/**
|
|
2925
|
-
* Set an explicit nLockTime (as a block height).
|
|
2926
|
-
*/
|
|
2927
3797
|
nlocktime(lockHeight) {
|
|
2928
3798
|
uniffiCaller.rustCall(/*caller:*/callStatus => {
|
|
2929
3799
|
(0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_txbuilder_nlocktime(uniffiTypeTxBuilderObjectFactory.clonePointer(this), _uniffiBindgenReactNative.FfiConverterUInt32.lower(lockHeight), callStatus);
|
|
2930
3800
|
}, /*liftString:*/FfiConverterString.lift);
|
|
2931
3801
|
}
|
|
2932
|
-
|
|
2933
|
-
/**
|
|
2934
|
-
* Only spend from change outputs.
|
|
2935
|
-
*/
|
|
2936
3802
|
onlySpendChange() {
|
|
2937
3803
|
uniffiCaller.rustCall(/*caller:*/callStatus => {
|
|
2938
3804
|
(0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_txbuilder_only_spend_change(uniffiTypeTxBuilderObjectFactory.clonePointer(this), callStatus);
|
|
2939
3805
|
}, /*liftString:*/FfiConverterString.lift);
|
|
2940
3806
|
}
|
|
2941
|
-
|
|
2942
|
-
/**
|
|
2943
|
-
* Include only witness UTXO in PSBT inputs (reduced size, less validation).
|
|
2944
|
-
*/
|
|
2945
3807
|
onlyWitnessUtxo() {
|
|
2946
3808
|
uniffiCaller.rustCall(/*caller:*/callStatus => {
|
|
2947
3809
|
(0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_txbuilder_only_witness_utxo(uniffiTypeTxBuilderObjectFactory.clonePointer(this), callStatus);
|
|
2948
3810
|
}, /*liftString:*/FfiConverterString.lift);
|
|
2949
3811
|
}
|
|
2950
|
-
|
|
2951
|
-
/**
|
|
2952
|
-
* Set the input/output ordering strategy.
|
|
2953
|
-
*/
|
|
2954
3812
|
ordering(ordering) {
|
|
2955
3813
|
uniffiCaller.rustCall(/*caller:*/callStatus => {
|
|
2956
3814
|
(0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_txbuilder_ordering(uniffiTypeTxBuilderObjectFactory.clonePointer(this), FfiConverterTypeTxOrdering.lower(ordering), callStatus);
|
|
2957
3815
|
}, /*liftString:*/FfiConverterString.lift);
|
|
2958
3816
|
}
|
|
2959
|
-
|
|
2960
|
-
/**
|
|
2961
|
-
* Supply a policy path for complex descriptors (multisig, timelocks).
|
|
2962
|
-
* path_map is a JSON-encoded BTreeMap<String, Vec<usize>>.
|
|
2963
|
-
*/
|
|
2964
3817
|
policyPath(pathMapJson, keychain) {
|
|
2965
3818
|
uniffiCaller.rustCall(/*caller:*/callStatus => {
|
|
2966
3819
|
(0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_txbuilder_policy_path(uniffiTypeTxBuilderObjectFactory.clonePointer(this), FfiConverterString.lower(pathMapJson), FfiConverterTypeKeychainKind.lower(keychain), callStatus);
|
|
2967
3820
|
}, /*liftString:*/FfiConverterString.lift);
|
|
2968
3821
|
}
|
|
2969
|
-
|
|
2970
|
-
/**
|
|
2971
|
-
* Set an exact nSequence value for all inputs.
|
|
2972
|
-
*/
|
|
2973
3822
|
setExactSequence(nsequence) {
|
|
2974
3823
|
uniffiCaller.rustCall(/*caller:*/callStatus => {
|
|
2975
3824
|
(0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_txbuilder_set_exact_sequence(uniffiTypeTxBuilderObjectFactory.clonePointer(this), _uniffiBindgenReactNative.FfiConverterUInt32.lower(nsequence), callStatus);
|
|
2976
3825
|
}, /*liftString:*/FfiConverterString.lift);
|
|
2977
3826
|
}
|
|
2978
|
-
|
|
2979
|
-
/**
|
|
2980
|
-
* Replace the entire recipient list.
|
|
2981
|
-
*/
|
|
2982
3827
|
setRecipients(recipients) {
|
|
2983
3828
|
uniffiCaller.rustCall(/*caller:*/callStatus => {
|
|
2984
3829
|
(0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_txbuilder_set_recipients(uniffiTypeTxBuilderObjectFactory.clonePointer(this), FfiConverterArrayTypeRecipient.lower(recipients), callStatus);
|
|
2985
3830
|
}, /*liftString:*/FfiConverterString.lift);
|
|
2986
3831
|
}
|
|
2987
|
-
|
|
2988
|
-
/**
|
|
2989
|
-
* Set the sighash type for all inputs.
|
|
2990
|
-
*/
|
|
2991
3832
|
sighash(sighashType) {
|
|
2992
3833
|
uniffiCaller.rustCall(/*caller:*/callStatus => {
|
|
2993
3834
|
(0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_txbuilder_sighash(uniffiTypeTxBuilderObjectFactory.clonePointer(this), _uniffiBindgenReactNative.FfiConverterUInt32.lower(sighashType), callStatus);
|
|
2994
3835
|
}, /*liftString:*/FfiConverterString.lift);
|
|
2995
3836
|
}
|
|
2996
|
-
|
|
2997
|
-
/**
|
|
2998
|
-
* Set the transaction version (1 or 2).
|
|
2999
|
-
*/
|
|
3000
3837
|
txVersion(version) {
|
|
3001
3838
|
uniffiCaller.rustCall(/*caller:*/callStatus => {
|
|
3002
3839
|
(0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_txbuilder_tx_version(uniffiTypeTxBuilderObjectFactory.clonePointer(this), _uniffiBindgenReactNative.FfiConverterInt32.lower(version), callStatus);
|
|
3003
3840
|
}, /*liftString:*/FfiConverterString.lift);
|
|
3004
3841
|
}
|
|
3005
|
-
|
|
3006
|
-
/**
|
|
3007
|
-
* Mark UTXOs as unspendable (excluded from coin selection).
|
|
3008
|
-
*/
|
|
3009
3842
|
unspendable(outpoints) {
|
|
3010
3843
|
uniffiCaller.rustCall(/*caller:*/callStatus => {
|
|
3011
3844
|
(0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_txbuilder_unspendable(uniffiTypeTxBuilderObjectFactory.clonePointer(this), FfiConverterArrayTypeOutPoint.lower(outpoints), callStatus);
|
|
@@ -3072,27 +3905,21 @@ const FfiConverterTypeTxBuilder = new _uniffiBindgenReactNative.FfiConverterObje
|
|
|
3072
3905
|
class Wallet extends _uniffiBindgenReactNative.UniffiAbstractObject {
|
|
3073
3906
|
[_uniffiBindgenReactNative.uniffiTypeNameSymbol] = "Wallet";
|
|
3074
3907
|
/**
|
|
3075
|
-
* Create or load a persisted wallet.
|
|
3076
|
-
* descriptor / change_descriptor: output descriptor strings (e.g. "wpkh(tprv…/84'/1'/0'/0/*)")
|
|
3077
|
-
* db_path: file path for the SQLite persistence database.
|
|
3908
|
+
* Create or load a persisted wallet (sync — for async use create_wallet()).
|
|
3078
3909
|
*/
|
|
3079
3910
|
constructor(descriptor, changeDescriptor, network, dbPath) /*throws*/{
|
|
3080
3911
|
super();
|
|
3081
3912
|
const pointer = uniffiCaller.rustCallWithError(/*liftError:*/FfiConverterTypeBdkError.lift.bind(FfiConverterTypeBdkError), /*caller:*/callStatus => {
|
|
3082
|
-
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_constructor_wallet_new(FfiConverterString.lower(descriptor),
|
|
3913
|
+
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_constructor_wallet_new(FfiConverterString.lower(descriptor), FfiConverterOptionalString.lower(changeDescriptor), FfiConverterTypeNetwork.lower(network), FfiConverterString.lower(dbPath), callStatus);
|
|
3083
3914
|
}, /*liftString:*/FfiConverterString.lift);
|
|
3084
3915
|
this[_uniffiBindgenReactNative.pointerLiteralSymbol] = pointer;
|
|
3085
3916
|
this[_uniffiBindgenReactNative.destructorGuardSymbol] = uniffiTypeWalletObjectFactory.bless(pointer);
|
|
3086
3917
|
}
|
|
3087
|
-
|
|
3088
|
-
/**
|
|
3089
|
-
* Broadcast a finalized PSBT via Electrum. Returns the txid.
|
|
3090
|
-
*/
|
|
3091
|
-
async broadcastWithElectrum(url, psbt, asyncOpts_) /*throws*/{
|
|
3918
|
+
async broadcastWithElectrum(client, psbt, asyncOpts_) /*throws*/{
|
|
3092
3919
|
const __stack = uniffiIsDebug ? new Error().stack : undefined;
|
|
3093
3920
|
try {
|
|
3094
3921
|
return await (0, _uniffiBindgenReactNative.uniffiRustCallAsync)(/*rustCaller:*/uniffiCaller, /*rustFutureFunc:*/() => {
|
|
3095
|
-
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_wallet_broadcast_with_electrum(uniffiTypeWalletObjectFactory.clonePointer(this),
|
|
3922
|
+
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_wallet_broadcast_with_electrum(uniffiTypeWalletObjectFactory.clonePointer(this), FfiConverterTypeElectrumClient.lower(client), FfiConverterTypePsbt.lower(psbt));
|
|
3096
3923
|
}, /*pollFunc:*/(0, _bdk_ffiFfi.default)().ubrn_ffi_bdk_ffi_rust_future_poll_rust_buffer, /*cancelFunc:*/(0, _bdk_ffiFfi.default)().ubrn_ffi_bdk_ffi_rust_future_cancel_rust_buffer, /*completeFunc:*/(0, _bdk_ffiFfi.default)().ubrn_ffi_bdk_ffi_rust_future_complete_rust_buffer, /*freeFunc:*/(0, _bdk_ffiFfi.default)().ubrn_ffi_bdk_ffi_rust_future_free_rust_buffer, /*liftFunc:*/FfiConverterString.lift.bind(FfiConverterString), /*liftString:*/FfiConverterString.lift, /*asyncOpts:*/asyncOpts_, /*errorHandler:*/FfiConverterTypeBdkError.lift.bind(FfiConverterTypeBdkError));
|
|
3097
3924
|
} catch (__error) {
|
|
3098
3925
|
if (uniffiIsDebug && __error instanceof Error) {
|
|
@@ -3101,10 +3928,6 @@ class Wallet extends _uniffiBindgenReactNative.UniffiAbstractObject {
|
|
|
3101
3928
|
throw __error;
|
|
3102
3929
|
}
|
|
3103
3930
|
}
|
|
3104
|
-
|
|
3105
|
-
/**
|
|
3106
|
-
* Broadcast a finalized PSBT via Esplora. Returns the txid.
|
|
3107
|
-
*/
|
|
3108
3931
|
async broadcastWithEsplora(url, psbt, asyncOpts_) /*throws*/{
|
|
3109
3932
|
const __stack = uniffiIsDebug ? new Error().stack : undefined;
|
|
3110
3933
|
try {
|
|
@@ -3118,91 +3941,46 @@ class Wallet extends _uniffiBindgenReactNative.UniffiAbstractObject {
|
|
|
3118
3941
|
throw __error;
|
|
3119
3942
|
}
|
|
3120
3943
|
}
|
|
3121
|
-
|
|
3122
|
-
/**
|
|
3123
|
-
* Build an RBF fee-bump PSBT for an unconfirmed transaction.
|
|
3124
|
-
* Mirrors Wallet::build_fee_bump().
|
|
3125
|
-
*/
|
|
3126
3944
|
buildFeeBump(txid, newFeeRate) /*throws*/{
|
|
3127
3945
|
return FfiConverterTypePsbt.lift(uniffiCaller.rustCallWithError(/*liftError:*/FfiConverterTypeBdkError.lift.bind(FfiConverterTypeBdkError), /*caller:*/callStatus => {
|
|
3128
3946
|
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_wallet_build_fee_bump(uniffiTypeWalletObjectFactory.clonePointer(this), FfiConverterString.lower(txid), _uniffiBindgenReactNative.FfiConverterFloat64.lower(newFeeRate), callStatus);
|
|
3129
3947
|
}, /*liftString:*/FfiConverterString.lift));
|
|
3130
3948
|
}
|
|
3131
|
-
|
|
3132
|
-
/**
|
|
3133
|
-
* Calculate the fee paid by a raw transaction (hex). Returns satoshis.
|
|
3134
|
-
* Mirrors Wallet::calculate_fee().
|
|
3135
|
-
*/
|
|
3136
3949
|
calculateFee(txHex) /*throws*/{
|
|
3137
3950
|
return _uniffiBindgenReactNative.FfiConverterUInt64.lift(uniffiCaller.rustCallWithError(/*liftError:*/FfiConverterTypeBdkError.lift.bind(FfiConverterTypeBdkError), /*caller:*/callStatus => {
|
|
3138
3951
|
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_wallet_calculate_fee(uniffiTypeWalletObjectFactory.clonePointer(this), FfiConverterString.lower(txHex), callStatus);
|
|
3139
3952
|
}, /*liftString:*/FfiConverterString.lift));
|
|
3140
3953
|
}
|
|
3141
|
-
|
|
3142
|
-
/**
|
|
3143
|
-
* Calculate the fee rate for a raw transaction (hex). Returns sat/vbyte.
|
|
3144
|
-
* Mirrors Wallet::calculate_fee_rate().
|
|
3145
|
-
*/
|
|
3146
3954
|
calculateFeeRate(txHex) /*throws*/{
|
|
3147
3955
|
return _uniffiBindgenReactNative.FfiConverterFloat64.lift(uniffiCaller.rustCallWithError(/*liftError:*/FfiConverterTypeBdkError.lift.bind(FfiConverterTypeBdkError), /*caller:*/callStatus => {
|
|
3148
3956
|
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_wallet_calculate_fee_rate(uniffiTypeWalletObjectFactory.clonePointer(this), FfiConverterString.lower(txHex), callStatus);
|
|
3149
3957
|
}, /*liftString:*/FfiConverterString.lift));
|
|
3150
3958
|
}
|
|
3151
|
-
|
|
3152
|
-
/**
|
|
3153
|
-
* Cancel (evict) a transaction from the wallet's view.
|
|
3154
|
-
* Mirrors Wallet::cancel_tx().
|
|
3155
|
-
*/
|
|
3156
3959
|
cancelTx(txHex) /*throws*/{
|
|
3157
3960
|
uniffiCaller.rustCallWithError(/*liftError:*/FfiConverterTypeBdkError.lift.bind(FfiConverterTypeBdkError), /*caller:*/callStatus => {
|
|
3158
3961
|
(0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_wallet_cancel_tx(uniffiTypeWalletObjectFactory.clonePointer(this), FfiConverterString.lower(txHex), callStatus);
|
|
3159
3962
|
}, /*liftString:*/FfiConverterString.lift);
|
|
3160
3963
|
}
|
|
3161
|
-
|
|
3162
|
-
/**
|
|
3163
|
-
* All checkpoints in the local chain, ordered by height descending.
|
|
3164
|
-
* Mirrors Wallet::checkpoints().
|
|
3165
|
-
*/
|
|
3166
3964
|
checkpoints() {
|
|
3167
3965
|
return FfiConverterArrayTypeBlockId.lift(uniffiCaller.rustCall(/*caller:*/callStatus => {
|
|
3168
3966
|
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_wallet_checkpoints(uniffiTypeWalletObjectFactory.clonePointer(this), callStatus);
|
|
3169
3967
|
}, /*liftString:*/FfiConverterString.lift));
|
|
3170
3968
|
}
|
|
3171
|
-
|
|
3172
|
-
/**
|
|
3173
|
-
* The highest derivation index that has been revealed, or null if none.
|
|
3174
|
-
* Mirrors Wallet::derivation_index().
|
|
3175
|
-
*/
|
|
3176
3969
|
derivationIndex(keychain) {
|
|
3177
3970
|
return FfiConverterOptionalUInt32.lift(uniffiCaller.rustCall(/*caller:*/callStatus => {
|
|
3178
3971
|
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_wallet_derivation_index(uniffiTypeWalletObjectFactory.clonePointer(this), FfiConverterTypeKeychainKind.lower(keychain), callStatus);
|
|
3179
3972
|
}, /*liftString:*/FfiConverterString.lift));
|
|
3180
3973
|
}
|
|
3181
|
-
|
|
3182
|
-
/**
|
|
3183
|
-
* Find the keychain and derivation index for a scriptPubKey (hex).
|
|
3184
|
-
* Returns null if the script does not belong to this wallet.
|
|
3185
|
-
* Mirrors Wallet::derivation_of_spk().
|
|
3186
|
-
*/
|
|
3187
3974
|
derivationOfSpk(scriptHex) {
|
|
3188
3975
|
return FfiConverterOptionalTypeDerivationInfo.lift(uniffiCaller.rustCall(/*caller:*/callStatus => {
|
|
3189
3976
|
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_wallet_derivation_of_spk(uniffiTypeWalletObjectFactory.clonePointer(this), FfiConverterString.lower(scriptHex), callStatus);
|
|
3190
3977
|
}, /*liftString:*/FfiConverterString.lift));
|
|
3191
3978
|
}
|
|
3192
|
-
|
|
3193
|
-
/**
|
|
3194
|
-
* The descriptor checksum for the given keychain.
|
|
3195
|
-
* Mirrors Wallet::descriptor_checksum().
|
|
3196
|
-
*/
|
|
3197
3979
|
descriptorChecksum(keychain) /*throws*/{
|
|
3198
3980
|
return FfiConverterString.lift(uniffiCaller.rustCallWithError(/*liftError:*/FfiConverterTypeBdkError.lift.bind(FfiConverterTypeBdkError), /*caller:*/callStatus => {
|
|
3199
3981
|
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_wallet_descriptor_checksum(uniffiTypeWalletObjectFactory.clonePointer(this), FfiConverterTypeKeychainKind.lower(keychain), callStatus);
|
|
3200
3982
|
}, /*liftString:*/FfiConverterString.lift));
|
|
3201
3983
|
}
|
|
3202
|
-
|
|
3203
|
-
/**
|
|
3204
|
-
* Drain the entire wallet to an address. Returns txid.
|
|
3205
|
-
*/
|
|
3206
3984
|
async drain(address, feeRate, esploraUrl, asyncOpts_) /*throws*/{
|
|
3207
3985
|
const __stack = uniffiIsDebug ? new Error().stack : undefined;
|
|
3208
3986
|
try {
|
|
@@ -3216,26 +3994,29 @@ class Wallet extends _uniffiBindgenReactNative.UniffiAbstractObject {
|
|
|
3216
3994
|
throw __error;
|
|
3217
3995
|
}
|
|
3218
3996
|
}
|
|
3219
|
-
|
|
3220
|
-
|
|
3221
|
-
|
|
3222
|
-
|
|
3223
|
-
|
|
3224
|
-
|
|
3997
|
+
async drainWithElectrum(address, feeRate, client, asyncOpts_) /*throws*/{
|
|
3998
|
+
const __stack = uniffiIsDebug ? new Error().stack : undefined;
|
|
3999
|
+
try {
|
|
4000
|
+
return await (0, _uniffiBindgenReactNative.uniffiRustCallAsync)(/*rustCaller:*/uniffiCaller, /*rustFutureFunc:*/() => {
|
|
4001
|
+
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_wallet_drain_with_electrum(uniffiTypeWalletObjectFactory.clonePointer(this), FfiConverterString.lower(address), _uniffiBindgenReactNative.FfiConverterFloat64.lower(feeRate), FfiConverterTypeElectrumClient.lower(client));
|
|
4002
|
+
}, /*pollFunc:*/(0, _bdk_ffiFfi.default)().ubrn_ffi_bdk_ffi_rust_future_poll_rust_buffer, /*cancelFunc:*/(0, _bdk_ffiFfi.default)().ubrn_ffi_bdk_ffi_rust_future_cancel_rust_buffer, /*completeFunc:*/(0, _bdk_ffiFfi.default)().ubrn_ffi_bdk_ffi_rust_future_complete_rust_buffer, /*freeFunc:*/(0, _bdk_ffiFfi.default)().ubrn_ffi_bdk_ffi_rust_future_free_rust_buffer, /*liftFunc:*/FfiConverterString.lift.bind(FfiConverterString), /*liftString:*/FfiConverterString.lift, /*asyncOpts:*/asyncOpts_, /*errorHandler:*/FfiConverterTypeBdkError.lift.bind(FfiConverterTypeBdkError));
|
|
4003
|
+
} catch (__error) {
|
|
4004
|
+
if (uniffiIsDebug && __error instanceof Error) {
|
|
4005
|
+
__error.stack = __stack;
|
|
4006
|
+
}
|
|
4007
|
+
throw __error;
|
|
4008
|
+
}
|
|
4009
|
+
}
|
|
3225
4010
|
finalizePsbt(psbt) /*throws*/{
|
|
3226
4011
|
return _uniffiBindgenReactNative.FfiConverterBool.lift(uniffiCaller.rustCallWithError(/*liftError:*/FfiConverterTypeBdkError.lift.bind(FfiConverterTypeBdkError), /*caller:*/callStatus => {
|
|
3227
4012
|
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_wallet_finalize_psbt(uniffiTypeWalletObjectFactory.clonePointer(this), FfiConverterTypePsbt.lower(psbt), callStatus);
|
|
3228
4013
|
}, /*liftString:*/FfiConverterString.lift));
|
|
3229
4014
|
}
|
|
3230
|
-
|
|
3231
|
-
/**
|
|
3232
|
-
* Full scan via an Electrum TCP/TLS server.
|
|
3233
|
-
*/
|
|
3234
|
-
async fullScanWithElectrum(url, stopGap, asyncOpts_) /*throws*/{
|
|
4015
|
+
async fullScanWithElectrum(client, stopGap, asyncOpts_) /*throws*/{
|
|
3235
4016
|
const __stack = uniffiIsDebug ? new Error().stack : undefined;
|
|
3236
4017
|
try {
|
|
3237
4018
|
return await (0, _uniffiBindgenReactNative.uniffiRustCallAsync)(/*rustCaller:*/uniffiCaller, /*rustFutureFunc:*/() => {
|
|
3238
|
-
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_wallet_full_scan_with_electrum(uniffiTypeWalletObjectFactory.clonePointer(this),
|
|
4019
|
+
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_wallet_full_scan_with_electrum(uniffiTypeWalletObjectFactory.clonePointer(this), FfiConverterTypeElectrumClient.lower(client), _uniffiBindgenReactNative.FfiConverterUInt64.lower(stopGap));
|
|
3239
4020
|
}, /*pollFunc:*/(0, _bdk_ffiFfi.default)().ubrn_ffi_bdk_ffi_rust_future_poll_void, /*cancelFunc:*/(0, _bdk_ffiFfi.default)().ubrn_ffi_bdk_ffi_rust_future_cancel_void, /*completeFunc:*/(0, _bdk_ffiFfi.default)().ubrn_ffi_bdk_ffi_rust_future_complete_void, /*freeFunc:*/(0, _bdk_ffiFfi.default)().ubrn_ffi_bdk_ffi_rust_future_free_void, /*liftFunc:*/_v => {}, /*liftString:*/FfiConverterString.lift, /*asyncOpts:*/asyncOpts_, /*errorHandler:*/FfiConverterTypeBdkError.lift.bind(FfiConverterTypeBdkError));
|
|
3240
4021
|
} catch (__error) {
|
|
3241
4022
|
if (uniffiIsDebug && __error instanceof Error) {
|
|
@@ -3244,12 +4025,6 @@ class Wallet extends _uniffiBindgenReactNative.UniffiAbstractObject {
|
|
|
3244
4025
|
throw __error;
|
|
3245
4026
|
}
|
|
3246
4027
|
}
|
|
3247
|
-
|
|
3248
|
-
/**
|
|
3249
|
-
* Full scan via an Esplora HTTP server (discovers all used addresses).
|
|
3250
|
-
* Uses Wallet::start_full_scan() + bdk_esplora client internally.
|
|
3251
|
-
* stop_gap: how many consecutive unused addresses to scan before stopping.
|
|
3252
|
-
*/
|
|
3253
4028
|
async fullScanWithEsplora(url, stopGap, asyncOpts_) /*throws*/{
|
|
3254
4029
|
const __stack = uniffiIsDebug ? new Error().stack : undefined;
|
|
3255
4030
|
try {
|
|
@@ -3263,209 +4038,106 @@ class Wallet extends _uniffiBindgenReactNative.UniffiAbstractObject {
|
|
|
3263
4038
|
throw __error;
|
|
3264
4039
|
}
|
|
3265
4040
|
}
|
|
3266
|
-
|
|
3267
|
-
/**
|
|
3268
|
-
* Get the wallet balance. Mirrors Wallet::balance().
|
|
3269
|
-
*/
|
|
3270
4041
|
getBalance() /*throws*/{
|
|
3271
4042
|
return FfiConverterTypeBalance.lift(uniffiCaller.rustCallWithError(/*liftError:*/FfiConverterTypeBdkError.lift.bind(FfiConverterTypeBdkError), /*caller:*/callStatus => {
|
|
3272
4043
|
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_wallet_get_balance(uniffiTypeWalletObjectFactory.clonePointer(this), callStatus);
|
|
3273
4044
|
}, /*liftString:*/FfiConverterString.lift));
|
|
3274
4045
|
}
|
|
3275
|
-
|
|
3276
|
-
/**
|
|
3277
|
-
* Returns the raw transaction hex for a given txid. Null if not found.
|
|
3278
|
-
* Mirrors Wallet::get_tx().
|
|
3279
|
-
*/
|
|
3280
4046
|
getTx(txid) /*throws*/{
|
|
3281
4047
|
return FfiConverterOptionalString.lift(uniffiCaller.rustCallWithError(/*liftError:*/FfiConverterTypeBdkError.lift.bind(FfiConverterTypeBdkError), /*caller:*/callStatus => {
|
|
3282
4048
|
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_wallet_get_tx(uniffiTypeWalletObjectFactory.clonePointer(this), FfiConverterString.lower(txid), callStatus);
|
|
3283
4049
|
}, /*liftString:*/FfiConverterString.lift));
|
|
3284
4050
|
}
|
|
3285
|
-
|
|
3286
|
-
/**
|
|
3287
|
-
* Get a specific UTXO. Returns null if not found. Mirrors Wallet::get_utxo().
|
|
3288
|
-
*/
|
|
3289
4051
|
getUtxo(outpoint) /*throws*/{
|
|
3290
4052
|
return FfiConverterOptionalTypeLocalOutput.lift(uniffiCaller.rustCallWithError(/*liftError:*/FfiConverterTypeBdkError.lift.bind(FfiConverterTypeBdkError), /*caller:*/callStatus => {
|
|
3291
4053
|
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_wallet_get_utxo(uniffiTypeWalletObjectFactory.clonePointer(this), FfiConverterTypeOutPoint.lower(outpoint), callStatus);
|
|
3292
4054
|
}, /*liftString:*/FfiConverterString.lift));
|
|
3293
4055
|
}
|
|
3294
|
-
|
|
3295
|
-
/**
|
|
3296
|
-
* Manually insert a TxOut (e.g. for tracking external outputs).
|
|
3297
|
-
* Mirrors Wallet::insert_txout().
|
|
3298
|
-
*/
|
|
3299
4056
|
insertTxout(outpoint, txout) {
|
|
3300
4057
|
uniffiCaller.rustCall(/*caller:*/callStatus => {
|
|
3301
4058
|
(0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_wallet_insert_txout(uniffiTypeWalletObjectFactory.clonePointer(this), FfiConverterTypeOutPoint.lower(outpoint), FfiConverterTypeTxOut.lower(txout), callStatus);
|
|
3302
4059
|
}, /*liftString:*/FfiConverterString.lift);
|
|
3303
4060
|
}
|
|
3304
|
-
|
|
3305
|
-
/**
|
|
3306
|
-
* Return true if the given scriptPubKey (hex) belongs to this wallet.
|
|
3307
|
-
* Mirrors Wallet::is_mine().
|
|
3308
|
-
*/
|
|
3309
4061
|
isMine(scriptHex) {
|
|
3310
4062
|
return _uniffiBindgenReactNative.FfiConverterBool.lift(uniffiCaller.rustCall(/*caller:*/callStatus => {
|
|
3311
4063
|
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_wallet_is_mine(uniffiTypeWalletObjectFactory.clonePointer(this), FfiConverterString.lower(scriptHex), callStatus);
|
|
3312
4064
|
}, /*liftString:*/FfiConverterString.lift));
|
|
3313
4065
|
}
|
|
3314
|
-
|
|
3315
|
-
/**
|
|
3316
|
-
* List all keychains and their public descriptors.
|
|
3317
|
-
* Mirrors Wallet::keychains().
|
|
3318
|
-
*/
|
|
3319
4066
|
keychains() {
|
|
3320
4067
|
return FfiConverterArrayTypeKeychainInfo.lift(uniffiCaller.rustCall(/*caller:*/callStatus => {
|
|
3321
4068
|
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_wallet_keychains(uniffiTypeWalletObjectFactory.clonePointer(this), callStatus);
|
|
3322
4069
|
}, /*liftString:*/FfiConverterString.lift));
|
|
3323
4070
|
}
|
|
3324
|
-
|
|
3325
|
-
/**
|
|
3326
|
-
* The latest checkpoint (tip of the local chain). Null if no blocks applied yet.
|
|
3327
|
-
* Mirrors Wallet::latest_checkpoint().
|
|
3328
|
-
*/
|
|
3329
4071
|
latestCheckpoint() {
|
|
3330
4072
|
return FfiConverterOptionalTypeBlockId.lift(uniffiCaller.rustCall(/*caller:*/callStatus => {
|
|
3331
4073
|
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_wallet_latest_checkpoint(uniffiTypeWalletObjectFactory.clonePointer(this), callStatus);
|
|
3332
4074
|
}, /*liftString:*/FfiConverterString.lift));
|
|
3333
4075
|
}
|
|
3334
|
-
|
|
3335
|
-
/**
|
|
3336
|
-
* List all wallet outputs (spent and unspent). Mirrors Wallet::list_output().
|
|
3337
|
-
*/
|
|
3338
4076
|
listOutput() /*throws*/{
|
|
3339
4077
|
return FfiConverterArrayTypeLocalOutput.lift(uniffiCaller.rustCallWithError(/*liftError:*/FfiConverterTypeBdkError.lift.bind(FfiConverterTypeBdkError), /*caller:*/callStatus => {
|
|
3340
4078
|
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_wallet_list_output(uniffiTypeWalletObjectFactory.clonePointer(this), callStatus);
|
|
3341
4079
|
}, /*liftString:*/FfiConverterString.lift));
|
|
3342
4080
|
}
|
|
3343
|
-
|
|
3344
|
-
/**
|
|
3345
|
-
* List all unspent wallet outputs. Mirrors Wallet::list_unspent().
|
|
3346
|
-
*/
|
|
3347
4081
|
listUnspent() /*throws*/{
|
|
3348
4082
|
return FfiConverterArrayTypeLocalOutput.lift(uniffiCaller.rustCallWithError(/*liftError:*/FfiConverterTypeBdkError.lift.bind(FfiConverterTypeBdkError), /*caller:*/callStatus => {
|
|
3349
4083
|
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_wallet_list_unspent(uniffiTypeWalletObjectFactory.clonePointer(this), callStatus);
|
|
3350
4084
|
}, /*liftString:*/FfiConverterString.lift));
|
|
3351
4085
|
}
|
|
3352
|
-
|
|
3353
|
-
/**
|
|
3354
|
-
* List all addresses that have been revealed but not yet received funds.
|
|
3355
|
-
* Mirrors Wallet::list_unused_addresses().
|
|
3356
|
-
*/
|
|
3357
4086
|
listUnusedAddresses(keychain) /*throws*/{
|
|
3358
4087
|
return FfiConverterArrayTypeAddressInfo.lift(uniffiCaller.rustCallWithError(/*liftError:*/FfiConverterTypeBdkError.lift.bind(FfiConverterTypeBdkError), /*caller:*/callStatus => {
|
|
3359
4088
|
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_wallet_list_unused_addresses(uniffiTypeWalletObjectFactory.clonePointer(this), FfiConverterTypeKeychainKind.lower(keychain), callStatus);
|
|
3360
4089
|
}, /*liftString:*/FfiConverterString.lift));
|
|
3361
4090
|
}
|
|
3362
|
-
|
|
3363
|
-
/**
|
|
3364
|
-
* Mark an address index as used (returns true if previously unused).
|
|
3365
|
-
* Mirrors Wallet::mark_used().
|
|
3366
|
-
*/
|
|
3367
4091
|
markUsed(keychain, index) {
|
|
3368
4092
|
return _uniffiBindgenReactNative.FfiConverterBool.lift(uniffiCaller.rustCall(/*caller:*/callStatus => {
|
|
3369
4093
|
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_wallet_mark_used(uniffiTypeWalletObjectFactory.clonePointer(this), FfiConverterTypeKeychainKind.lower(keychain), _uniffiBindgenReactNative.FfiConverterUInt32.lower(index), callStatus);
|
|
3370
4094
|
}, /*liftString:*/FfiConverterString.lift));
|
|
3371
4095
|
}
|
|
3372
|
-
|
|
3373
|
-
/**
|
|
3374
|
-
* The network this wallet is configured for.
|
|
3375
|
-
* Mirrors Wallet::network().
|
|
3376
|
-
*/
|
|
3377
4096
|
network() {
|
|
3378
4097
|
return FfiConverterTypeNetwork.lift(uniffiCaller.rustCall(/*caller:*/callStatus => {
|
|
3379
4098
|
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_wallet_network(uniffiTypeWalletObjectFactory.clonePointer(this), callStatus);
|
|
3380
4099
|
}, /*liftString:*/FfiConverterString.lift));
|
|
3381
4100
|
}
|
|
3382
|
-
|
|
3383
|
-
/**
|
|
3384
|
-
* The next derivation index that will be revealed.
|
|
3385
|
-
* Mirrors Wallet::next_derivation_index().
|
|
3386
|
-
*/
|
|
3387
4101
|
nextDerivationIndex(keychain) {
|
|
3388
4102
|
return _uniffiBindgenReactNative.FfiConverterUInt32.lift(uniffiCaller.rustCall(/*caller:*/callStatus => {
|
|
3389
4103
|
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_wallet_next_derivation_index(uniffiTypeWalletObjectFactory.clonePointer(this), FfiConverterTypeKeychainKind.lower(keychain), callStatus);
|
|
3390
4104
|
}, /*liftString:*/FfiConverterString.lift));
|
|
3391
4105
|
}
|
|
3392
|
-
|
|
3393
|
-
/**
|
|
3394
|
-
* Return the next address that has not yet received funds.
|
|
3395
|
-
* Mirrors Wallet::next_unused_address().
|
|
3396
|
-
*/
|
|
3397
4106
|
nextUnusedAddress(keychain) /*throws*/{
|
|
3398
4107
|
return FfiConverterTypeAddressInfo.lift(uniffiCaller.rustCallWithError(/*liftError:*/FfiConverterTypeBdkError.lift.bind(FfiConverterTypeBdkError), /*caller:*/callStatus => {
|
|
3399
4108
|
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_wallet_next_unused_address(uniffiTypeWalletObjectFactory.clonePointer(this), FfiConverterTypeKeychainKind.lower(keychain), callStatus);
|
|
3400
4109
|
}, /*liftString:*/FfiConverterString.lift));
|
|
3401
4110
|
}
|
|
3402
|
-
|
|
3403
|
-
/**
|
|
3404
|
-
* Peek at a specific derivation index without advancing the counter.
|
|
3405
|
-
* Mirrors Wallet::peek_address().
|
|
3406
|
-
*/
|
|
3407
4111
|
peekAddress(keychain, index) /*throws*/{
|
|
3408
4112
|
return FfiConverterTypeAddressInfo.lift(uniffiCaller.rustCallWithError(/*liftError:*/FfiConverterTypeBdkError.lift.bind(FfiConverterTypeBdkError), /*caller:*/callStatus => {
|
|
3409
4113
|
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_wallet_peek_address(uniffiTypeWalletObjectFactory.clonePointer(this), FfiConverterTypeKeychainKind.lower(keychain), _uniffiBindgenReactNative.FfiConverterUInt32.lower(index), callStatus);
|
|
3410
4114
|
}, /*liftString:*/FfiConverterString.lift));
|
|
3411
4115
|
}
|
|
3412
|
-
|
|
3413
|
-
/**
|
|
3414
|
-
* Persist any staged changes to the database.
|
|
3415
|
-
* Our FFI wraps PersistedWallet; this calls persist() internally.
|
|
3416
|
-
*/
|
|
3417
4116
|
persist() /*throws*/{
|
|
3418
4117
|
return _uniffiBindgenReactNative.FfiConverterBool.lift(uniffiCaller.rustCallWithError(/*liftError:*/FfiConverterTypeBdkError.lift.bind(FfiConverterTypeBdkError), /*caller:*/callStatus => {
|
|
3419
4118
|
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_wallet_persist(uniffiTypeWalletObjectFactory.clonePointer(this), callStatus);
|
|
3420
4119
|
}, /*liftString:*/FfiConverterString.lift));
|
|
3421
4120
|
}
|
|
3422
|
-
|
|
3423
|
-
/**
|
|
3424
|
-
* Spending policies for a given keychain, returned as a JSON string.
|
|
3425
|
-
* Returns null if the descriptor has no policy.
|
|
3426
|
-
* Mirrors Wallet::policies() — serialized because the Policy tree is complex.
|
|
3427
|
-
*/
|
|
3428
4121
|
policies(keychain) /*throws*/{
|
|
3429
4122
|
return FfiConverterOptionalString.lift(uniffiCaller.rustCallWithError(/*liftError:*/FfiConverterTypeBdkError.lift.bind(FfiConverterTypeBdkError), /*caller:*/callStatus => {
|
|
3430
4123
|
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_wallet_policies(uniffiTypeWalletObjectFactory.clonePointer(this), FfiConverterTypeKeychainKind.lower(keychain), callStatus);
|
|
3431
4124
|
}, /*liftString:*/FfiConverterString.lift));
|
|
3432
4125
|
}
|
|
3433
|
-
|
|
3434
|
-
/**
|
|
3435
|
-
* The public-only descriptor for the given keychain as a string.
|
|
3436
|
-
* Mirrors Wallet::public_descriptor().
|
|
3437
|
-
*/
|
|
3438
4126
|
publicDescriptor(keychain) /*throws*/{
|
|
3439
4127
|
return FfiConverterString.lift(uniffiCaller.rustCallWithError(/*liftError:*/FfiConverterTypeBdkError.lift.bind(FfiConverterTypeBdkError), /*caller:*/callStatus => {
|
|
3440
4128
|
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_wallet_public_descriptor(uniffiTypeWalletObjectFactory.clonePointer(this), FfiConverterTypeKeychainKind.lower(keychain), callStatus);
|
|
3441
4129
|
}, /*liftString:*/FfiConverterString.lift));
|
|
3442
4130
|
}
|
|
3443
|
-
|
|
3444
|
-
/**
|
|
3445
|
-
* Reveal all addresses up to and including the given derivation index.
|
|
3446
|
-
* Mirrors Wallet::reveal_addresses_to().
|
|
3447
|
-
*/
|
|
3448
4131
|
revealAddressesTo(keychain, index) /*throws*/{
|
|
3449
4132
|
return FfiConverterArrayTypeAddressInfo.lift(uniffiCaller.rustCallWithError(/*liftError:*/FfiConverterTypeBdkError.lift.bind(FfiConverterTypeBdkError), /*caller:*/callStatus => {
|
|
3450
4133
|
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_wallet_reveal_addresses_to(uniffiTypeWalletObjectFactory.clonePointer(this), FfiConverterTypeKeychainKind.lower(keychain), _uniffiBindgenReactNative.FfiConverterUInt32.lower(index), callStatus);
|
|
3451
4134
|
}, /*liftString:*/FfiConverterString.lift));
|
|
3452
4135
|
}
|
|
3453
|
-
|
|
3454
|
-
/**
|
|
3455
|
-
* Reveal and return the next address at the next derivation index,
|
|
3456
|
-
* incrementing the index even if previous addresses are unused.
|
|
3457
|
-
* Mirrors Wallet::reveal_next_address().
|
|
3458
|
-
*/
|
|
3459
4136
|
revealNextAddress(keychain) /*throws*/{
|
|
3460
4137
|
return FfiConverterTypeAddressInfo.lift(uniffiCaller.rustCallWithError(/*liftError:*/FfiConverterTypeBdkError.lift.bind(FfiConverterTypeBdkError), /*caller:*/callStatus => {
|
|
3461
4138
|
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_wallet_reveal_next_address(uniffiTypeWalletObjectFactory.clonePointer(this), FfiConverterTypeKeychainKind.lower(keychain), callStatus);
|
|
3462
4139
|
}, /*liftString:*/FfiConverterString.lift));
|
|
3463
4140
|
}
|
|
3464
|
-
|
|
3465
|
-
/**
|
|
3466
|
-
* Build, sign, and broadcast a simple payment in one call. Returns txid.
|
|
3467
|
-
* Combines build_tx → sign → broadcast via Esplora.
|
|
3468
|
-
*/
|
|
3469
4141
|
async send(address, amountSats, feeRate, esploraUrl, asyncOpts_) /*throws*/{
|
|
3470
4142
|
const __stack = uniffiIsDebug ? new Error().stack : undefined;
|
|
3471
4143
|
try {
|
|
@@ -3479,36 +4151,34 @@ class Wallet extends _uniffiBindgenReactNative.UniffiAbstractObject {
|
|
|
3479
4151
|
throw __error;
|
|
3480
4152
|
}
|
|
3481
4153
|
}
|
|
3482
|
-
|
|
3483
|
-
|
|
3484
|
-
|
|
3485
|
-
|
|
3486
|
-
|
|
4154
|
+
async sendWithElectrum(address, amountSats, feeRate, client, asyncOpts_) /*throws*/{
|
|
4155
|
+
const __stack = uniffiIsDebug ? new Error().stack : undefined;
|
|
4156
|
+
try {
|
|
4157
|
+
return await (0, _uniffiBindgenReactNative.uniffiRustCallAsync)(/*rustCaller:*/uniffiCaller, /*rustFutureFunc:*/() => {
|
|
4158
|
+
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_wallet_send_with_electrum(uniffiTypeWalletObjectFactory.clonePointer(this), FfiConverterString.lower(address), _uniffiBindgenReactNative.FfiConverterUInt64.lower(amountSats), _uniffiBindgenReactNative.FfiConverterFloat64.lower(feeRate), FfiConverterTypeElectrumClient.lower(client));
|
|
4159
|
+
}, /*pollFunc:*/(0, _bdk_ffiFfi.default)().ubrn_ffi_bdk_ffi_rust_future_poll_rust_buffer, /*cancelFunc:*/(0, _bdk_ffiFfi.default)().ubrn_ffi_bdk_ffi_rust_future_cancel_rust_buffer, /*completeFunc:*/(0, _bdk_ffiFfi.default)().ubrn_ffi_bdk_ffi_rust_future_complete_rust_buffer, /*freeFunc:*/(0, _bdk_ffiFfi.default)().ubrn_ffi_bdk_ffi_rust_future_free_rust_buffer, /*liftFunc:*/FfiConverterString.lift.bind(FfiConverterString), /*liftString:*/FfiConverterString.lift, /*asyncOpts:*/asyncOpts_, /*errorHandler:*/FfiConverterTypeBdkError.lift.bind(FfiConverterTypeBdkError));
|
|
4160
|
+
} catch (__error) {
|
|
4161
|
+
if (uniffiIsDebug && __error instanceof Error) {
|
|
4162
|
+
__error.stack = __stack;
|
|
4163
|
+
}
|
|
4164
|
+
throw __error;
|
|
4165
|
+
}
|
|
4166
|
+
}
|
|
3487
4167
|
sentAndReceived(txHex) /*throws*/{
|
|
3488
4168
|
return FfiConverterTypeSentAndReceived.lift(uniffiCaller.rustCallWithError(/*liftError:*/FfiConverterTypeBdkError.lift.bind(FfiConverterTypeBdkError), /*caller:*/callStatus => {
|
|
3489
4169
|
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_wallet_sent_and_received(uniffiTypeWalletObjectFactory.clonePointer(this), FfiConverterString.lower(txHex), callStatus);
|
|
3490
4170
|
}, /*liftString:*/FfiConverterString.lift));
|
|
3491
4171
|
}
|
|
3492
|
-
|
|
3493
|
-
/**
|
|
3494
|
-
* Sign all inputs in the PSBT that this wallet can sign.
|
|
3495
|
-
* Returns true if the PSBT is fully finalized after signing.
|
|
3496
|
-
* Mirrors Wallet::sign() with default SignOptions.
|
|
3497
|
-
*/
|
|
3498
4172
|
sign(psbt) /*throws*/{
|
|
3499
4173
|
return _uniffiBindgenReactNative.FfiConverterBool.lift(uniffiCaller.rustCallWithError(/*liftError:*/FfiConverterTypeBdkError.lift.bind(FfiConverterTypeBdkError), /*caller:*/callStatus => {
|
|
3500
4174
|
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_wallet_sign(uniffiTypeWalletObjectFactory.clonePointer(this), FfiConverterTypePsbt.lower(psbt), callStatus);
|
|
3501
4175
|
}, /*liftString:*/FfiConverterString.lift));
|
|
3502
4176
|
}
|
|
3503
|
-
|
|
3504
|
-
/**
|
|
3505
|
-
* Incremental sync via Electrum.
|
|
3506
|
-
*/
|
|
3507
|
-
async syncWithElectrum(url, stopGap, asyncOpts_) /*throws*/{
|
|
4177
|
+
async syncWithElectrum(client, stopGap, asyncOpts_) /*throws*/{
|
|
3508
4178
|
const __stack = uniffiIsDebug ? new Error().stack : undefined;
|
|
3509
4179
|
try {
|
|
3510
4180
|
return await (0, _uniffiBindgenReactNative.uniffiRustCallAsync)(/*rustCaller:*/uniffiCaller, /*rustFutureFunc:*/() => {
|
|
3511
|
-
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_wallet_sync_with_electrum(uniffiTypeWalletObjectFactory.clonePointer(this),
|
|
4181
|
+
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_wallet_sync_with_electrum(uniffiTypeWalletObjectFactory.clonePointer(this), FfiConverterTypeElectrumClient.lower(client), _uniffiBindgenReactNative.FfiConverterUInt64.lower(stopGap));
|
|
3512
4182
|
}, /*pollFunc:*/(0, _bdk_ffiFfi.default)().ubrn_ffi_bdk_ffi_rust_future_poll_void, /*cancelFunc:*/(0, _bdk_ffiFfi.default)().ubrn_ffi_bdk_ffi_rust_future_cancel_void, /*completeFunc:*/(0, _bdk_ffiFfi.default)().ubrn_ffi_bdk_ffi_rust_future_complete_void, /*freeFunc:*/(0, _bdk_ffiFfi.default)().ubrn_ffi_bdk_ffi_rust_future_free_void, /*liftFunc:*/_v => {}, /*liftString:*/FfiConverterString.lift, /*asyncOpts:*/asyncOpts_, /*errorHandler:*/FfiConverterTypeBdkError.lift.bind(FfiConverterTypeBdkError));
|
|
3513
4183
|
} catch (__error) {
|
|
3514
4184
|
if (uniffiIsDebug && __error instanceof Error) {
|
|
@@ -3517,11 +4187,6 @@ class Wallet extends _uniffiBindgenReactNative.UniffiAbstractObject {
|
|
|
3517
4187
|
throw __error;
|
|
3518
4188
|
}
|
|
3519
4189
|
}
|
|
3520
|
-
|
|
3521
|
-
/**
|
|
3522
|
-
* Incremental sync via Esplora (only checks revealed SPKs + UTXOs + unconfirmed).
|
|
3523
|
-
* Uses Wallet::start_sync_with_revealed_spks() + bdk_esplora client internally.
|
|
3524
|
-
*/
|
|
3525
4190
|
async syncWithEsplora(url, stopGap, asyncOpts_) /*throws*/{
|
|
3526
4191
|
const __stack = uniffiIsDebug ? new Error().stack : undefined;
|
|
3527
4192
|
try {
|
|
@@ -3535,31 +4200,16 @@ class Wallet extends _uniffiBindgenReactNative.UniffiAbstractObject {
|
|
|
3535
4200
|
throw __error;
|
|
3536
4201
|
}
|
|
3537
4202
|
}
|
|
3538
|
-
|
|
3539
|
-
/**
|
|
3540
|
-
* All wallet-relevant canonical transactions.
|
|
3541
|
-
* Mirrors Wallet::transactions() → mapped to TxDetails.
|
|
3542
|
-
*/
|
|
3543
4203
|
transactions() /*throws*/{
|
|
3544
4204
|
return FfiConverterArrayTypeTxDetails.lift(uniffiCaller.rustCallWithError(/*liftError:*/FfiConverterTypeBdkError.lift.bind(FfiConverterTypeBdkError), /*caller:*/callStatus => {
|
|
3545
4205
|
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_wallet_transactions(uniffiTypeWalletObjectFactory.clonePointer(this), callStatus);
|
|
3546
4206
|
}, /*liftString:*/FfiConverterString.lift));
|
|
3547
4207
|
}
|
|
3548
|
-
|
|
3549
|
-
/**
|
|
3550
|
-
* Details for a single transaction. Returns null if not found.
|
|
3551
|
-
* Mirrors Wallet::tx_details().
|
|
3552
|
-
*/
|
|
3553
4208
|
txDetails(txid) /*throws*/{
|
|
3554
4209
|
return FfiConverterOptionalTypeTxDetails.lift(uniffiCaller.rustCallWithError(/*liftError:*/FfiConverterTypeBdkError.lift.bind(FfiConverterTypeBdkError), /*caller:*/callStatus => {
|
|
3555
4210
|
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_wallet_tx_details(uniffiTypeWalletObjectFactory.clonePointer(this), FfiConverterString.lower(txid), callStatus);
|
|
3556
4211
|
}, /*liftString:*/FfiConverterString.lift));
|
|
3557
4212
|
}
|
|
3558
|
-
|
|
3559
|
-
/**
|
|
3560
|
-
* Mark an address index as unused (returns true if previously used).
|
|
3561
|
-
* Mirrors Wallet::unmark_used().
|
|
3562
|
-
*/
|
|
3563
4213
|
unmarkUsed(keychain, index) {
|
|
3564
4214
|
return _uniffiBindgenReactNative.FfiConverterBool.lift(uniffiCaller.rustCall(/*caller:*/callStatus => {
|
|
3565
4215
|
return (0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_fn_method_wallet_unmark_used(uniffiTypeWalletObjectFactory.clonePointer(this), FfiConverterTypeKeychainKind.lower(keychain), _uniffiBindgenReactNative.FfiConverterUInt32.lower(index), callStatus);
|
|
@@ -3670,6 +4320,12 @@ const FfiConverterArrayTypeRecipient = new _uniffiBindgenReactNative.FfiConverte
|
|
|
3670
4320
|
// FfiConverter for Array<TxDetails>
|
|
3671
4321
|
const FfiConverterArrayTypeTxDetails = new _uniffiBindgenReactNative.FfiConverterArray(FfiConverterTypeTxDetails);
|
|
3672
4322
|
|
|
4323
|
+
// FfiConverter for Array<TxInput>
|
|
4324
|
+
const FfiConverterArrayTypeTxInput = new _uniffiBindgenReactNative.FfiConverterArray(FfiConverterTypeTxInput);
|
|
4325
|
+
|
|
4326
|
+
// FfiConverter for Array<TxOutput>
|
|
4327
|
+
const FfiConverterArrayTypeTxOutput = new _uniffiBindgenReactNative.FfiConverterArray(FfiConverterTypeTxOutput);
|
|
4328
|
+
|
|
3673
4329
|
// FfiConverter for Array<string>
|
|
3674
4330
|
const FfiConverterArrayString = new _uniffiBindgenReactNative.FfiConverterArray(FfiConverterString);
|
|
3675
4331
|
|
|
@@ -3694,21 +4350,33 @@ function uniffiEnsureInitialized() {
|
|
|
3694
4350
|
if (bindingsContractVersion !== scaffoldingContractVersion) {
|
|
3695
4351
|
throw new _uniffiBindgenReactNative.UniffiInternalError.ContractVersionMismatch(scaffoldingContractVersion, bindingsContractVersion);
|
|
3696
4352
|
}
|
|
4353
|
+
if ((0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_checksum_func_address_from_script() !== 50547) {
|
|
4354
|
+
throw new _uniffiBindgenReactNative.UniffiInternalError.ApiChecksumMismatch("uniffi_bdk_ffi_checksum_func_address_from_script");
|
|
4355
|
+
}
|
|
3697
4356
|
if ((0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_checksum_func_create_descriptor() !== 166) {
|
|
3698
4357
|
throw new _uniffiBindgenReactNative.UniffiInternalError.ApiChecksumMismatch("uniffi_bdk_ffi_checksum_func_create_descriptor");
|
|
3699
4358
|
}
|
|
4359
|
+
if ((0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_checksum_func_create_descriptor_from_string() !== 29727) {
|
|
4360
|
+
throw new _uniffiBindgenReactNative.UniffiInternalError.ApiChecksumMismatch("uniffi_bdk_ffi_checksum_func_create_descriptor_from_string");
|
|
4361
|
+
}
|
|
3700
4362
|
if ((0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_checksum_func_create_public_descriptor() !== 10610) {
|
|
3701
4363
|
throw new _uniffiBindgenReactNative.UniffiInternalError.ApiChecksumMismatch("uniffi_bdk_ffi_checksum_func_create_public_descriptor");
|
|
3702
4364
|
}
|
|
3703
4365
|
if ((0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_checksum_func_create_single_key_descriptor() !== 56046) {
|
|
3704
4366
|
throw new _uniffiBindgenReactNative.UniffiInternalError.ApiChecksumMismatch("uniffi_bdk_ffi_checksum_func_create_single_key_descriptor");
|
|
3705
4367
|
}
|
|
4368
|
+
if ((0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_checksum_func_create_wallet() !== 59494) {
|
|
4369
|
+
throw new _uniffiBindgenReactNative.UniffiInternalError.ApiChecksumMismatch("uniffi_bdk_ffi_checksum_func_create_wallet");
|
|
4370
|
+
}
|
|
3706
4371
|
if ((0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_checksum_func_export_wallet() !== 53701) {
|
|
3707
4372
|
throw new _uniffiBindgenReactNative.UniffiInternalError.ApiChecksumMismatch("uniffi_bdk_ffi_checksum_func_export_wallet");
|
|
3708
4373
|
}
|
|
3709
4374
|
if ((0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_checksum_func_is_valid_address() !== 14593) {
|
|
3710
4375
|
throw new _uniffiBindgenReactNative.UniffiInternalError.ApiChecksumMismatch("uniffi_bdk_ffi_checksum_func_is_valid_address");
|
|
3711
4376
|
}
|
|
4377
|
+
if ((0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_checksum_func_validate_descriptor() !== 44572) {
|
|
4378
|
+
throw new _uniffiBindgenReactNative.UniffiInternalError.ApiChecksumMismatch("uniffi_bdk_ffi_checksum_func_validate_descriptor");
|
|
4379
|
+
}
|
|
3712
4380
|
if ((0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_checksum_func_version() !== 5205) {
|
|
3713
4381
|
throw new _uniffiBindgenReactNative.UniffiInternalError.ApiChecksumMismatch("uniffi_bdk_ffi_checksum_func_version");
|
|
3714
4382
|
}
|
|
@@ -3802,7 +4470,7 @@ function uniffiEnsureInitialized() {
|
|
|
3802
4470
|
if ((0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_checksum_method_txbuilder_fee_rate() !== 2789) {
|
|
3803
4471
|
throw new _uniffiBindgenReactNative.UniffiInternalError.ApiChecksumMismatch("uniffi_bdk_ffi_checksum_method_txbuilder_fee_rate");
|
|
3804
4472
|
}
|
|
3805
|
-
if ((0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_checksum_method_txbuilder_finish() !==
|
|
4473
|
+
if ((0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_checksum_method_txbuilder_finish() !== 23648) {
|
|
3806
4474
|
throw new _uniffiBindgenReactNative.UniffiInternalError.ApiChecksumMismatch("uniffi_bdk_ffi_checksum_method_txbuilder_finish");
|
|
3807
4475
|
}
|
|
3808
4476
|
if ((0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_checksum_method_txbuilder_include_output_redeem_witness_script() !== 1428) {
|
|
@@ -3841,7 +4509,7 @@ function uniffiEnsureInitialized() {
|
|
|
3841
4509
|
if ((0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_checksum_method_txbuilder_unspendable() !== 10665) {
|
|
3842
4510
|
throw new _uniffiBindgenReactNative.UniffiInternalError.ApiChecksumMismatch("uniffi_bdk_ffi_checksum_method_txbuilder_unspendable");
|
|
3843
4511
|
}
|
|
3844
|
-
if ((0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_checksum_method_wallet_broadcast_with_electrum() !==
|
|
4512
|
+
if ((0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_checksum_method_wallet_broadcast_with_electrum() !== 26438) {
|
|
3845
4513
|
throw new _uniffiBindgenReactNative.UniffiInternalError.ApiChecksumMismatch("uniffi_bdk_ffi_checksum_method_wallet_broadcast_with_electrum");
|
|
3846
4514
|
}
|
|
3847
4515
|
if ((0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_checksum_method_wallet_broadcast_with_esplora() !== 37423) {
|
|
@@ -3874,10 +4542,13 @@ function uniffiEnsureInitialized() {
|
|
|
3874
4542
|
if ((0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_checksum_method_wallet_drain() !== 47076) {
|
|
3875
4543
|
throw new _uniffiBindgenReactNative.UniffiInternalError.ApiChecksumMismatch("uniffi_bdk_ffi_checksum_method_wallet_drain");
|
|
3876
4544
|
}
|
|
4545
|
+
if ((0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_checksum_method_wallet_drain_with_electrum() !== 42924) {
|
|
4546
|
+
throw new _uniffiBindgenReactNative.UniffiInternalError.ApiChecksumMismatch("uniffi_bdk_ffi_checksum_method_wallet_drain_with_electrum");
|
|
4547
|
+
}
|
|
3877
4548
|
if ((0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_checksum_method_wallet_finalize_psbt() !== 43414) {
|
|
3878
4549
|
throw new _uniffiBindgenReactNative.UniffiInternalError.ApiChecksumMismatch("uniffi_bdk_ffi_checksum_method_wallet_finalize_psbt");
|
|
3879
4550
|
}
|
|
3880
|
-
if ((0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_checksum_method_wallet_full_scan_with_electrum() !==
|
|
4551
|
+
if ((0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_checksum_method_wallet_full_scan_with_electrum() !== 40837) {
|
|
3881
4552
|
throw new _uniffiBindgenReactNative.UniffiInternalError.ApiChecksumMismatch("uniffi_bdk_ffi_checksum_method_wallet_full_scan_with_electrum");
|
|
3882
4553
|
}
|
|
3883
4554
|
if ((0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_checksum_method_wallet_full_scan_with_esplora() !== 39717) {
|
|
@@ -3946,13 +4617,16 @@ function uniffiEnsureInitialized() {
|
|
|
3946
4617
|
if ((0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_checksum_method_wallet_send() !== 4457) {
|
|
3947
4618
|
throw new _uniffiBindgenReactNative.UniffiInternalError.ApiChecksumMismatch("uniffi_bdk_ffi_checksum_method_wallet_send");
|
|
3948
4619
|
}
|
|
4620
|
+
if ((0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_checksum_method_wallet_send_with_electrum() !== 23570) {
|
|
4621
|
+
throw new _uniffiBindgenReactNative.UniffiInternalError.ApiChecksumMismatch("uniffi_bdk_ffi_checksum_method_wallet_send_with_electrum");
|
|
4622
|
+
}
|
|
3949
4623
|
if ((0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_checksum_method_wallet_sent_and_received() !== 949) {
|
|
3950
4624
|
throw new _uniffiBindgenReactNative.UniffiInternalError.ApiChecksumMismatch("uniffi_bdk_ffi_checksum_method_wallet_sent_and_received");
|
|
3951
4625
|
}
|
|
3952
4626
|
if ((0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_checksum_method_wallet_sign() !== 32193) {
|
|
3953
4627
|
throw new _uniffiBindgenReactNative.UniffiInternalError.ApiChecksumMismatch("uniffi_bdk_ffi_checksum_method_wallet_sign");
|
|
3954
4628
|
}
|
|
3955
|
-
if ((0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_checksum_method_wallet_sync_with_electrum() !==
|
|
4629
|
+
if ((0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_checksum_method_wallet_sync_with_electrum() !== 17015) {
|
|
3956
4630
|
throw new _uniffiBindgenReactNative.UniffiInternalError.ApiChecksumMismatch("uniffi_bdk_ffi_checksum_method_wallet_sync_with_electrum");
|
|
3957
4631
|
}
|
|
3958
4632
|
if ((0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_checksum_method_wallet_sync_with_esplora() !== 28111) {
|
|
@@ -3967,6 +4641,9 @@ function uniffiEnsureInitialized() {
|
|
|
3967
4641
|
if ((0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_checksum_method_wallet_unmark_used() !== 46731) {
|
|
3968
4642
|
throw new _uniffiBindgenReactNative.UniffiInternalError.ApiChecksumMismatch("uniffi_bdk_ffi_checksum_method_wallet_unmark_used");
|
|
3969
4643
|
}
|
|
4644
|
+
if ((0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_checksum_constructor_electrumclient_new() !== 63288) {
|
|
4645
|
+
throw new _uniffiBindgenReactNative.UniffiInternalError.ApiChecksumMismatch("uniffi_bdk_ffi_checksum_constructor_electrumclient_new");
|
|
4646
|
+
}
|
|
3970
4647
|
if ((0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_checksum_constructor_mnemonic_from_entropy() !== 37039) {
|
|
3971
4648
|
throw new _uniffiBindgenReactNative.UniffiInternalError.ApiChecksumMismatch("uniffi_bdk_ffi_checksum_constructor_mnemonic_from_entropy");
|
|
3972
4649
|
}
|
|
@@ -3988,7 +4665,7 @@ function uniffiEnsureInitialized() {
|
|
|
3988
4665
|
if ((0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_checksum_constructor_txbuilder_new() !== 16691) {
|
|
3989
4666
|
throw new _uniffiBindgenReactNative.UniffiInternalError.ApiChecksumMismatch("uniffi_bdk_ffi_checksum_constructor_txbuilder_new");
|
|
3990
4667
|
}
|
|
3991
|
-
if ((0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_checksum_constructor_wallet_new() !==
|
|
4668
|
+
if ((0, _bdk_ffiFfi.default)().ubrn_uniffi_bdk_ffi_checksum_constructor_wallet_new() !== 64812) {
|
|
3992
4669
|
throw new _uniffiBindgenReactNative.UniffiInternalError.ApiChecksumMismatch("uniffi_bdk_ffi_checksum_constructor_wallet_new");
|
|
3993
4670
|
}
|
|
3994
4671
|
}
|
|
@@ -4003,6 +4680,7 @@ var _default = exports.default = Object.freeze({
|
|
|
4003
4680
|
FfiConverterTypeConfirmationBlockTime,
|
|
4004
4681
|
FfiConverterTypeDerivationInfo,
|
|
4005
4682
|
FfiConverterTypeDescriptorTemplate,
|
|
4683
|
+
FfiConverterTypeElectrumClient,
|
|
4006
4684
|
FfiConverterTypeKeychainInfo,
|
|
4007
4685
|
FfiConverterTypeKeychainKind,
|
|
4008
4686
|
FfiConverterTypeLanguage,
|
|
@@ -4016,8 +4694,10 @@ var _default = exports.default = Object.freeze({
|
|
|
4016
4694
|
FfiConverterTypeSingleKeyDescriptorTemplate,
|
|
4017
4695
|
FfiConverterTypeTxBuilder,
|
|
4018
4696
|
FfiConverterTypeTxDetails,
|
|
4697
|
+
FfiConverterTypeTxInput,
|
|
4019
4698
|
FfiConverterTypeTxOrdering,
|
|
4020
4699
|
FfiConverterTypeTxOut,
|
|
4700
|
+
FfiConverterTypeTxOutput,
|
|
4021
4701
|
FfiConverterTypeWallet,
|
|
4022
4702
|
FfiConverterTypeWalletEvent,
|
|
4023
4703
|
FfiConverterTypeWordCount
|