Update tests to new Tuple mapping API
[ldk-java] / ts / structs / UserConfig.ts
index a4cd7e8ce75a07a268ef7ce7dff1f3e789ef91bf..0e59b8fbb8434f31c286b71a04ffa79c786fcf98 100644 (file)
@@ -18,13 +18,6 @@ import * as bindings from '../bindings' // TODO: figure out location
                         bindings.UserConfig_free(this.ptr);
                     }
                 }
-       public UserConfig clone() {
-               number ret = bindings.UserConfig_clone(this.ptr);
-               const ret_hu_conv: UserConfig = new UserConfig(null, ret);
-               ret_hu_conv.ptrs_to.add(this);
-               return ret_hu_conv;
-       }
-
        public ChannelHandshakeConfig get_own_channel_config() {
                number ret = bindings.UserConfig_get_own_channel_config(this.ptr);
                const ret_hu_conv: ChannelHandshakeConfig = new ChannelHandshakeConfig(null, ret);
@@ -61,8 +54,17 @@ import * as bindings from '../bindings' // TODO: figure out location
                this.ptrs_to.add(val);
        }
 
-       public static UserConfig constructor_new(ChannelHandshakeConfig own_channel_config_arg, ChannelHandshakeLimits peer_channel_config_limits_arg, ChannelConfig channel_options_arg) {
-               number ret = bindings.UserConfig_new(own_channel_config_arg == null ? 0 : own_channel_config_arg.ptr & ~1, peer_channel_config_limits_arg == null ? 0 : peer_channel_config_limits_arg.ptr & ~1, channel_options_arg == null ? 0 : channel_options_arg.ptr & ~1);
+       public boolean get_accept_forwards_to_priv_channels() {
+               boolean ret = bindings.UserConfig_get_accept_forwards_to_priv_channels(this.ptr);
+               return ret;
+       }
+
+       public void set_accept_forwards_to_priv_channels(boolean val) {
+               bindings.UserConfig_set_accept_forwards_to_priv_channels(this.ptr, val);
+       }
+
+       public static UserConfig constructor_new(ChannelHandshakeConfig own_channel_config_arg, ChannelHandshakeLimits peer_channel_config_limits_arg, ChannelConfig channel_options_arg, boolean accept_forwards_to_priv_channels_arg) {
+               number ret = bindings.UserConfig_new(own_channel_config_arg == null ? 0 : own_channel_config_arg.ptr & ~1, peer_channel_config_limits_arg == null ? 0 : peer_channel_config_limits_arg.ptr & ~1, channel_options_arg == null ? 0 : channel_options_arg.ptr & ~1, accept_forwards_to_priv_channels_arg);
                const ret_hu_conv: UserConfig = new UserConfig(null, ret);
                ret_hu_conv.ptrs_to.add(ret_hu_conv);
                ret_hu_conv.ptrs_to.add(own_channel_config_arg);
@@ -71,6 +73,13 @@ import * as bindings from '../bindings' // TODO: figure out location
                return ret_hu_conv;
        }
 
+       public UserConfig clone() {
+               number ret = bindings.UserConfig_clone(this.ptr);
+               const ret_hu_conv: UserConfig = new UserConfig(null, ret);
+               ret_hu_conv.ptrs_to.add(this);
+               return ret_hu_conv;
+       }
+
        public static UserConfig constructor_default() {
                number ret = bindings.UserConfig_default();
                const ret_hu_conv: UserConfig = new UserConfig(null, ret);