6 namespace org { namespace ldk { namespace structs {
10 * The minimum and maximum fees which the sender is willing to place on the closing transaction.
12 * This is provided in [`ClosingSigned`] by both sides to indicate the fee range they are willing
15 public class ClosingSignedFeeRange : CommonBase {
16 internal ClosingSignedFeeRange(object _dummy, long ptr) : base(ptr) { }
17 ~ClosingSignedFeeRange() {
18 if (ptr != 0) { bindings.ClosingSignedFeeRange_free(ptr); }
22 * The minimum absolute fee, in satoshis, which the sender is willing to place on the closing
25 public long get_min_fee_satoshis() {
26 long ret = bindings.ClosingSignedFeeRange_get_min_fee_satoshis(this.ptr);
32 * The minimum absolute fee, in satoshis, which the sender is willing to place on the closing
35 public void set_min_fee_satoshis(long val) {
36 bindings.ClosingSignedFeeRange_set_min_fee_satoshis(this.ptr, val);
42 * The maximum absolute fee, in satoshis, which the sender is willing to place on the closing
45 public long get_max_fee_satoshis() {
46 long ret = bindings.ClosingSignedFeeRange_get_max_fee_satoshis(this.ptr);
52 * The maximum absolute fee, in satoshis, which the sender is willing to place on the closing
55 public void set_max_fee_satoshis(long val) {
56 bindings.ClosingSignedFeeRange_set_max_fee_satoshis(this.ptr, val);
62 * Constructs a new ClosingSignedFeeRange given each field
64 public static ClosingSignedFeeRange of(long min_fee_satoshis_arg, long max_fee_satoshis_arg) {
65 long ret = bindings.ClosingSignedFeeRange_new(min_fee_satoshis_arg, max_fee_satoshis_arg);
66 GC.KeepAlive(min_fee_satoshis_arg);
67 GC.KeepAlive(max_fee_satoshis_arg);
68 if (ret >= 0 && ret <= 4096) { return null; }
69 org.ldk.structs.ClosingSignedFeeRange ret_hu_conv = null; if (ret < 0 || ret > 4096) { ret_hu_conv = new org.ldk.structs.ClosingSignedFeeRange(null, ret); }
70 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(ret_hu_conv); };
74 internal long clone_ptr() {
75 long ret = bindings.ClosingSignedFeeRange_clone_ptr(this.ptr);
81 * Creates a copy of the ClosingSignedFeeRange
83 public ClosingSignedFeeRange clone() {
84 long ret = bindings.ClosingSignedFeeRange_clone(this.ptr);
86 if (ret >= 0 && ret <= 4096) { return null; }
87 org.ldk.structs.ClosingSignedFeeRange ret_hu_conv = null; if (ret < 0 || ret > 4096) { ret_hu_conv = new org.ldk.structs.ClosingSignedFeeRange(null, ret); }
88 if (ret_hu_conv != null) { ret_hu_conv.ptrs_to.AddLast(this); };
93 * Checks if two ClosingSignedFeeRanges contain equal inner contents.
94 * This ignores pointers and is_owned flags and looks at the values in fields.
95 * Two objects with NULL inner values will be considered "equal" here.
97 public bool eq(org.ldk.structs.ClosingSignedFeeRange b) {
98 bool ret = bindings.ClosingSignedFeeRange_eq(this.ptr, b == null ? 0 : b.ptr);
101 if (this != null) { this.ptrs_to.AddLast(b); };
105 public override bool Equals(object o) {
106 if (!(o is ClosingSignedFeeRange)) return false;
107 return this.eq((ClosingSignedFeeRange)o);
110 * Serialize the ClosingSignedFeeRange object into a byte array which can be read by ClosingSignedFeeRange_read
112 public byte[] write() {
113 byte[] ret = bindings.ClosingSignedFeeRange_write(this.ptr);
119 * Read a ClosingSignedFeeRange from a byte array, created by ClosingSignedFeeRange_write
121 public static Result_ClosingSignedFeeRangeDecodeErrorZ read(byte[] ser) {
122 long ret = bindings.ClosingSignedFeeRange_read(ser);
124 if (ret >= 0 && ret <= 4096) { return null; }
125 Result_ClosingSignedFeeRangeDecodeErrorZ ret_hu_conv = Result_ClosingSignedFeeRangeDecodeErrorZ.constr_from_ptr(ret);