Exemplo n.º 1
0
        public override void Dispose()
        {
            if (this.acceptor == null)
            {
                return;
            }

            foreach (long id in this.idChannels.Keys.ToArray())
            {
                TChannel channel = this.idChannels[id];
                channel.Dispose();
            }
            this.acceptor.Stop();
            this.acceptor = null;
        }
Exemplo n.º 2
0
        public override void Dispose()
        {
            if (this.IsDisposed)
            {
                return;
            }

            base.Dispose();

            foreach (long id in this.idChannels.Keys.ToArray())
            {
                TChannel channel = this.idChannels[id];
                channel.Dispose();
            }
            this.acceptor?.Close();
            this.acceptor = null;
            this.innArgs.Dispose();
        }
Exemplo n.º 3
0
        public override void Dispose()
        {
            bool IsDisposeLocal = this.IsDispose;

            base.Dispose();
            this.IsDispose = true;
            if (IsDisposeLocal)
            {
                return;
            }


            foreach (long id in this.idChannels.Keys.ToArray())
            {
                TChannel channel = this.idChannels[id];
                channel.Dispose();
            }
            this.acceptor?.Close();
            this.acceptor = null;
            this.innArgs.Dispose();
        }