lightningdevkit
Version:
Lightning Development Kit
60 lines • 2.09 kB
JavaScript
import { LSPS1Options } from '../structs/LSPS1Options.mjs';
import { CommonBase } from './CommonBase.mjs';
import * as bindings from '../bindings.mjs';
/**
* A response to a [`LSPS1GetInfoRequest`].
*/
export class LSPS1GetInfoResponse extends CommonBase {
/* @internal */
constructor(_dummy, ptr) {
super(ptr, bindings.LSPS1GetInfoResponse_free);
}
/**
* All options supported by the LSP.
*/
get_options() {
const ret = bindings.LSPS1GetInfoResponse_get_options(this.ptr);
const ret_hu_conv = new LSPS1Options(null, ret);
CommonBase.add_ref_from(ret_hu_conv, this);
return ret_hu_conv;
}
/**
* All options supported by the LSP.
*/
set_options(val) {
bindings.LSPS1GetInfoResponse_set_options(this.ptr, CommonBase.get_ptr_of(val));
}
/**
* Constructs a new LSPS1GetInfoResponse given each field
*/
static constructor_new(options_arg) {
const ret = bindings.LSPS1GetInfoResponse_new(CommonBase.get_ptr_of(options_arg));
const ret_hu_conv = new LSPS1GetInfoResponse(null, ret);
CommonBase.add_ref_from(ret_hu_conv, ret_hu_conv);
return ret_hu_conv;
}
clone_ptr() {
const ret = bindings.LSPS1GetInfoResponse_clone_ptr(this.ptr);
return ret;
}
/**
* Creates a copy of the LSPS1GetInfoResponse
*/
clone() {
const ret = bindings.LSPS1GetInfoResponse_clone(this.ptr);
const ret_hu_conv = new LSPS1GetInfoResponse(null, ret);
CommonBase.add_ref_from(ret_hu_conv, this);
return ret_hu_conv;
}
/**
* Checks if two LSPS1GetInfoResponses contain equal inner contents.
* This ignores pointers and is_owned flags and looks at the values in fields.
* Two objects with NULL inner values will be considered "equal" here.
*/
eq(b) {
const ret = bindings.LSPS1GetInfoResponse_eq(this.ptr, CommonBase.get_ptr_of(b));
CommonBase.add_ref_from(this, b);
return ret;
}
}
//# sourceMappingURL=LSPS1GetInfoResponse.mjs.map