[C#] Update auto-generated C# bindings
[ldk-java] / c_sharp / src / org / ldk / structs / UpdateFailHTLC.cs
index 2c29d8857fbd437a324e13426d0ab046873a848c..78ff71d344ddee8b5c2ed7e5199eb191b5cd3ec9 100644 (file)
@@ -21,16 +21,18 @@ public class UpdateFailHTLC : CommonBase {
         * The channel ID
         */
        public byte[] get_channel_id() {
-               byte[] ret = bindings.UpdateFailHTLC_get_channel_id(this.ptr);
+               long ret = bindings.UpdateFailHTLC_get_channel_id(this.ptr);
                GC.KeepAlive(this);
-               return ret;
+               if (ret >= 0 && ret <= 4096) { return null; }
+               byte[] ret_conv = InternalUtils.decodeUint8Array(ret);
+               return ret_conv;
        }
 
        /**
         * The channel ID
         */
        public void set_channel_id(byte[] val) {
-               bindings.UpdateFailHTLC_set_channel_id(this.ptr, InternalUtils.check_arr_len(val, 32));
+               bindings.UpdateFailHTLC_set_channel_id(this.ptr, InternalUtils.encodeUint8Array(InternalUtils.check_arr_len(val, 32)));
                GC.KeepAlive(this);
                GC.KeepAlive(val);
        }
@@ -92,16 +94,18 @@ public class UpdateFailHTLC : CommonBase {
         * Serialize the UpdateFailHTLC object into a byte array which can be read by UpdateFailHTLC_read
         */
        public byte[] write() {
-               byte[] ret = bindings.UpdateFailHTLC_write(this.ptr);
+               long ret = bindings.UpdateFailHTLC_write(this.ptr);
                GC.KeepAlive(this);
-               return ret;
+               if (ret >= 0 && ret <= 4096) { return null; }
+               byte[] ret_conv = InternalUtils.decodeUint8Array(ret);
+               return ret_conv;
        }
 
        /**
         * Read a UpdateFailHTLC from a byte array, created by UpdateFailHTLC_write
         */
        public static Result_UpdateFailHTLCDecodeErrorZ read(byte[] ser) {
-               long ret = bindings.UpdateFailHTLC_read(ser);
+               long ret = bindings.UpdateFailHTLC_read(InternalUtils.encodeUint8Array(ser));
                GC.KeepAlive(ser);
                if (ret >= 0 && ret <= 4096) { return null; }
                Result_UpdateFailHTLCDecodeErrorZ ret_hu_conv = Result_UpdateFailHTLCDecodeErrorZ.constr_from_ptr(ret);