Update auto-generated bindings
[ldk-java] / src / main / java / org / ldk / structs / RouteHint.java
1 package org.ldk.structs;
2
3 import org.ldk.impl.bindings;
4 import org.ldk.enums.*;
5 import org.ldk.util.*;
6 import java.util.Arrays;
7
8
9 /**
10  * A list of hops along a payment path terminating with a channel to the recipient.
11  */
12 @SuppressWarnings("unchecked") // We correctly assign various generic arrays
13 public class RouteHint extends CommonBase {
14         RouteHint(Object _dummy, long ptr) { super(ptr); }
15         @Override @SuppressWarnings("deprecation")
16         protected void finalize() throws Throwable {
17                 super.finalize();
18                 if (ptr != 0) { bindings.RouteHint_free(ptr); }
19         }
20
21         /**
22          * Checks if two RouteHints contain equal inner contents.
23          * This ignores pointers and is_owned flags and looks at the values in fields.
24          * Two objects with NULL inner values will be considered "equal" here.
25          */
26         public boolean eq(RouteHint b) {
27                 boolean ret = bindings.RouteHint_eq(this.ptr, b == null ? 0 : b.ptr & ~1);
28                 this.ptrs_to.add(b);
29                 return ret;
30         }
31
32         /**
33          * Creates a copy of the RouteHint
34          */
35         public RouteHint clone() {
36                 long ret = bindings.RouteHint_clone(this.ptr);
37                 RouteHint ret_hu_conv = new RouteHint(null, ret);
38                 ret_hu_conv.ptrs_to.add(this);
39                 return ret_hu_conv;
40         }
41
42 }