Lines Matching refs:callback
57 connect(url: string, callback: AsyncCallback<boolean>): void;
58 connect(url: string, options: WebSocketRequestOptions, callback: AsyncCallback<boolean>): void;
68 send(data: string | ArrayBuffer, callback: AsyncCallback<boolean>): void;
78 close(callback: AsyncCallback<boolean>): void;
79 close(options: WebSocketCloseOptions, callback: AsyncCallback<boolean>): void;
85 on(type: 'open', callback: AsyncCallback<Object>): void;
90 off(type: 'open', callback?: AsyncCallback<Object>): void;
96 on(type: 'message', callback: AsyncCallback<string | ArrayBuffer>): void;
102 off(type: 'message', callback?: AsyncCallback<string | ArrayBuffer>): void;
107 on(type: 'close', callback: AsyncCallback<{ code: number, reason: string }>): void;
112 off(type: 'close', callback?: AsyncCallback<{ code: number, reason: string }>): void;
117 on(type: 'error', callback: ErrorCallback): void;
122 off(type: 'error', callback?: ErrorCallback): void;