+ super.finalize();
+ if (ptr != 0) { bindings.Shutdown_free(ptr); }
+ }
+
+ /**
+ * The channel ID
+ */
+ public byte[] get_channel_id() {
+ byte[] ret = bindings.Shutdown_get_channel_id(this.ptr);
+ return ret;
+ }
+
+ /**
+ * The channel ID
+ */
+ public void set_channel_id(byte[] val) {
+ bindings.Shutdown_set_channel_id(this.ptr, InternalUtils.check_arr_len(val, 32));
+ }
+
+ /**
+ * The destination of this peer's funds on closing.
+ * Must be in one of these forms: p2pkh, p2sh, p2wpkh, p2wsh.
+ */
+ public byte[] get_scriptpubkey() {
+ byte[] ret = bindings.Shutdown_get_scriptpubkey(this.ptr);
+ return ret;
+ }
+
+ /**
+ * The destination of this peer's funds on closing.
+ * Must be in one of these forms: p2pkh, p2sh, p2wpkh, p2wsh.
+ */
+ public void set_scriptpubkey(byte[] val) {
+ bindings.Shutdown_set_scriptpubkey(this.ptr, val);
+ }
+
+ /**
+ * Constructs a new Shutdown given each field
+ */
+ public static Shutdown of(byte[] channel_id_arg, byte[] scriptpubkey_arg) {
+ long ret = bindings.Shutdown_new(InternalUtils.check_arr_len(channel_id_arg, 32), scriptpubkey_arg);
+ if (ret >= 0 && ret <= 4096) { return null; }
+ Shutdown ret_hu_conv = null; if (ret < 0 || ret > 4096) { ret_hu_conv = new Shutdown(null, ret); }
+ ret_hu_conv.ptrs_to.add(ret_hu_conv);
+ return ret_hu_conv;
+ }
+
+ long clone_ptr() {
+ long ret = bindings.Shutdown_clone_ptr(this.ptr);
+ return ret;