added #ping(chunk) and #close(code) to WebSocket