ProtocolHandler
import { ProtocolHandler } from "https://raw.githubusercontent.com/nats-io/nats.deno/v1.28.2/nats-base-client/internal_mod.ts";
class ProtocolHandler implements Dispatcher<ParserEvent> { }
_closed: boolean;
abortReconnect: boolean;
closed: Deferred<Error | void>;
connected: boolean;
connectedOnce: boolean;
connectError?: (err?: Error) => void;
connectPromise: Promise<void> | null;
features: Features;
heartbeats: Heartbeat;
inBytes: number;
info?: ServerInfo;
infoReceived: boolean;
inMsgs: number;
lastError?: NatsError;
listeners: QueuedIterator<Status>[];
muxSubscriptions: MuxSubscription;
noMorePublishing: boolean;
options: ConnectionOptions;
outbound: DataBuffer;
outBytes: number;
outMsgs: number;
parser: Parser;
pendingLimit: number;
pongs: Array<Deferred<void>>;
publisher: Publisher;
server: ServerImpl;
servers: Servers;
subscriptions: Subscriptions;
transport: Transport;
whyClosed: string;
private async _close(err?: Error): Promise<void>;
private flushPending();
private initMux(): void;
private selectServer(): ServerImpl | undefined;
_subunsub(s: SubscriptionImpl);
close(): Promise<void>;
dialLoop(): Promise<void>;
public disconnect(): void;
async disconnected(err?: Error): Promise<void>;
async dodialLoop(): Promise<void>;
drain(): Promise<void>;
getServer(): ServerImpl | undefined;
handleAuthError(err: NatsError);
handleError(err: NatsError);
isClosed(): boolean;
processError(m: Uint8Array);
processInfo(m: Uint8Array);
processMsg(msg: MsgArg, data: Uint8Array);
processPing();
processPong();
public reconnect(): Promise<void>;
resetOutbound(): void;
sendCommand(cmd: string | Uint8Array, ...payloads: Uint8Array[]);
sendSubscriptions();
status(): AsyncIterable<Status>;
static public async connect(options: ConnectionOptions, publisher: Publisher): Promise<ProtocolHandler>;
static toError(s: string);
§Implements
§Properties
§
info: ServerInfo
[src]§
listeners: QueuedIterator<Status>[]
[src]§
muxSubscriptions: MuxSubscription
[src]§
options: ConnectionOptions
[src]§
outbound: DataBuffer
[src]§
subscriptions: Subscriptions
[src]§Methods
§
_sub(s: SubscriptionImpl): void
[src]§
_subunsub(s: SubscriptionImpl)
[src]§
push(e: ParserEvent): void
[src]§
subscribe(s: SubscriptionImpl): Subscription
[src]