[TS] Update auto-generated TS bindings
[ldk-java] / ts / structs / RawInvoice.mts
index 3ed7d64ef75e5d2093fdbdc99c18d844ea60bfe5..af1e8d9d0daead7c2773aa98ee373b01f9d932a9 100644 (file)
@@ -67,6 +67,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';
@@ -104,10 +107,13 @@ 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';
+import { TwoTuple_u64u64Z } from '../structs/TwoTuple_u64u64Z.mjs';
+import { Option_C2Tuple_u64u64ZZ } from '../structs/Option_C2Tuple_u64u64ZZ.mjs';
+import { NodeId } from '../structs/NodeId.mjs';
 import { Record } from '../structs/Record.mjs';
 import { Logger, LoggerInterface } from '../structs/Logger.mjs';
 import { NetworkGraph } from '../structs/NetworkGraph.mjs';
@@ -122,7 +128,6 @@ import { Result_NodeFeaturesDecodeErrorZ } from '../structs/Result_NodeFeaturesD
 import { InvoiceFeatures } from '../structs/InvoiceFeatures.mjs';
 import { Result_InvoiceFeaturesDecodeErrorZ } from '../structs/Result_InvoiceFeaturesDecodeErrorZ.mjs';
 import { Result_ChannelTypeFeaturesDecodeErrorZ } from '../structs/Result_ChannelTypeFeaturesDecodeErrorZ.mjs';
-import { NodeId } from '../structs/NodeId.mjs';
 import { Result_NodeIdDecodeErrorZ } from '../structs/Result_NodeIdDecodeErrorZ.mjs';
 import { Result_COption_NetworkUpdateZDecodeErrorZ } from '../structs/Result_COption_NetworkUpdateZDecodeErrorZ.mjs';
 import { Access, AccessInterface } from '../structs/Access.mjs';
@@ -136,9 +141,12 @@ 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';
+import { NodeAlias } from '../structs/NodeAlias.mjs';
+import { Result_NodeAliasDecodeErrorZ } from '../structs/Result_NodeAliasDecodeErrorZ.mjs';
 import { NodeInfo } from '../structs/NodeInfo.mjs';
 import { Result_NodeInfoDecodeErrorZ } from '../structs/Result_NodeInfoDecodeErrorZ.mjs';
 import { Result_NetworkGraphDecodeErrorZ } from '../structs/Result_NetworkGraphDecodeErrorZ.mjs';
