public StubWebSocketConnection Connect(string path) { var connection = new StubWebSocketConnection(Guid.NewGuid(), path); connection.ReceiveMessageHandler = msg => OnMessageReceived(new WebSocketMessageEventArgs(connection, msg)); RegisterConnection(connection); return connection; }
public StubWebSocketConnection Connect(string path) { var connection = new StubWebSocketConnection(Guid.NewGuid(), path); connection.ReceiveMessageHandler = msg => OnMessageReceived(new WebSocketMessageEventArgs(connection, msg)); RegisterConnection(connection); return(connection); }
public void Disconnect(StubWebSocketConnection connection) { UnregisterConnection(connection.Identity); }
public void Disconnect(StubWebSocketConnection connection) { UnregisterConnection(connection.Identity); }