Create structs and traits that are (a bit) more human-friendly!
[ldk-java] / src / main / java / org / ldk / structs / ChannelPublicKeys.java
1 package org.ldk.structs;
2
3 import org.ldk.impl.bindings;
4 import org.ldk.enums.*;
5
6 public class ChannelPublicKeys extends CommonBase {
7         ChannelPublicKeys(Object _dummy, long ptr) { super(ptr); }
8         @Override @SuppressWarnings("deprecation")
9         protected void finalize() throws Throwable {
10                 bindings.ChannelPublicKeys_free(ptr); super.finalize();
11         }
12
13         public ChannelPublicKeys(ChannelPublicKeys orig) {
14                 super(bindings.ChannelPublicKeys_clone(orig.ptr & ~1));
15                 this.ptrs_to.add(orig);
16         }
17
18         public byte[] get_funding_pubkey(ChannelPublicKeys this_ptr) {
19                 byte[] ret = bindings.ChannelPublicKeys_get_funding_pubkey(this_ptr.ptr & ~1);
20                 this.ptrs_to.add(this_ptr);
21                 return ret;
22         }
23
24         public void set_funding_pubkey(ChannelPublicKeys this_ptr, byte[] val) {
25                 bindings.ChannelPublicKeys_set_funding_pubkey(this_ptr.ptr & ~1, val);
26                 this.ptrs_to.add(this_ptr);
27         }
28
29         public byte[] get_revocation_basepoint(ChannelPublicKeys this_ptr) {
30                 byte[] ret = bindings.ChannelPublicKeys_get_revocation_basepoint(this_ptr.ptr & ~1);
31                 this.ptrs_to.add(this_ptr);
32                 return ret;
33         }
34
35         public void set_revocation_basepoint(ChannelPublicKeys this_ptr, byte[] val) {
36                 bindings.ChannelPublicKeys_set_revocation_basepoint(this_ptr.ptr & ~1, val);
37                 this.ptrs_to.add(this_ptr);
38         }
39
40         public byte[] get_payment_point(ChannelPublicKeys this_ptr) {
41                 byte[] ret = bindings.ChannelPublicKeys_get_payment_point(this_ptr.ptr & ~1);
42                 this.ptrs_to.add(this_ptr);
43                 return ret;
44         }
45
46         public void set_payment_point(ChannelPublicKeys this_ptr, byte[] val) {
47                 bindings.ChannelPublicKeys_set_payment_point(this_ptr.ptr & ~1, val);
48                 this.ptrs_to.add(this_ptr);
49         }
50
51         public byte[] get_delayed_payment_basepoint(ChannelPublicKeys this_ptr) {
52                 byte[] ret = bindings.ChannelPublicKeys_get_delayed_payment_basepoint(this_ptr.ptr & ~1);
53                 this.ptrs_to.add(this_ptr);
54                 return ret;
55         }
56
57         public void set_delayed_payment_basepoint(ChannelPublicKeys this_ptr, byte[] val) {
58                 bindings.ChannelPublicKeys_set_delayed_payment_basepoint(this_ptr.ptr & ~1, val);
59                 this.ptrs_to.add(this_ptr);
60         }
61
62         public byte[] get_htlc_basepoint(ChannelPublicKeys this_ptr) {
63                 byte[] ret = bindings.ChannelPublicKeys_get_htlc_basepoint(this_ptr.ptr & ~1);
64                 this.ptrs_to.add(this_ptr);
65                 return ret;
66         }
67
68         public void set_htlc_basepoint(ChannelPublicKeys this_ptr, byte[] val) {
69                 bindings.ChannelPublicKeys_set_htlc_basepoint(this_ptr.ptr & ~1, val);
70                 this.ptrs_to.add(this_ptr);
71         }
72
73         public ChannelPublicKeys(byte[] funding_pubkey_arg, byte[] revocation_basepoint_arg, byte[] payment_point_arg, byte[] delayed_payment_basepoint_arg, byte[] htlc_basepoint_arg) {
74                 super(bindings.ChannelPublicKeys_new(funding_pubkey_arg, revocation_basepoint_arg, payment_point_arg, delayed_payment_basepoint_arg, htlc_basepoint_arg));
75         }
76
77         // Skipped ChannelPublicKeys_write
78         // Skipped ChannelPublicKeys_read
79 }