UNPKG

lightningdevkit

Version:
45 lines (44 loc) 1.6 kB
import { Type } from '../structs/Type.mjs'; import { Result_RawLSPSMessageDecodeErrorZ } from '../structs/Result_RawLSPSMessageDecodeErrorZ.mjs'; import { CommonBase } from './CommonBase.mjs'; /** * Lightning message type used by LSPS protocols. */ export declare class RawLSPSMessage extends CommonBase { /** * The raw string payload that holds the actual message. */ get_payload(): string; /** * The raw string payload that holds the actual message. */ set_payload(val: string): void; /** * Constructs a new RawLSPSMessage given each field */ static constructor_new(payload_arg: string): RawLSPSMessage; clone_ptr(): bigint; /** * Creates a copy of the RawLSPSMessage */ clone(): RawLSPSMessage; /** * Checks if two RawLSPSMessages 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: RawLSPSMessage): boolean; /** * Serialize the RawLSPSMessage object into a byte array which can be read by RawLSPSMessage_read */ write(): Uint8Array; /** * Read a RawLSPSMessage from a byte array, created by RawLSPSMessage_write */ static constructor_read(ser: Uint8Array): Result_RawLSPSMessageDecodeErrorZ; /** * Constructs a new Type which calls the relevant methods on this_arg. * This copies the `inner` pointer in this_arg and thus the returned Type must be freed before this_arg is */ as_Type(): Type; }