UNPKG

xud

Version:
19 lines (18 loc) 736 B
import Packet, { PacketDirection, ResponseType } from '../Packet'; import PacketType from '../PacketType'; import { DisconnectionReason } from '../../../constants/enums'; import * as pb from '../../../proto/xudp2p_pb'; export declare type DisconnectingPacketBody = { reason: DisconnectionReason; payload?: string; }; declare class DisconnectingPacket extends Packet<DisconnectingPacketBody> { get type(): PacketType; get direction(): PacketDirection; get responseType(): ResponseType; static deserialize: (binary: Uint8Array) => DisconnectingPacket | pb.DisconnectingPacket.AsObject; private static validate; private static convert; serialize: () => Uint8Array; } export default DisconnectingPacket;