Example usage for com.google.gwt.websocket.client WebSocket CONNECTING

List of usage examples for com.google.gwt.websocket.client WebSocket CONNECTING

Introduction

In this page you can find the example usage for com.google.gwt.websocket.client WebSocket CONNECTING.

Prototype

int CONNECTING

To view the source code for com.google.gwt.websocket.client WebSocket CONNECTING.

Click Source Link

Document

The connection has not yet been established.

Usage

From source file:org.rest.client.activity.SocketActivity.java

License:Apache License

@Override
public void connect(String url) {
    if (socket != null) {
        socket.close();/*from w w  w .j  a  va 2  s.  co m*/
    }
    socket = null;
    socketUrl = url;
    messages.clear();
    saveHistory();
    view.setConnectionStatus(WebSocket.CONNECTING);

    socket = WebSocketImpl.open(url);
    setUpSocketHandlers();

}