lib/Connection.js
function ReconnectingConnection(id, connection) {
  this.id = id;
  this.connection = null;
  this.closed = false;
  this.queue = [];

  this.setConnection(connection);
}
function ReconnectingConnection(id, connection) {
  this.id = id;
  this.connection = null;
  this.closed = false;
  this.queue = [];

  this.setConnection(connection);
}
function ReconnectingConnection ( id , connection ) { this . id = id ; this . connection = null ; this . closed = false ; this . queue = [ ] ; this . setConnection ( connection ) ; }
Create a reconnecting connection
@param {number | string} id      Identifier for this connection
@param {WebSocket} [connection]  A client connection
@constructor
Create a reconnecting connection