Use this method to close the websocket connection cleanly This sends a close frame and waits for acknowlegement before closing the connection
define WebSocket callbacks
Send a ping to the client. The client must respond with a pong.
In the case that the client is running a WebSocket draft < 01, false is returned since ping & pong are not supported
Test whether the connection is pingable (i.e. the WebSocket draft in use is >= 01)
Send an unsolicited pong message, as allowed by the protocol. The client is not expected to respond to this message.
em-websocket automatically takes care of sending pong replies to incoming ping messages, as the protocol demands.
[Validate]