Ejemplo n.º 1
0
        protected override void Dispose(bool disposing)
        {
            if (disposing)
            {
                var tasks = new List <Task>();
                foreach (var disp in subscriptions)
                {
                    var task = disp.DisposeAsync();
                    tasks.Add(task);
                }

                Task.WaitAll(tasks.ToArray());

                client.Dispose();
                client = null;
            }
        }
Ejemplo n.º 2
0
 public DeepStreamClient(string hostname, int port)
 {
     subscriptions = new List <IAsyncDisposable>();
     client        = new DeepStreamNet.DeepStreamClient(hostname, (short)port);
 }