X-Git-Url: http://git.bitcoin.ninja/index.cgi?a=blobdiff_plain;f=src%2Fmain%2Fjava%2Forg%2Fldk%2Fstructs%2FChannelHandshakeConfig.java;h=730d50adb2618cd4932ad8ab51c166fa574003d1;hb=36e18c10580824f746164804e16e7f8a7dafd61d;hp=98578edcf2afbdeb253108b464cb024b23b90575;hpb=aa0e2aade37133339f4113a0cd7465b111f0a0d0;p=ldk-java diff --git a/src/main/java/org/ldk/structs/ChannelHandshakeConfig.java b/src/main/java/org/ldk/structs/ChannelHandshakeConfig.java index 98578edc..730d50ad 100644 --- a/src/main/java/org/ldk/structs/ChannelHandshakeConfig.java +++ b/src/main/java/org/ldk/structs/ChannelHandshakeConfig.java @@ -14,13 +14,6 @@ public class ChannelHandshakeConfig extends CommonBase { if (ptr != 0) { bindings.ChannelHandshakeConfig_free(ptr); } } - public static ChannelHandshakeConfig constructor_clone(ChannelHandshakeConfig orig) { - long ret = bindings.ChannelHandshakeConfig_clone(orig == null ? 0 : orig.ptr & ~1); - ChannelHandshakeConfig ret_hu_conv = new ChannelHandshakeConfig(null, ret); - ret_hu_conv.ptrs_to.add(orig); - return ret_hu_conv; - } - public int get_minimum_depth() { int ret = bindings.ChannelHandshakeConfig_get_minimum_depth(this.ptr); return ret; @@ -51,12 +44,21 @@ public class ChannelHandshakeConfig extends CommonBase { public static ChannelHandshakeConfig constructor_new(int minimum_depth_arg, short our_to_self_delay_arg, long our_htlc_minimum_msat_arg) { long ret = bindings.ChannelHandshakeConfig_new(minimum_depth_arg, our_to_self_delay_arg, our_htlc_minimum_msat_arg); ChannelHandshakeConfig ret_hu_conv = new ChannelHandshakeConfig(null, ret); + ret_hu_conv.ptrs_to.add(ret_hu_conv); + return ret_hu_conv; + } + + public ChannelHandshakeConfig clone() { + long ret = bindings.ChannelHandshakeConfig_clone(this.ptr); + ChannelHandshakeConfig ret_hu_conv = new ChannelHandshakeConfig(null, ret); + ret_hu_conv.ptrs_to.add(this); return ret_hu_conv; } public static ChannelHandshakeConfig constructor_default() { long ret = bindings.ChannelHandshakeConfig_default(); ChannelHandshakeConfig ret_hu_conv = new ChannelHandshakeConfig(null, ret); + ret_hu_conv.ptrs_to.add(ret_hu_conv); return ret_hu_conv; }