@secondts/bark-react-native 0.21.0 → 0.22.0
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/README.md +1 -1
- package/cpp/generated/bark.cpp +38 -0
- package/cpp/generated/bark.hpp +2 -0
- package/lib/commonjs/generated/bark-ffi.js.map +1 -1
- package/lib/commonjs/generated/bark.js +84 -1
- package/lib/commonjs/generated/bark.js.map +1 -1
- package/lib/module/generated/bark-ffi.js.map +1 -1
- package/lib/module/generated/bark.js +83 -0
- package/lib/module/generated/bark.js.map +1 -1
- package/lib/typescript/commonjs/src/generated/bark-ffi.d.ts +2 -0
- package/lib/typescript/commonjs/src/generated/bark-ffi.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/generated/bark.d.ts +93 -0
- package/lib/typescript/commonjs/src/generated/bark.d.ts.map +1 -1
- package/lib/typescript/module/src/generated/bark-ffi.d.ts +2 -0
- package/lib/typescript/module/src/generated/bark-ffi.d.ts.map +1 -1
- package/lib/typescript/module/src/generated/bark.d.ts +93 -0
- package/lib/typescript/module/src/generated/bark.d.ts.map +1 -1
- package/package.json +4 -4
- package/src/generated/bark-ffi.ts +7 -0
- package/src/generated/bark.ts +183 -0
package/README.md
CHANGED
|
@@ -60,7 +60,7 @@ npx expo install @secondts/bark-react-native@beta
|
|
|
60
60
|
|
|
61
61
|
```bash
|
|
62
62
|
# Or install a specific beta version
|
|
63
|
-
npx expo install @secondts/bark-react-native@0.
|
|
63
|
+
npx expo install @secondts/bark-react-native@0.22.0
|
|
64
64
|
```
|
|
65
65
|
|
|
66
66
|
For bare React Native projects, use:
|
package/cpp/generated/bark.cpp
CHANGED
|
@@ -452,6 +452,12 @@ extern "C" {
|
|
|
452
452
|
/*handle*/ uint64_t ptr,
|
|
453
453
|
uint64_t amount_sats
|
|
454
454
|
);
|
|
455
|
+
/*handle*/ uint64_t uniffi_bark_ffi_fn_method_wallet_estimate_emergency_exit_fee(
|
|
456
|
+
/*handle*/ uint64_t ptr,
|
|
457
|
+
RustBuffer vtxo_ids,
|
|
458
|
+
RustBuffer fee_rate_sat_per_vb,
|
|
459
|
+
RustBuffer destination
|
|
460
|
+
);
|
|
455
461
|
/*handle*/ uint64_t uniffi_bark_ffi_fn_method_wallet_estimate_lightning_receive_fee(
|
|
456
462
|
/*handle*/ uint64_t ptr,
|
|
457
463
|
uint64_t amount_sats
|
|
@@ -1070,6 +1076,8 @@ extern "C" {
|
|
|
1070
1076
|
);
|
|
1071
1077
|
uint16_t uniffi_bark_ffi_checksum_method_wallet_estimate_board_fee(
|
|
1072
1078
|
);
|
|
1079
|
+
uint16_t uniffi_bark_ffi_checksum_method_wallet_estimate_emergency_exit_fee(
|
|
1080
|
+
);
|
|
1073
1081
|
uint16_t uniffi_bark_ffi_checksum_method_wallet_estimate_lightning_receive_fee(
|
|
1074
1082
|
);
|
|
1075
1083
|
uint16_t uniffi_bark_ffi_checksum_method_wallet_estimate_lightning_send_fee(
|
|
@@ -5080,6 +5088,14 @@ NativeBark::NativeBark(
|
|
|
5080
5088
|
return this->cpp_uniffi_bark_ffi_fn_method_wallet_estimate_board_fee(rt, thisVal, args, count);
|
|
5081
5089
|
}
|
|
5082
5090
|
);
|
|
5091
|
+
props["ubrn_uniffi_bark_ffi_fn_method_wallet_estimate_emergency_exit_fee"] = jsi::Function::createFromHostFunction(
|
|
5092
|
+
rt,
|
|
5093
|
+
jsi::PropNameID::forAscii(rt, "ubrn_uniffi_bark_ffi_fn_method_wallet_estimate_emergency_exit_fee"),
|
|
5094
|
+
4,
|
|
5095
|
+
[this](jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args, size_t count) -> jsi::Value {
|
|
5096
|
+
return this->cpp_uniffi_bark_ffi_fn_method_wallet_estimate_emergency_exit_fee(rt, thisVal, args, count);
|
|
5097
|
+
}
|
|
5098
|
+
);
|
|
5083
5099
|
props["ubrn_uniffi_bark_ffi_fn_method_wallet_estimate_lightning_receive_fee"] = jsi::Function::createFromHostFunction(
|
|
5084
5100
|
rt,
|
|
5085
5101
|
jsi::PropNameID::forAscii(rt, "ubrn_uniffi_bark_ffi_fn_method_wallet_estimate_lightning_receive_fee"),
|
|
@@ -6528,6 +6544,14 @@ NativeBark::NativeBark(
|
|
|
6528
6544
|
return this->cpp_uniffi_bark_ffi_checksum_method_wallet_estimate_board_fee(rt, thisVal, args, count);
|
|
6529
6545
|
}
|
|
6530
6546
|
);
|
|
6547
|
+
props["ubrn_uniffi_bark_ffi_checksum_method_wallet_estimate_emergency_exit_fee"] = jsi::Function::createFromHostFunction(
|
|
6548
|
+
rt,
|
|
6549
|
+
jsi::PropNameID::forAscii(rt, "ubrn_uniffi_bark_ffi_checksum_method_wallet_estimate_emergency_exit_fee"),
|
|
6550
|
+
0,
|
|
6551
|
+
[this](jsi::Runtime &rt, const jsi::Value &thisVal, const jsi::Value *args, size_t count) -> jsi::Value {
|
|
6552
|
+
return this->cpp_uniffi_bark_ffi_checksum_method_wallet_estimate_emergency_exit_fee(rt, thisVal, args, count);
|
|
6553
|
+
}
|
|
6554
|
+
);
|
|
6531
6555
|
props["ubrn_uniffi_bark_ffi_checksum_method_wallet_estimate_lightning_receive_fee"] = jsi::Function::createFromHostFunction(
|
|
6532
6556
|
rt,
|
|
6533
6557
|
jsi::PropNameID::forAscii(rt, "ubrn_uniffi_bark_ffi_checksum_method_wallet_estimate_lightning_receive_fee"),
|
|
@@ -7827,6 +7851,13 @@ jsi::Value NativeBark::cpp_uniffi_bark_ffi_fn_method_wallet_estimate_board_fee(j
|
|
|
7827
7851
|
);
|
|
7828
7852
|
|
|
7829
7853
|
|
|
7854
|
+
return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker, value);
|
|
7855
|
+
}
|
|
7856
|
+
jsi::Value NativeBark::cpp_uniffi_bark_ffi_fn_method_wallet_estimate_emergency_exit_fee(jsi::Runtime& rt, const jsi::Value& thisVal, const jsi::Value* args, size_t count) {
|
|
7857
|
+
auto value = uniffi_bark_ffi_fn_method_wallet_estimate_emergency_exit_fee(uniffi_jsi::Bridging</*handle*/ uint64_t>::fromJs(rt, callInvoker, args[0]), uniffi::bark::Bridging<RustBuffer>::fromJs(rt, callInvoker, args[1]), uniffi::bark::Bridging<RustBuffer>::fromJs(rt, callInvoker, args[2]), uniffi::bark::Bridging<RustBuffer>::fromJs(rt, callInvoker, args[3])
|
|
7858
|
+
);
|
|
7859
|
+
|
|
7860
|
+
|
|
7830
7861
|
return uniffi_jsi::Bridging</*handle*/ uint64_t>::toJs(rt, callInvoker, value);
|
|
7831
7862
|
}
|
|
7832
7863
|
jsi::Value NativeBark::cpp_uniffi_bark_ffi_fn_method_wallet_estimate_lightning_receive_fee(jsi::Runtime& rt, const jsi::Value& thisVal, const jsi::Value* args, size_t count) {
|
|
@@ -9159,6 +9190,13 @@ jsi::Value NativeBark::cpp_uniffi_bark_ffi_checksum_method_wallet_estimate_board
|
|
|
9159
9190
|
);
|
|
9160
9191
|
|
|
9161
9192
|
|
|
9193
|
+
return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
|
|
9194
|
+
}
|
|
9195
|
+
jsi::Value NativeBark::cpp_uniffi_bark_ffi_checksum_method_wallet_estimate_emergency_exit_fee(jsi::Runtime& rt, const jsi::Value& thisVal, const jsi::Value* args, size_t count) {
|
|
9196
|
+
auto value = uniffi_bark_ffi_checksum_method_wallet_estimate_emergency_exit_fee(
|
|
9197
|
+
);
|
|
9198
|
+
|
|
9199
|
+
|
|
9162
9200
|
return uniffi_jsi::Bridging<uint16_t>::toJs(rt, callInvoker, value);
|
|
9163
9201
|
}
|
|
9164
9202
|
jsi::Value NativeBark::cpp_uniffi_bark_ffi_checksum_method_wallet_estimate_lightning_receive_fee(jsi::Runtime& rt, const jsi::Value& thisVal, const jsi::Value* args, size_t count) {
|
package/cpp/generated/bark.hpp
CHANGED
|
@@ -80,6 +80,7 @@ class NativeBark : public jsi::HostObject {
|
|
|
80
80
|
jsi::Value cpp_uniffi_bark_ffi_fn_method_wallet_drain_exits(jsi::Runtime& rt, const jsi::Value& thisVal, const jsi::Value* args, size_t count);
|
|
81
81
|
jsi::Value cpp_uniffi_bark_ffi_fn_method_wallet_estimate_arkoor_payment_fee(jsi::Runtime& rt, const jsi::Value& thisVal, const jsi::Value* args, size_t count);
|
|
82
82
|
jsi::Value cpp_uniffi_bark_ffi_fn_method_wallet_estimate_board_fee(jsi::Runtime& rt, const jsi::Value& thisVal, const jsi::Value* args, size_t count);
|
|
83
|
+
jsi::Value cpp_uniffi_bark_ffi_fn_method_wallet_estimate_emergency_exit_fee(jsi::Runtime& rt, const jsi::Value& thisVal, const jsi::Value* args, size_t count);
|
|
83
84
|
jsi::Value cpp_uniffi_bark_ffi_fn_method_wallet_estimate_lightning_receive_fee(jsi::Runtime& rt, const jsi::Value& thisVal, const jsi::Value* args, size_t count);
|
|
84
85
|
jsi::Value cpp_uniffi_bark_ffi_fn_method_wallet_estimate_lightning_send_fee(jsi::Runtime& rt, const jsi::Value& thisVal, const jsi::Value* args, size_t count);
|
|
85
86
|
jsi::Value cpp_uniffi_bark_ffi_fn_method_wallet_estimate_offboard_all_fee(jsi::Runtime& rt, const jsi::Value& thisVal, const jsi::Value* args, size_t count);
|
|
@@ -261,6 +262,7 @@ class NativeBark : public jsi::HostObject {
|
|
|
261
262
|
jsi::Value cpp_uniffi_bark_ffi_checksum_method_wallet_drain_exits(jsi::Runtime& rt, const jsi::Value& thisVal, const jsi::Value* args, size_t count);
|
|
262
263
|
jsi::Value cpp_uniffi_bark_ffi_checksum_method_wallet_estimate_arkoor_payment_fee(jsi::Runtime& rt, const jsi::Value& thisVal, const jsi::Value* args, size_t count);
|
|
263
264
|
jsi::Value cpp_uniffi_bark_ffi_checksum_method_wallet_estimate_board_fee(jsi::Runtime& rt, const jsi::Value& thisVal, const jsi::Value* args, size_t count);
|
|
265
|
+
jsi::Value cpp_uniffi_bark_ffi_checksum_method_wallet_estimate_emergency_exit_fee(jsi::Runtime& rt, const jsi::Value& thisVal, const jsi::Value* args, size_t count);
|
|
264
266
|
jsi::Value cpp_uniffi_bark_ffi_checksum_method_wallet_estimate_lightning_receive_fee(jsi::Runtime& rt, const jsi::Value& thisVal, const jsi::Value* args, size_t count);
|
|
265
267
|
jsi::Value cpp_uniffi_bark_ffi_checksum_method_wallet_estimate_lightning_send_fee(jsi::Runtime& rt, const jsi::Value& thisVal, const jsi::Value* args, size_t count);
|
|
266
268
|
jsi::Value cpp_uniffi_bark_ffi_checksum_method_wallet_estimate_offboard_all_fee(jsi::Runtime& rt, const jsi::Value& thisVal, const jsi::Value* args, size_t count);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["getter","globalThis","NativeBark","_default","exports","default","isRustFutureContinuationCallbackTypeCompatible","isUniffiForeignFutureTypeCompatible"],"sourceRoot":"../../../src","sources":["generated/bark-ffi.ts"],"mappings":";;;;;;AAAA;AACA;;AAEA;AACA;AACA;;
|
|
1
|
+
{"version":3,"names":["getter","globalThis","NativeBark","_default","exports","default","isRustFutureContinuationCallbackTypeCompatible","isUniffiForeignFutureTypeCompatible"],"sourceRoot":"../../../src","sources":["generated/bark-ffi.ts"],"mappings":";;;;;;AAAA;AACA;;AAEA;AACA;AACA;;AA+zBA;AACA;AACA;AACA;AACA;AACA,MAAMA,MAAmC,GAAGA,CAAA,KACzCC,UAAU,CAASC,UAAU;AAAC,IAAAC,QAAA,GAAAC,OAAA,CAAAC,OAAA,GAClBL,MAAM,EAErB;AAwKA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,MAAMM,8CAGL,GAAG,IAAI;AACR,MAAMC,mCAGL,GAAG,IAAI","ignoreList":[]}
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
exports.default = exports.WalletTransaction = exports.WalletProperties = exports.WalletOpenArgs = exports.WalletNotification_Tags = exports.WalletNotification = exports.Wallet = exports.VtxoState_Tags = exports.VtxoState = exports.VtxoLockHolder_Tags = exports.VtxoLockHolder = exports.Vtxo = exports.RoundState = exports.RefreshFees = exports.RecoveryReport = exports.RecoveryBucket = exports.PpmExpiryFeeEntry = exports.PendingBoard = exports.OutPoint = exports.OnchainWallet = exports.OnchainUtxo_Tags = exports.OnchainUtxo = exports.OnchainBalance = exports.OffboardResult = exports.OffboardFees = exports.NotificationHolder = exports.Network = exports.Movement = exports.LogLevel = exports.LightningSendStatus_Tags = exports.LightningSendStatus = exports.LightningSendFees = exports.LightningSend = exports.LightningReceiveFees = exports.LightningReceive = exports.LightningInvoice = exports.FeeSchedule = exports.FeeRates = exports.FeeEstimate = exports.ExitVtxo = exports.ExitTxStatus_Tags = exports.ExitTxStatus = exports.ExitTxOrigin_Tags = exports.ExitTxOrigin = exports.ExitTx = exports.ExitTransactionStatus = exports.ExitState_Tags = exports.ExitStateKind = exports.ExitState = exports.ExitProgressStatus = exports.ExitClaimTransaction = exports.ExitCancelResult = exports.ExitCancelFailure_Tags = exports.ExitCancelFailure = exports.Exception_Tags = exports.Exception = exports.Destination = exports.CustomOnchainWalletCallbacksImpl = exports.CpfpParams = exports.Config = exports.BoardFundingInfo = exports.BoardFees = exports.BlockRef = exports.BarkLoggerImpl = exports.Balance = exports.ArkInfo = exports.AddressWithIndex = void 0;
|
|
6
|
+
exports.default = exports.WalletTransaction = exports.WalletProperties = exports.WalletOpenArgs = exports.WalletNotification_Tags = exports.WalletNotification = exports.Wallet = exports.VtxoState_Tags = exports.VtxoState = exports.VtxoLockHolder_Tags = exports.VtxoLockHolder = exports.Vtxo = exports.RoundState = exports.RefreshFees = exports.RecoveryReport = exports.RecoveryBucket = exports.PpmExpiryFeeEntry = exports.PendingBoard = exports.OutPoint = exports.OnchainWallet = exports.OnchainUtxo_Tags = exports.OnchainUtxo = exports.OnchainBalance = exports.OffboardResult = exports.OffboardFees = exports.NotificationHolder = exports.Network = exports.Movement = exports.LogLevel = exports.LightningSendStatus_Tags = exports.LightningSendStatus = exports.LightningSendFees = exports.LightningSend = exports.LightningReceiveFees = exports.LightningReceive = exports.LightningInvoice = exports.FeeSchedule = exports.FeeRates = exports.FeeEstimate = exports.ExitVtxo = exports.ExitTxStatus_Tags = exports.ExitTxStatus = exports.ExitTxOrigin_Tags = exports.ExitTxOrigin = exports.ExitTx = exports.ExitTransactionStatus = exports.ExitState_Tags = exports.ExitStateKind = exports.ExitState = exports.ExitProgressStatus = exports.ExitClaimTransaction = exports.ExitCancelResult = exports.ExitCancelFailure_Tags = exports.ExitCancelFailure = exports.Exception_Tags = exports.Exception = exports.EmergencyExitFeeEstimate = exports.Destination = exports.CustomOnchainWalletCallbacksImpl = exports.CpfpParams = exports.Config = exports.BoardFundingInfo = exports.BoardFees = exports.BlockRef = exports.BarkLoggerImpl = exports.Balance = exports.ArkInfo = exports.AddressWithIndex = void 0;
|
|
7
7
|
exports.extractTxFromPsbt = extractTxFromPsbt;
|
|
8
8
|
exports.generateMnemonic = generateMnemonic;
|
|
9
9
|
exports.initWallet = initWallet;
|
|
@@ -500,6 +500,57 @@ const FfiConverterTypeDestination = (() => {
|
|
|
500
500
|
return new FFIConverter();
|
|
501
501
|
})();
|
|
502
502
|
|
|
503
|
+
/**
|
|
504
|
+
* Estimated onchain cost of unilaterally (emergency) exiting a set of VTXOs.
|
|
505
|
+
*
|
|
506
|
+
* Mirrors bark-rest's `GET /exits/fee` response. The two legs are paid from
|
|
507
|
+
* different pockets: `exit_broadcast_fee_sats` is spent now out of confirmed
|
|
508
|
+
* onchain funds to CPFP-bump every not-yet-confirmed exit transaction, while
|
|
509
|
+
* `claim_fee_sats` is deducted later from the recovered value when the
|
|
510
|
+
* matured outputs are drained.
|
|
511
|
+
*/
|
|
512
|
+
|
|
513
|
+
/**
|
|
514
|
+
* Generated factory for {@link EmergencyExitFeeEstimate} record objects.
|
|
515
|
+
*/
|
|
516
|
+
const EmergencyExitFeeEstimate = exports.EmergencyExitFeeEstimate = (() => {
|
|
517
|
+
const defaults = () => ({});
|
|
518
|
+
const create = (() => {
|
|
519
|
+
return (0, _uniffiBindgenReactNative.uniffiCreateRecord)(defaults);
|
|
520
|
+
})();
|
|
521
|
+
return Object.freeze({
|
|
522
|
+
create,
|
|
523
|
+
new: create,
|
|
524
|
+
defaults: () => Object.freeze(defaults())
|
|
525
|
+
});
|
|
526
|
+
})();
|
|
527
|
+
const FfiConverterTypeEmergencyExitFeeEstimate = (() => {
|
|
528
|
+
class FFIConverter extends _uniffiBindgenReactNative.AbstractFfiConverterByteArray {
|
|
529
|
+
read(from) {
|
|
530
|
+
return {
|
|
531
|
+
exitBroadcastFeeSats: _uniffiBindgenReactNative.FfiConverterUInt64.read(from),
|
|
532
|
+
claimFeeSats: _uniffiBindgenReactNative.FfiConverterUInt64.read(from),
|
|
533
|
+
totalFeeSats: _uniffiBindgenReactNative.FfiConverterUInt64.read(from),
|
|
534
|
+
feeRateSatPerVb: _uniffiBindgenReactNative.FfiConverterUInt64.read(from),
|
|
535
|
+
txsToBroadcast: _uniffiBindgenReactNative.FfiConverterUInt64.read(from),
|
|
536
|
+
fundable: _uniffiBindgenReactNative.FfiConverterBool.read(from)
|
|
537
|
+
};
|
|
538
|
+
}
|
|
539
|
+
write(value, into) {
|
|
540
|
+
_uniffiBindgenReactNative.FfiConverterUInt64.write(value.exitBroadcastFeeSats, into);
|
|
541
|
+
_uniffiBindgenReactNative.FfiConverterUInt64.write(value.claimFeeSats, into);
|
|
542
|
+
_uniffiBindgenReactNative.FfiConverterUInt64.write(value.totalFeeSats, into);
|
|
543
|
+
_uniffiBindgenReactNative.FfiConverterUInt64.write(value.feeRateSatPerVb, into);
|
|
544
|
+
_uniffiBindgenReactNative.FfiConverterUInt64.write(value.txsToBroadcast, into);
|
|
545
|
+
_uniffiBindgenReactNative.FfiConverterBool.write(value.fundable, into);
|
|
546
|
+
}
|
|
547
|
+
allocationSize(value) {
|
|
548
|
+
return _uniffiBindgenReactNative.FfiConverterUInt64.allocationSize(value.exitBroadcastFeeSats) + _uniffiBindgenReactNative.FfiConverterUInt64.allocationSize(value.claimFeeSats) + _uniffiBindgenReactNative.FfiConverterUInt64.allocationSize(value.totalFeeSats) + _uniffiBindgenReactNative.FfiConverterUInt64.allocationSize(value.feeRateSatPerVb) + _uniffiBindgenReactNative.FfiConverterUInt64.allocationSize(value.txsToBroadcast) + _uniffiBindgenReactNative.FfiConverterBool.allocationSize(value.fundable);
|
|
549
|
+
}
|
|
550
|
+
}
|
|
551
|
+
return new FFIConverter();
|
|
552
|
+
})();
|
|
553
|
+
|
|
503
554
|
/**
|
|
504
555
|
* Outcome of a cancellation request.
|
|
505
556
|
*
|
|
@@ -4948,6 +4999,34 @@ class Wallet extends _uniffiBindgenReactNative.UniffiAbstractObject {
|
|
|
4948
4999
|
throw __error;
|
|
4949
5000
|
}
|
|
4950
5001
|
}
|
|
5002
|
+
|
|
5003
|
+
/**
|
|
5004
|
+
* Estimate the onchain cost of unilaterally (emergency) exiting VTXOs.
|
|
5005
|
+
* Mirrors bark-rest `GET /exits/fee`.
|
|
5006
|
+
*
|
|
5007
|
+
* Pass an empty `vtxo_ids` to price exiting the whole wallet (every
|
|
5008
|
+
* spendable VTXO). `fee_rate_sat_per_vb` applies to both legs; omit it to
|
|
5009
|
+
* use the chain's fast rate for the broadcast leg and regular rate for
|
|
5010
|
+
* the claim leg. `destination` only affects the claim transaction's weight.
|
|
5011
|
+
*
|
|
5012
|
+
* The onchain wallet is synced first so `fundable` reflects the current
|
|
5013
|
+
* confirmed balance. Requires a BDK onchain wallet: callback-backed
|
|
5014
|
+
* wallets (`CustomOnchainWalletCallbacks`) cannot simulate the CPFP walk
|
|
5015
|
+
* and return an error.
|
|
5016
|
+
*/
|
|
5017
|
+
async estimateEmergencyExitFee(vtxoIds, feeRateSatPerVb, destination, asyncOpts_) /*throws*/{
|
|
5018
|
+
const __stack = uniffiIsDebug ? new Error().stack : undefined;
|
|
5019
|
+
try {
|
|
5020
|
+
return await (0, _uniffiBindgenReactNative.uniffiRustCallAsync)(/*rustCaller:*/uniffiCaller, /*rustFutureFunc:*/() => {
|
|
5021
|
+
return (0, _barkFfi.default)().ubrn_uniffi_bark_ffi_fn_method_wallet_estimate_emergency_exit_fee(uniffiTypeWalletObjectFactory.clonePointer(this), FfiConverterArrayString.lower(vtxoIds), FfiConverterOptionalUInt64.lower(feeRateSatPerVb), FfiConverterOptionalString.lower(destination));
|
|
5022
|
+
}, /*pollFunc:*/(0, _barkFfi.default)().ubrn_ffi_bark_ffi_rust_future_poll_rust_buffer, /*cancelFunc:*/(0, _barkFfi.default)().ubrn_ffi_bark_ffi_rust_future_cancel_rust_buffer, /*completeFunc:*/(0, _barkFfi.default)().ubrn_ffi_bark_ffi_rust_future_complete_rust_buffer, /*freeFunc:*/(0, _barkFfi.default)().ubrn_ffi_bark_ffi_rust_future_free_rust_buffer, /*liftFunc:*/FfiConverterTypeEmergencyExitFeeEstimate.lift.bind(FfiConverterTypeEmergencyExitFeeEstimate), /*liftString:*/FfiConverterString.lift, /*asyncOpts:*/asyncOpts_, /*errorHandler:*/FfiConverterTypeError.lift.bind(FfiConverterTypeError));
|
|
5023
|
+
} catch (__error) {
|
|
5024
|
+
if (uniffiIsDebug && __error instanceof Error) {
|
|
5025
|
+
__error.stack = __stack;
|
|
5026
|
+
}
|
|
5027
|
+
throw __error;
|
|
5028
|
+
}
|
|
5029
|
+
}
|
|
4951
5030
|
async estimateLightningReceiveFee(amountSats, asyncOpts_) /*throws*/{
|
|
4952
5031
|
const __stack = uniffiIsDebug ? new Error().stack : undefined;
|
|
4953
5032
|
try {
|
|
@@ -6295,6 +6374,9 @@ function uniffiEnsureInitialized() {
|
|
|
6295
6374
|
if ((0, _barkFfi.default)().ubrn_uniffi_bark_ffi_checksum_method_wallet_estimate_board_fee() !== 55967) {
|
|
6296
6375
|
throw new _uniffiBindgenReactNative.UniffiInternalError.ApiChecksumMismatch("uniffi_bark_ffi_checksum_method_wallet_estimate_board_fee");
|
|
6297
6376
|
}
|
|
6377
|
+
if ((0, _barkFfi.default)().ubrn_uniffi_bark_ffi_checksum_method_wallet_estimate_emergency_exit_fee() !== 44713) {
|
|
6378
|
+
throw new _uniffiBindgenReactNative.UniffiInternalError.ApiChecksumMismatch("uniffi_bark_ffi_checksum_method_wallet_estimate_emergency_exit_fee");
|
|
6379
|
+
}
|
|
6298
6380
|
if ((0, _barkFfi.default)().ubrn_uniffi_bark_ffi_checksum_method_wallet_estimate_lightning_receive_fee() !== 33637) {
|
|
6299
6381
|
throw new _uniffiBindgenReactNative.UniffiInternalError.ApiChecksumMismatch("uniffi_bark_ffi_checksum_method_wallet_estimate_lightning_receive_fee");
|
|
6300
6382
|
}
|
|
@@ -6552,6 +6634,7 @@ var _default = exports.default = Object.freeze({
|
|
|
6552
6634
|
FfiConverterTypeCpfpParams,
|
|
6553
6635
|
FfiConverterTypeCustomOnchainWalletCallbacks,
|
|
6554
6636
|
FfiConverterTypeDestination,
|
|
6637
|
+
FfiConverterTypeEmergencyExitFeeEstimate,
|
|
6555
6638
|
FfiConverterTypeError,
|
|
6556
6639
|
FfiConverterTypeExitCancelFailure,
|
|
6557
6640
|
FfiConverterTypeExitCancelResult,
|