Example #1
0
 /// <summary>
 /// Run search.
 /// </summary>
 /// <param name="settings">Settings to start search.</param>
 /// <exception cref="ArgumentNullException">Throws if <paramref name="settings"/> is null.</exception>
 /// <exception cref="InvalidOperationException">Throws if previous search command is still active.</exception>
 /// <exception cref="SearchSettingsValidationException">Throws if settings to search has any problems.</exception>
 public void Run(SearchSettings settings)
 {
     if (settings == null)
     {
         throw new ArgumentNullException("settings");
     }
     if (IsBusy)
     {
         ShowUI();
         throw new InvalidOperationException("The previous search command is still active.");
     }
     _searcherUI = new SearchProgressForm(this);
     ShowUI();
     LogMessage("Search started.");
     InternalStartSearching(settings);
 }
Example #2
0
 /// <summary>
 /// Run search.
 /// </summary>
 /// <param name="settings">Settings to start search.</param>
 /// <exception cref="ArgumentNullException">Throws if <paramref name="settings"/> is null.</exception>
 /// <exception cref="InvalidOperationException">Throws if previous search command is still active.</exception>
 /// <exception cref="SearchSettingsValidationException">Throws if settings to search has any problems.</exception>
 public void Run(SearchSettings settings)
 {
     if (settings == null)
         throw new ArgumentNullException("settings");
     if (IsBusy)
     {
         ShowUI();
         throw new InvalidOperationException("The previous search command is still active.");
     }
     _searcherUI = new SearchProgressForm(this);
     ShowUI();
     LogMessage("Search started.");
     InternalStartSearching(settings);
 }