lightningdevkit
Version:
Lightning Development Kit
54 lines (53 loc) • 1.73 kB
text/typescript
import { ChannelId } from '../structs/ChannelId.mjs';
import { Result_UpdateFeeDecodeErrorZ } from '../structs/Result_UpdateFeeDecodeErrorZ.mjs';
import { CommonBase } from './CommonBase.mjs';
/**
* An [`update_fee`] message to be sent to or received from a peer
*
* [`update_fee`]: https://github.com/lightning/bolts/blob/master/02-peer-protocol.md#updating-fees-update_fee
*/
export declare class UpdateFee extends CommonBase {
/**
* The channel ID
*/
get_channel_id(): ChannelId;
/**
* The channel ID
*/
set_channel_id(val: ChannelId): void;
/**
* Fee rate per 1000-weight of the transaction
*/
get_feerate_per_kw(): number;
/**
* Fee rate per 1000-weight of the transaction
*/
set_feerate_per_kw(val: number): void;
/**
* Constructs a new UpdateFee given each field
*/
static constructor_new(channel_id_arg: ChannelId, feerate_per_kw_arg: number): UpdateFee;
clone_ptr(): bigint;
/**
* Creates a copy of the UpdateFee
*/
clone(): UpdateFee;
/**
* Generates a non-cryptographic 64-bit hash of the UpdateFee.
*/
hash(): bigint;
/**
* Checks if two UpdateFees 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: UpdateFee): boolean;
/**
* Serialize the UpdateFee object into a byte array which can be read by UpdateFee_read
*/
write(): Uint8Array;
/**
* Read a UpdateFee from a byte array, created by UpdateFee_write
*/
static constructor_read(ser: Uint8Array): Result_UpdateFeeDecodeErrorZ;
}