/// import { IBuffer } from '../buffer'; import * as http from 'http'; import * as net from 'net'; import * as s from '../_server'; import { ConversationBasic } from './_conv'; export * from './_conv'; export declare class WSConversation extends ConversationBasic { protected m_token: string; readonly server: s.Server; readonly request: http.IncomingMessage; readonly socket: net.Socket; /** * @arg {http.ServerRequest} req * @arg {String} bind_services */ constructor(req: http.IncomingMessage, upgradeHead: any, bind_services: string); private _safeDestroy; private _initialize; private __initialize; private _handshakes; private _upgrade; /** * verifies the origin of a request. * @param {String} origin * @return {Boolean} */ verifyOrigin(origin: string): number | boolean; /** * @func bindService() 绑定服务 */ protected bindServices(services: string[]): Promise; send(data: IBuffer): Promise; ping(): Promise; pong(): Promise; close(): void; }