IsAlive() public abstract method

public abstract IsAlive ( ) : bool
return bool
        public void Sub()
        {
            SubModel subModel = new SubModel
            {
                Id     = Id,
                Name   = Name,
                Params = Params
            };

            if (!_webSocketAdapterBase.IsAlive())
            {
                throw new InvalidOperationException("The DDP-Connection is not alive anymore");
            }
            _webSocketAdapterBase.SendJson(subModel);
        }
示例#2
0
 private void Dispose(bool disposing)
 {
     if (!_disposed)
     {
         if (disposing && _webSocketAdapter.IsAlive())
         {
             //dispose managed resources
             _webSocketAdapter.Close();
         }
     }
     //dispose unmanaged resources
     _disposed = true;
 }