UNPKG

lightningdevkit

Version:
50 lines 1.76 kB
import { Option_u64Z } from '../structs/Option_u64Z.mjs'; import { CommonBase } from './CommonBase.mjs'; import * as bindings from '../bindings.mjs'; /** * Client-side configuration options for bLIP-51 / LSPS1 channel requests. */ export class LSPS1ClientConfig extends CommonBase { /* @internal */ constructor(_dummy, ptr) { super(ptr, bindings.LSPS1ClientConfig_free); } /** * The maximally allowed channel fees. */ get_max_channel_fees_msat() { const ret = bindings.LSPS1ClientConfig_get_max_channel_fees_msat(this.ptr); const ret_hu_conv = Option_u64Z.constr_from_ptr(ret); CommonBase.add_ref_from(ret_hu_conv, this); return ret_hu_conv; } /** * The maximally allowed channel fees. */ set_max_channel_fees_msat(val) { bindings.LSPS1ClientConfig_set_max_channel_fees_msat(this.ptr, CommonBase.get_ptr_of(val)); } /** * Constructs a new LSPS1ClientConfig given each field */ static constructor_new(max_channel_fees_msat_arg) { const ret = bindings.LSPS1ClientConfig_new(CommonBase.get_ptr_of(max_channel_fees_msat_arg)); const ret_hu_conv = new LSPS1ClientConfig(null, ret); CommonBase.add_ref_from(ret_hu_conv, ret_hu_conv); return ret_hu_conv; } clone_ptr() { const ret = bindings.LSPS1ClientConfig_clone_ptr(this.ptr); return ret; } /** * Creates a copy of the LSPS1ClientConfig */ clone() { const ret = bindings.LSPS1ClientConfig_clone(this.ptr); const ret_hu_conv = new LSPS1ClientConfig(null, ret); CommonBase.add_ref_from(ret_hu_conv, this); return ret_hu_conv; } } //# sourceMappingURL=LSPS1ClientConfig.mjs.map