Package playn.core
Interface Net.WebSocket.Listener
- Enclosing interface:
Net.WebSocket
public static interface Net.WebSocket.Listener
Notifies game of web socket events.
-
Method Summary
Modifier and TypeMethodDescriptionvoid
onClose()
Reports that a web socket has been closed.void
onDataMessage
(ByteBuffer msg) Reports that a binary message has arrived on a web socket.void
Reports that a web socket has encountered an error.void
onOpen()
Reports that a requested web socket is now open and ready for use.void
onTextMessage
(String msg) Reports that a text message has arrived on a web socket.
-
Method Details
-
onOpen
void onOpen()Reports that a requested web socket is now open and ready for use. -
onTextMessage
Reports that a text message has arrived on a web socket. -
onDataMessage
Reports that a binary message has arrived on a web socket. -
onClose
void onClose()Reports that a web socket has been closed. -
onError
Reports that a web socket has encountered an error. TODO: is it closed as a result of this?
-