Update auto-generated bindings to 0.0.103
[ldk-java] / src / main / java / org / ldk / structs / TwoTuple_u32TxOutZ.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 import javax.annotation.Nullable;
8
9
10 /**
11  * A Tuple
12  */
13 @SuppressWarnings("unchecked") // We correctly assign various generic arrays
14 public class TwoTuple_u32TxOutZ extends CommonBase {
15         TwoTuple_u32TxOutZ(Object _dummy, long ptr) { super(ptr); }
16         @Override @SuppressWarnings("deprecation")
17         protected void finalize() throws Throwable {
18                 super.finalize();
19                 if (ptr != 0) { bindings.C2Tuple_u32TxOutZ_free(ptr); }
20         }
21
22         /**
23          * 
24          */
25         public int get_a() {
26                 int ret = bindings.C2Tuple_u32TxOutZ_get_a(this.ptr);
27                 return ret;
28         }
29
30         /**
31          * 
32          */
33         public TxOut get_b() {
34                 long ret = bindings.C2Tuple_u32TxOutZ_get_b(this.ptr);
35                 if (ret >= 0 && ret <= 4096) { return null; }
36                 TxOut ret_conv = new TxOut(null, ret);
37                 return ret_conv;
38         }
39
40         /**
41          * Creates a new tuple which has the same data as `orig`
42          * but with all dynamically-allocated buffers duplicated in new buffers.
43          */
44         public TwoTuple_u32TxOutZ clone() {
45                 long ret = bindings.C2Tuple_u32TxOutZ_clone(this.ptr);
46                 if (ret >= 0 && ret <= 4096) { return null; }
47                 TwoTuple_u32TxOutZ ret_hu_conv = new TwoTuple_u32TxOutZ(null, ret);
48                 ret_hu_conv.ptrs_to.add(this);
49                 return ret_hu_conv;
50         }
51
52         /**
53          * Creates a new C2Tuple_u32TxOutZ from the contained elements.
54          */
55         public static TwoTuple_u32TxOutZ of(int a, TxOut b) {
56                 long ret = bindings.C2Tuple_u32TxOutZ_new(a, b.ptr);
57                 if (ret >= 0 && ret <= 4096) { return null; }
58                 TwoTuple_u32TxOutZ ret_hu_conv = new TwoTuple_u32TxOutZ(null, ret);
59                 ret_hu_conv.ptrs_to.add(ret_hu_conv);
60                 return ret_hu_conv;
61         }
62
63 }