@@ -1014,6 +1014,8 @@ internal open class UniffiVTableCallbackInterfaceVssHeaderProvider(
10141014
10151015
10161016
1017+
1018+
10171019
10181020
10191021
@@ -1309,6 +1311,8 @@ internal interface UniffiLib : Library {
13091311 ): RustBuffer .ByValue
13101312 fun uniffi_ldk_node_fn_method_onchainpayment_calculate_cpfp_fee_rate (`ptr`: Pointer ,`parentTxid`: RustBuffer .ByValue ,`urgent`: Byte ,uniffi_out_err : UniffiRustCallStatus ,
13111313 ): Pointer
1314+ fun uniffi_ldk_node_fn_method_onchainpayment_calculate_total_fee (`ptr`: Pointer ,`address`: RustBuffer .ByValue ,`amountSats`: Long ,`feeRate`: RustBuffer .ByValue ,`utxosToSpend`: RustBuffer .ByValue ,uniffi_out_err : UniffiRustCallStatus ,
1315+ ): Long
13121316 fun uniffi_ldk_node_fn_method_onchainpayment_list_spendable_outputs (`ptr`: Pointer ,uniffi_out_err : UniffiRustCallStatus ,
13131317 ): RustBuffer .ByValue
13141318 fun uniffi_ldk_node_fn_method_onchainpayment_new_address (`ptr`: Pointer ,uniffi_out_err : UniffiRustCallStatus ,
@@ -1675,6 +1679,8 @@ internal interface UniffiLib : Library {
16751679 ): Short
16761680 fun uniffi_ldk_node_checksum_method_onchainpayment_calculate_cpfp_fee_rate (
16771681 ): Short
1682+ fun uniffi_ldk_node_checksum_method_onchainpayment_calculate_total_fee (
1683+ ): Short
16781684 fun uniffi_ldk_node_checksum_method_onchainpayment_list_spendable_outputs (
16791685 ): Short
16801686 fun uniffi_ldk_node_checksum_method_onchainpayment_new_address (
@@ -2048,6 +2054,9 @@ private fun uniffiCheckApiChecksums(lib: UniffiLib) {
20482054 if (lib.uniffi_ldk_node_checksum_method_onchainpayment_calculate_cpfp_fee_rate() != 32879 .toShort()) {
20492055 throw RuntimeException (" UniFFI API checksum mismatch: try cleaning and rebuilding your project" )
20502056 }
2057+ if (lib.uniffi_ldk_node_checksum_method_onchainpayment_calculate_total_fee() != 57218 .toShort()) {
2058+ throw RuntimeException (" UniFFI API checksum mismatch: try cleaning and rebuilding your project" )
2059+ }
20512060 if (lib.uniffi_ldk_node_checksum_method_onchainpayment_list_spendable_outputs() != 19144 .toShort()) {
20522061 throw RuntimeException (" UniFFI API checksum mismatch: try cleaning and rebuilding your project" )
20532062 }
@@ -6072,6 +6081,8 @@ public interface OnchainPaymentInterface {
60726081
60736082 fun `calculateCpfpFeeRate` (`parentTxid`: Txid , `urgent`: kotlin.Boolean ): FeeRate
60746083
6084+ fun `calculateTotalFee` (`address`: Address , `amountSats`: kotlin.ULong , `feeRate`: FeeRate ? , `utxosToSpend`: List <SpendableUtxo >? ): kotlin.ULong
6085+
60756086 fun `listSpendableOutputs` (): List <SpendableUtxo >
60766087
60776088 fun `newAddress` (): Address
@@ -6206,6 +6217,19 @@ open class OnchainPayment: Disposable, AutoCloseable, OnchainPaymentInterface {
62066217
62076218
62086219
6220+ @Throws(NodeException ::class )override fun `calculateTotalFee` (`address`: Address , `amountSats`: kotlin.ULong , `feeRate`: FeeRate ? , `utxosToSpend`: List <SpendableUtxo >? ): kotlin.ULong {
6221+ return FfiConverterULong .lift(
6222+ callWithPointer {
6223+ uniffiRustCallWithError(NodeException ) { _status ->
6224+ UniffiLib .INSTANCE .uniffi_ldk_node_fn_method_onchainpayment_calculate_total_fee(
6225+ it, FfiConverterTypeAddress .lower(`address`),FfiConverterULong .lower(`amountSats`),FfiConverterOptionalTypeFeeRate .lower(`feeRate`),FfiConverterOptionalSequenceTypeSpendableUtxo .lower(`utxosToSpend`),_status )
6226+ }
6227+ }
6228+ )
6229+ }
6230+
6231+
6232+
62096233 @Throws(NodeException ::class )override fun `listSpendableOutputs` (): List <SpendableUtxo > {
62106234 return FfiConverterSequenceTypeSpendableUtxo .lift(
62116235 callWithPointer {
0 commit comments