6 namespace org { namespace ldk { namespace structs {
12 public class TwoTuple_ThirtyTwoBytesChannelMonitorZ : CommonBase {
13 internal TwoTuple_ThirtyTwoBytesChannelMonitorZ(object _dummy, long ptr) : base(ptr) { }
14 ~TwoTuple_ThirtyTwoBytesChannelMonitorZ() {
15 if (ptr != 0) { bindings.C2Tuple_ThirtyTwoBytesChannelMonitorZ_free(ptr); }
21 public byte[] get_a() {
22 long ret = bindings.C2Tuple_ThirtyTwoBytesChannelMonitorZ_get_a(this.ptr);
24 if (ret >= 0 && ret <= 4096) { return null; }
25 byte[] ret_conv = InternalUtils.decodeUint8Array(ret);
32 public ChannelMonitor get_b() {
33 long ret = bindings.C2Tuple_ThirtyTwoBytesChannelMonitorZ_get_b(this.ptr);
35 if (ret >= 0 && ret <= 4096) { return null; }
36 org.ldk.structs.ChannelMonitor ret_hu_conv = null; if (ret < 0 || ret > 4096) { ret_hu_conv = new org.ldk.structs.ChannelMonitor(null, ret); }
37 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(this); };
41 internal long clone_ptr() {
42 long ret = bindings.C2Tuple_ThirtyTwoBytesChannelMonitorZ_clone_ptr(this.ptr);
48 * Creates a new tuple which has the same data as `orig`
49 * but with all dynamically-allocated buffers duplicated in new buffers.
51 public TwoTuple_ThirtyTwoBytesChannelMonitorZ clone() {
52 long ret = bindings.C2Tuple_ThirtyTwoBytesChannelMonitorZ_clone(this.ptr);
54 if (ret >= 0 && ret <= 4096) { return null; }
55 TwoTuple_ThirtyTwoBytesChannelMonitorZ ret_hu_conv = new TwoTuple_ThirtyTwoBytesChannelMonitorZ(null, ret);
56 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(this); };
61 * Creates a new C2Tuple_ThirtyTwoBytesChannelMonitorZ from the contained elements.
63 public static TwoTuple_ThirtyTwoBytesChannelMonitorZ of(byte[] a, org.ldk.structs.ChannelMonitor b) {
64 long ret = bindings.C2Tuple_ThirtyTwoBytesChannelMonitorZ_new(InternalUtils.encodeUint8Array(InternalUtils.check_arr_len(a, 32)), b.ptr);
67 if (ret >= 0 && ret <= 4096) { return null; }
68 TwoTuple_ThirtyTwoBytesChannelMonitorZ ret_hu_conv = new TwoTuple_ThirtyTwoBytesChannelMonitorZ(null, ret);
69 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(ret_hu_conv); };
70 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(b); };