f56cca90d569a01000236546e098cbf054224e15
[ldk-java] / src / main / java / org / ldk / structs / UnsignedChannelUpdate.java
1 package org.ldk.structs;
2
3 import org.ldk.impl.bindings;
4 import org.ldk.enums.*;
5
6 public class UnsignedChannelUpdate extends CommonBase {
7         UnsignedChannelUpdate(Object _dummy, long ptr) { super(ptr); }
8         @Override @SuppressWarnings("deprecation")
9         protected void finalize() throws Throwable {
10                 bindings.UnsignedChannelUpdate_free(ptr); super.finalize();
11         }
12
13         public UnsignedChannelUpdate(UnsignedChannelUpdate orig) {
14                 super(bindings.UnsignedChannelUpdate_clone(orig == null ? 0 : orig.ptr & ~1));
15                 this.ptrs_to.add(orig);
16         }
17
18         public byte[] get_chain_hash(UnsignedChannelUpdate this_ptr) {
19                 byte[] ret = bindings.UnsignedChannelUpdate_get_chain_hash(this_ptr == null ? 0 : this_ptr.ptr & ~1);
20                 this.ptrs_to.add(this_ptr);
21                 return ret;
22         }
23
24         public void set_chain_hash(UnsignedChannelUpdate this_ptr, byte[] val) {
25                 bindings.UnsignedChannelUpdate_set_chain_hash(this_ptr == null ? 0 : this_ptr.ptr & ~1, val);
26                 this.ptrs_to.add(this_ptr);
27         }
28
29         public long get_short_channel_id(UnsignedChannelUpdate this_ptr) {
30                 long ret = bindings.UnsignedChannelUpdate_get_short_channel_id(this_ptr == null ? 0 : this_ptr.ptr & ~1);
31                 this.ptrs_to.add(this_ptr);
32                 return ret;
33         }
34
35         public void set_short_channel_id(UnsignedChannelUpdate this_ptr, long val) {
36                 bindings.UnsignedChannelUpdate_set_short_channel_id(this_ptr == null ? 0 : this_ptr.ptr & ~1, val);
37                 this.ptrs_to.add(this_ptr);
38         }
39
40         public int get_timestamp(UnsignedChannelUpdate this_ptr) {
41                 int ret = bindings.UnsignedChannelUpdate_get_timestamp(this_ptr == null ? 0 : this_ptr.ptr & ~1);
42                 this.ptrs_to.add(this_ptr);
43                 return ret;
44         }
45
46         public void set_timestamp(UnsignedChannelUpdate this_ptr, int val) {
47                 bindings.UnsignedChannelUpdate_set_timestamp(this_ptr == null ? 0 : this_ptr.ptr & ~1, val);
48                 this.ptrs_to.add(this_ptr);
49         }
50
51         public byte get_flags(UnsignedChannelUpdate this_ptr) {
52                 byte ret = bindings.UnsignedChannelUpdate_get_flags(this_ptr == null ? 0 : this_ptr.ptr & ~1);
53                 this.ptrs_to.add(this_ptr);
54                 return ret;
55         }
56
57         public void set_flags(UnsignedChannelUpdate this_ptr, byte val) {
58                 bindings.UnsignedChannelUpdate_set_flags(this_ptr == null ? 0 : this_ptr.ptr & ~1, val);
59                 this.ptrs_to.add(this_ptr);
60         }
61
62         public short get_cltv_expiry_delta(UnsignedChannelUpdate this_ptr) {
63                 short ret = bindings.UnsignedChannelUpdate_get_cltv_expiry_delta(this_ptr == null ? 0 : this_ptr.ptr & ~1);
64                 this.ptrs_to.add(this_ptr);
65                 return ret;
66         }
67
68         public void set_cltv_expiry_delta(UnsignedChannelUpdate this_ptr, short val) {
69                 bindings.UnsignedChannelUpdate_set_cltv_expiry_delta(this_ptr == null ? 0 : this_ptr.ptr & ~1, val);
70                 this.ptrs_to.add(this_ptr);
71         }
72
73         public long get_htlc_minimum_msat(UnsignedChannelUpdate this_ptr) {
74                 long ret = bindings.UnsignedChannelUpdate_get_htlc_minimum_msat(this_ptr == null ? 0 : this_ptr.ptr & ~1);
75                 this.ptrs_to.add(this_ptr);
76                 return ret;
77         }
78
79         public void set_htlc_minimum_msat(UnsignedChannelUpdate this_ptr, long val) {
80                 bindings.UnsignedChannelUpdate_set_htlc_minimum_msat(this_ptr == null ? 0 : this_ptr.ptr & ~1, val);
81                 this.ptrs_to.add(this_ptr);
82         }
83
84         public int get_fee_base_msat(UnsignedChannelUpdate this_ptr) {
85                 int ret = bindings.UnsignedChannelUpdate_get_fee_base_msat(this_ptr == null ? 0 : this_ptr.ptr & ~1);
86                 this.ptrs_to.add(this_ptr);
87                 return ret;
88         }
89
90         public void set_fee_base_msat(UnsignedChannelUpdate this_ptr, int val) {
91                 bindings.UnsignedChannelUpdate_set_fee_base_msat(this_ptr == null ? 0 : this_ptr.ptr & ~1, val);
92                 this.ptrs_to.add(this_ptr);
93         }
94
95         public int get_fee_proportional_millionths(UnsignedChannelUpdate this_ptr) {
96                 int ret = bindings.UnsignedChannelUpdate_get_fee_proportional_millionths(this_ptr == null ? 0 : this_ptr.ptr & ~1);
97                 this.ptrs_to.add(this_ptr);
98                 return ret;
99         }
100
101         public void set_fee_proportional_millionths(UnsignedChannelUpdate this_ptr, int val) {
102                 bindings.UnsignedChannelUpdate_set_fee_proportional_millionths(this_ptr == null ? 0 : this_ptr.ptr & ~1, val);
103                 this.ptrs_to.add(this_ptr);
104         }
105
106         // Skipped UnsignedChannelUpdate_write
107         public UnsignedChannelUpdate(byte[] ser) {
108                 super(bindings.UnsignedChannelUpdate_read(ser));
109         }
110
111 }