+ /**
+ * Utility method to constructs a new DangerousValue-variant DecodeError
+ */
+ public static DecodeError dangerous_value() {
+ long ret = bindings.DecodeError_dangerous_value();
+ if (ret >= 0 && ret <= 4096) { return null; }
+ org.ldk.structs.DecodeError ret_hu_conv = org.ldk.structs.DecodeError.constr_from_ptr(ret);
+ if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.add(ret_hu_conv); };
+ return ret_hu_conv;
+ }
+
+ /**
+ * Generates a non-cryptographic 64-bit hash of the DecodeError.
+ */
+ public long hash() {
+ long ret = bindings.DecodeError_hash(this.ptr);
+ Reference.reachabilityFence(this);
+ return ret;
+ }
+
+ @Override public int hashCode() {
+ return (int)this.hash();
+ }