Create structs and traits that are (a bit) more human-friendly!
[ldk-java] / src / main / java / org / ldk / structs / UnsignedNodeAnnouncement.java
1 package org.ldk.structs;
2
3 import org.ldk.impl.bindings;
4 import org.ldk.enums.*;
5
6 public class UnsignedNodeAnnouncement extends CommonBase {
7         UnsignedNodeAnnouncement(Object _dummy, long ptr) { super(ptr); }
8         @Override @SuppressWarnings("deprecation")
9         protected void finalize() throws Throwable {
10                 bindings.UnsignedNodeAnnouncement_free(ptr); super.finalize();
11         }
12
13         public UnsignedNodeAnnouncement(UnsignedNodeAnnouncement orig) {
14                 super(bindings.UnsignedNodeAnnouncement_clone(orig.ptr & ~1));
15                 this.ptrs_to.add(orig);
16         }
17
18         public NodeFeatures get_features(UnsignedNodeAnnouncement this_ptr) {
19                 NodeFeatures ret = new NodeFeatures(null, bindings.UnsignedNodeAnnouncement_get_features(this_ptr.ptr & ~1));
20                 this.ptrs_to.add(this_ptr);
21                 return ret;
22         }
23
24         public void set_features(UnsignedNodeAnnouncement this_ptr, NodeFeatures val) {
25                 bindings.UnsignedNodeAnnouncement_set_features(this_ptr.ptr & ~1, val.ptr & ~1);
26                 this.ptrs_to.add(this_ptr);
27                 this.ptrs_to.add(val);
28         }
29
30         public int get_timestamp(UnsignedNodeAnnouncement this_ptr) {
31                 int ret = bindings.UnsignedNodeAnnouncement_get_timestamp(this_ptr.ptr & ~1);
32                 this.ptrs_to.add(this_ptr);
33                 return ret;
34         }
35
36         public void set_timestamp(UnsignedNodeAnnouncement this_ptr, int val) {
37                 bindings.UnsignedNodeAnnouncement_set_timestamp(this_ptr.ptr & ~1, val);
38                 this.ptrs_to.add(this_ptr);
39         }
40
41         public byte[] get_node_id(UnsignedNodeAnnouncement this_ptr) {
42                 byte[] ret = bindings.UnsignedNodeAnnouncement_get_node_id(this_ptr.ptr & ~1);
43                 this.ptrs_to.add(this_ptr);
44                 return ret;
45         }
46
47         public void set_node_id(UnsignedNodeAnnouncement this_ptr, byte[] val) {
48                 bindings.UnsignedNodeAnnouncement_set_node_id(this_ptr.ptr & ~1, val);
49                 this.ptrs_to.add(this_ptr);
50         }
51
52         public byte[] get_rgb(UnsignedNodeAnnouncement this_ptr) {
53                 byte[] ret = bindings.UnsignedNodeAnnouncement_get_rgb(this_ptr.ptr & ~1);
54                 this.ptrs_to.add(this_ptr);
55                 return ret;
56         }
57
58         // Skipped UnsignedNodeAnnouncement_set_rgb
59         public byte[] get_alias(UnsignedNodeAnnouncement this_ptr) {
60                 byte[] ret = bindings.UnsignedNodeAnnouncement_get_alias(this_ptr.ptr & ~1);
61                 this.ptrs_to.add(this_ptr);
62                 return ret;
63         }
64
65         public void set_alias(UnsignedNodeAnnouncement this_ptr, byte[] val) {
66                 bindings.UnsignedNodeAnnouncement_set_alias(this_ptr.ptr & ~1, val);
67                 this.ptrs_to.add(this_ptr);
68         }
69
70         // Skipped UnsignedNodeAnnouncement_set_addresses
71         // Skipped UnsignedNodeAnnouncement_write
72         // Skipped UnsignedNodeAnnouncement_read
73 }