X-Git-Url: http://git.bitcoin.ninja/index.cgi?a=blobdiff_plain;ds=sidebyside;f=ts%2Fstructs%2FHolderCommitmentTransaction.mts;h=c34ffcd72464c01fa0a90367ae989c975d10663f;hb=bbf1ef578b7cfe9fc7d3ad8b6626ae6204e370e5;hp=d4b37e3abd9cd3addeeb1b94905b656012a36aa3;hpb=4713fdb1c6821681d17ecde031b77eb43db1308b;p=ldk-java diff --git a/ts/structs/HolderCommitmentTransaction.mts b/ts/structs/HolderCommitmentTransaction.mts index d4b37e3a..c34ffcd7 100644 --- a/ts/structs/HolderCommitmentTransaction.mts +++ b/ts/structs/HolderCommitmentTransaction.mts @@ -66,6 +66,9 @@ import { Result_PaymentPurposeDecodeErrorZ } from '../structs/Result_PaymentPurp import { ClosureReason } from '../structs/ClosureReason.mjs'; import { Option_ClosureReasonZ } from '../structs/Option_ClosureReasonZ.mjs'; import { Result_COption_ClosureReasonZDecodeErrorZ } from '../structs/Result_COption_ClosureReasonZDecodeErrorZ.mjs'; +import { HTLCDestination } from '../structs/HTLCDestination.mjs'; +import { Option_HTLCDestinationZ } from '../structs/Option_HTLCDestinationZ.mjs'; +import { Result_COption_HTLCDestinationZDecodeErrorZ } from '../structs/Result_COption_HTLCDestinationZDecodeErrorZ.mjs'; import { ChannelUpdate } from '../structs/ChannelUpdate.mjs'; import { NetworkUpdate } from '../structs/NetworkUpdate.mjs'; import { Option_NetworkUpdateZ } from '../structs/Option_NetworkUpdateZ.mjs'; @@ -103,7 +106,7 @@ import { TwoTuple_usizeTransactionZ } from '../structs/TwoTuple_usizeTransaction import { Result_NoneChannelMonitorUpdateErrZ } from '../structs/Result_NoneChannelMonitorUpdateErrZ.mjs'; import { HTLCUpdate } from '../structs/HTLCUpdate.mjs'; import { MonitorEvent } from '../structs/MonitorEvent.mjs'; -import { TwoTuple_OutPointCVec_MonitorEventZZ } from '../structs/TwoTuple_OutPointCVec_MonitorEventZZ.mjs'; +import { ThreeTuple_OutPointCVec_MonitorEventZPublicKeyZ } from '../structs/ThreeTuple_OutPointCVec_MonitorEventZPublicKeyZ.mjs'; import { Option_C2Tuple_usizeTransactionZZ } from '../structs/Option_C2Tuple_usizeTransactionZZ.mjs'; import { FixedPenaltyScorer } from '../structs/FixedPenaltyScorer.mjs'; import { Result_FixedPenaltyScorerDecodeErrorZ } from '../structs/Result_FixedPenaltyScorerDecodeErrorZ.mjs'; @@ -137,6 +140,7 @@ import { ChannelInfo } from '../structs/ChannelInfo.mjs'; import { Result_ChannelInfoDecodeErrorZ } from '../structs/Result_ChannelInfoDecodeErrorZ.mjs'; import { RoutingFees } from '../structs/RoutingFees.mjs'; import { Result_RoutingFeesDecodeErrorZ } from '../structs/Result_RoutingFeesDecodeErrorZ.mjs'; +import { Hostname } from '../structs/Hostname.mjs'; import { NetAddress } from '../structs/NetAddress.mjs'; import { NodeAnnouncementInfo } from '../structs/NodeAnnouncementInfo.mjs'; import { Result_NodeAnnouncementInfoDecodeErrorZ } from '../structs/Result_NodeAnnouncementInfoDecodeErrorZ.mjs'; @@ -379,6 +383,24 @@ export class HolderCommitmentTransaction extends CommonBase { bindings.HolderCommitmentTransaction_set_counterparty_sig(this.ptr, bindings.encodeUint8Array(bindings.check_arr_len(val, 64))); } + /** + * All non-dust counterparty HTLC signatures, in the order they appear in the transaction + * + * Returns a copy of the field. + */ + public get_counterparty_htlc_sigs(): Uint8Array[] { + const ret: number = bindings.HolderCommitmentTransaction_get_counterparty_htlc_sigs(this.ptr); + const ret_conv_12_len: number = bindings.getArrayLength(ret); + const ret_conv_12_arr: Uint8Array[] = new Array(ret_conv_12_len).fill(null); + for (var m = 0; m < ret_conv_12_len; m++) { + const ret_conv_12: number = bindings.getU32ArrayElem(ret, m); + const ret_conv_12_conv: Uint8Array = bindings.decodeUint8Array(ret_conv_12); + ret_conv_12_arr[m] = ret_conv_12_conv; + } + bindings.freeWasmMemory(ret) + return ret_conv_12_arr; + } + /** * All non-dust counterparty HTLC signatures, in the order they appear in the transaction */