Skip to content

Instantly share code, notes, and snippets.

@odadoda
Created November 8, 2013 13:16
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save odadoda/7370904 to your computer and use it in GitHub Desktop.
Save odadoda/7370904 to your computer and use it in GitHub Desktop.
Return a websocket connection
// Websocket interface
public static WebSocket<String> wsInterface(){
return new WebSocket<String>(){
// called when websocket handshake is done
public void onReady(WebSocket.In<String> in, WebSocket.Out<String> out){
SimpleChat.start(in, out);
}
};
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment