UNPKG

irctokens

Version:
22 lines (21 loc) 652 B
import { Hostmask } from './hostmask'; import type { TextEncodingLabel } from '.'; export interface LineArgs { tags?: Record<string, string>; source?: string; command: string; params: string[]; } export declare class Line { #private; tags?: Record<string, string>; source?: string; command: string; params: string[]; constructor({ tags, source, command, params }: LineArgs); get hostmask(): Hostmask; format(): string; withSource(source: string): Line; copy(): Line; } export declare function tokenise(line: string | Uint8Array, encoding?: TextEncodingLabel, fallback?: TextEncodingLabel): Line;