@@ -357,7 +365,7 @@ import * as bindings from '../bindings.mjs'
  */
 export class RawInvoice extends CommonBase {
        /* @internal */
-       public constructor(_dummy: object, ptr: number) {
+       public constructor(_dummy: object, ptr: bigint) {
                super(ptr, bindings.RawInvoice_free);
        }
 
@@ -365,7 +373,7 @@ export class RawInvoice extends CommonBase {
         * data part
         */
        public get_data(): RawDataPart {
-               const ret: number = bindings.RawInvoice_get_data(this.ptr);
+               const ret: bigint = bindings.RawInvoice_get_data(this.ptr);
                const ret_hu_conv: RawDataPart = new RawDataPart(null, ret);
                CommonBase.add_ref_from(ret_hu_conv, this);
                return ret_hu_conv;
@@ -375,7 +383,8 @@ export class RawInvoice extends CommonBase {
         * data part
         */
        public set_data(val: RawDataPart): void {
-               bindings.RawInvoice_set_data(this.ptr, val == null ? 0 : CommonBase.get_ptr_of(val) & ~1);
+               bindings.RawInvoice_set_data(this.ptr, val == null ? 0n : CommonBase.get_ptr_of(val));
+               CommonBase.add_ref_from(this, val);
        }
 
        /**
@@ -384,13 +393,13 @@ export class RawInvoice extends CommonBase {
         * Two objects with NULL inner values will be considered "equal" here.
         */
        public eq(b: RawInvoice): boolean {
-               const ret: boolean = bindings.RawInvoice_eq(this.ptr, b == null ? 0 : CommonBase.get_ptr_of(b) & ~1);
+               const ret: boolean = bindings.RawInvoice_eq(this.ptr, b == null ? 0n : CommonBase.get_ptr_of(b));
                CommonBase.add_ref_from(this, b);
                return ret;
        }
 
-       public clone_ptr(): number {
-               const ret: number = bindings.RawInvoice_clone_ptr(this.ptr);
+       public clone_ptr(): bigint {
+               const ret: bigint = bindings.RawInvoice_clone_ptr(this.ptr);
                return ret;
        }
 
@@ -398,7 +407,7 @@ export class RawInvoice extends CommonBase {
         * Creates a copy of the RawInvoice
         */
        public clone(): RawInvoice {
-               const ret: number = bindings.RawInvoice_clone(this.ptr);
+               const ret: bigint = bindings.RawInvoice_clone(this.ptr);
                const ret_hu_conv: RawInvoice = new RawInvoice(null, ret);
                CommonBase.add_ref_from(ret_hu_conv, this);
                return ret_hu_conv;
@@ -417,7 +426,7 @@ export class RawInvoice extends CommonBase {
         * Note that the return value (or a relevant inner pointer) may be NULL or all-0s to represent None
         */
        public payment_hash(): Sha256 {
-               const ret: number = bindings.RawInvoice_payment_hash(this.ptr);
+               const ret: bigint = bindings.RawInvoice_payment_hash(this.ptr);
                const ret_hu_conv: Sha256 = new Sha256(null, ret);
                CommonBase.add_ref_from(ret_hu_conv, this);
                return ret_hu_conv;
@@ -427,7 +436,7 @@ export class RawInvoice extends CommonBase {
         * Note that the return value (or a relevant inner pointer) may be NULL or all-0s to represent None
         */
        public description(): Description {
-               const ret: number = bindings.RawInvoice_description(this.ptr);
+               const ret: bigint = bindings.RawInvoice_description(this.ptr);
                const ret_hu_conv: Description = new Description(null, ret);
                CommonBase.add_ref_from(ret_hu_conv, this);
                return ret_hu_conv;
@@ -437,7 +446,7 @@ export class RawInvoice extends CommonBase {
         * Note that the return value (or a relevant inner pointer) may be NULL or all-0s to represent None
         */
        public payee_pub_key(): PayeePubKey {
-               const ret: number = bindings.RawInvoice_payee_pub_key(this.ptr);
+               const ret: bigint = bindings.RawInvoice_payee_pub_key(this.ptr);
                const ret_hu_conv: PayeePubKey = new PayeePubKey(null, ret);
                CommonBase.add_ref_from(ret_hu_conv, this);
                return ret_hu_conv;
@@ -447,7 +456,7 @@ export class RawInvoice extends CommonBase {
         * Note that the return value (or a relevant inner pointer) may be NULL or all-0s to represent None
         */
        public description_hash(): Sha256 {
-               const ret: number = bindings.RawInvoice_description_hash(this.ptr);
+               const ret: bigint = bindings.RawInvoice_description_hash(this.ptr);
                const ret_hu_conv: Sha256 = new Sha256(null, ret);
                CommonBase.add_ref_from(ret_hu_conv, this);
                return ret_hu_conv;
@@ -457,7 +466,7 @@ export class RawInvoice extends CommonBase {
         * Note that the return value (or a relevant inner pointer) may be NULL or all-0s to represent None
         */
        public expiry_time(): ExpiryTime {
-               const ret: number = bindings.RawInvoice_expiry_time(this.ptr);
+               const ret: bigint = bindings.RawInvoice_expiry_time(this.ptr);
                const ret_hu_conv: ExpiryTime = new ExpiryTime(null, ret);
                CommonBase.add_ref_from(ret_hu_conv, this);
                return ret_hu_conv;
@@ -467,7 +476,7 @@ export class RawInvoice extends CommonBase {
         * Note that the return value (or a relevant inner pointer) may be NULL or all-0s to represent None
         */
        public min_final_cltv_expiry(): MinFinalCltvExpiry {
-               const ret: number = bindings.RawInvoice_min_final_cltv_expiry(this.ptr);
+               const ret: bigint = bindings.RawInvoice_min_final_cltv_expiry(this.ptr);
                const ret_hu_conv: MinFinalCltvExpiry = new MinFinalCltvExpiry(null, ret);
                CommonBase.add_ref_from(ret_hu_conv, this);
                return ret_hu_conv;
@@ -486,7 +495,7 @@ export class RawInvoice extends CommonBase {
         * Note that the return value (or a relevant inner pointer) may be NULL or all-0s to represent None
         */
        public features(): InvoiceFeatures {
-               const ret: number = bindings.RawInvoice_features(this.ptr);
+               const ret: bigint = bindings.RawInvoice_features(this.ptr);
                const ret_hu_conv: InvoiceFeatures = new InvoiceFeatures(null, ret);
                CommonBase.add_ref_from(ret_hu_conv, this);
                return ret_hu_conv;
@@ -497,7 +506,7 @@ export class RawInvoice extends CommonBase {
                const ret_conv_14_len: number = bindings.getArrayLength(ret);
                const ret_conv_14_arr: PrivateRoute[] = new Array(ret_conv_14_len).fill(null);
                for (var o = 0; o < ret_conv_14_len; o++) {
-                       const ret_conv_14: number = bindings.getU32ArrayElem(ret, o);
+                       const ret_conv_14: bigint = bindings.getU64ArrayElem(ret, o);
                        const ret_conv_14_hu_conv: PrivateRoute = new PrivateRoute(null, ret_conv_14);
                        CommonBase.add_ref_from(ret_conv_14_hu_conv, this);
                        ret_conv_14_arr[o] = ret_conv_14_hu_conv;
@@ -507,7 +516,7 @@ export class RawInvoice extends CommonBase {
        }
 
        public amount_pico_btc(): Option_u64Z {
-               const ret: number = bindings.RawInvoice_amount_pico_btc(this.ptr);
+               const ret: bigint = bindings.RawInvoice_amount_pico_btc(this.ptr);
                const ret_hu_conv: Option_u64Z = Option_u64Z.constr_from_ptr(ret);
                CommonBase.add_ref_from(ret_hu_conv, this);
                return ret_hu_conv;