Example #1
0
 private void Dispose(bool disposing)
 {
     if (disposing)
     {
         if (_Server != null)
         {
             _Server.Dispose();
             _Server = null;
         }
     }
 }
Example #2
0
 public void Disconnect()
 {
     _projectCollection?.Dispose();
     _configurationServer?.Dispose();
     ClearBranchPaths();
     IsConnected = false;
 }
Example #3
0
 public void Dispose()
 {
     if (_tfsConfigurationServer != null)
     {
         _tfsConfigurationServer.Dispose();
     }
 }
Example #4
0
 /// <summary>
 /// Dispose of all resources held.
 /// </summary>
 /// <param name="disposeManaged">If disposeManaged equals true, clean up all resources.</param>
 protected virtual void Dispose(bool disposeManaged)
 {
     if (disposeManaged)
     {
         if (configurationServer != null)
         {
             configurationServer.Dispose();
             configurationServer = null;
         }
     }
 }
Example #5
0
        private static bool CheckTfsServerPath(string path, NetworkCredential credential)
        {
            TfsConfigurationServer tfsServer = null;

            try
            {
                tfsServer = new TfsConfigurationServer(new Uri(path), credential);
                tfsServer.Connect(ConnectOptions.None);
                return(true);
            }
            catch
            {
                if (tfsServer != null)
                {
                    tfsServer.Dispose();
                }
            }

            return(false);
        }
        private static bool CheckTfsServerPath(string path, NetworkCredential credential)
        {
            TfsConfigurationServer tfsServer = null;
            try
            {
                tfsServer = new TfsConfigurationServer(new Uri(path), credential);
                tfsServer.Connect(ConnectOptions.None);
                return true;
            }
            catch
            {
                if (tfsServer != null)
                    tfsServer.Dispose();
            }

            return false;
        }
Example #7
0
 public void Dispose()
 {
     _tfsConfigurationServer.Dispose();
 }