1 package org.ldk.structs;
3 import org.ldk.impl.bindings;
4 import org.ldk.enums.*;
6 import java.util.Arrays;
8 @SuppressWarnings("unchecked") // We correctly assign various generic arrays
9 public class GossipTimestampFilter extends CommonBase {
10 GossipTimestampFilter(Object _dummy, long ptr) { super(ptr); }
11 @Override @SuppressWarnings("deprecation")
12 protected void finalize() throws Throwable {
14 if (ptr != 0) { bindings.GossipTimestampFilter_free(ptr); }
17 public GossipTimestampFilter clone() {
18 long ret = bindings.GossipTimestampFilter_clone(this.ptr);
19 GossipTimestampFilter ret_hu_conv = new GossipTimestampFilter(null, ret);
23 public byte[] get_chain_hash() {
24 byte[] ret = bindings.GossipTimestampFilter_get_chain_hash(this.ptr);
28 public void set_chain_hash(byte[] val) {
29 bindings.GossipTimestampFilter_set_chain_hash(this.ptr, val);
32 public int get_first_timestamp() {
33 int ret = bindings.GossipTimestampFilter_get_first_timestamp(this.ptr);
37 public void set_first_timestamp(int val) {
38 bindings.GossipTimestampFilter_set_first_timestamp(this.ptr, val);
41 public int get_timestamp_range() {
42 int ret = bindings.GossipTimestampFilter_get_timestamp_range(this.ptr);
46 public void set_timestamp_range(int val) {
47 bindings.GossipTimestampFilter_set_timestamp_range(this.ptr, val);
50 public static GossipTimestampFilter constructor_new(byte[] chain_hash_arg, int first_timestamp_arg, int timestamp_range_arg) {
51 long ret = bindings.GossipTimestampFilter_new(chain_hash_arg, first_timestamp_arg, timestamp_range_arg);
52 GossipTimestampFilter ret_hu_conv = new GossipTimestampFilter(null, ret);
56 public static Result_GossipTimestampFilterDecodeErrorZ constructor_read(byte[] ser) {
57 long ret = bindings.GossipTimestampFilter_read(ser);
58 Result_GossipTimestampFilterDecodeErrorZ ret_hu_conv = Result_GossipTimestampFilterDecodeErrorZ.constr_from_ptr(ret);
62 public byte[] write() {
63 byte[] ret = bindings.GossipTimestampFilter_write(this.ptr);