import { BufWrapper } from '@minecraft-js/bufwrapper'; import { RCONPacketType } from '../util/PacketType'; export declare class RCONPacket { /** * Type of the packet * @see https://wiki.vg/RCON#Packets */ type: RCONPacketType; /** Payload of the packet */ payload: string; /** BufWrapper instance that wraps the buffer for this packet */ buf: BufWrapper; /** * Read or write a packet * @param buf Buffer to create the packet from, can be `undefined` if you are building a packet */ constructor(buf?: BufWrapper); /** * Write the data to the packet * @param type Type of the RCONPacket * @param payload Payload for this packet */ write(type?: RCONPacketType, payload?: string): void; /** * Read the packet content */ read(type: RCONPacketType): RCONPacket; /** Maximum client to server packet length */ static readonly MAX_CLIENT_PAYLOAD_LENGTH = 1460; /** Maximum server to client packet length */ static readonly MAX_SERVER_PAYLOAD_LENGTH = 4110; }