Ignore:
Timestamp:
07/07/14 14:17:15 (7 years ago)
Author:
abeham
Message:

#2189: updated API documentation and comments

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/sources/HeuristicLab.Algorithms.TabuSearch/3.3/TabuSearch.cs

    r11096 r11108  
    352352      if (Problem != null) {
    353353        // only add move generators that also have a corresponding tabu-checker and tabu-maker
    354         //
    355         // 1. assumption: all tabu checkers and tabu makers also implement the IMoveOperator interface
    356         // 2. assumption: all move generators also implement the IMoveOperator interface
    357         // 3. assumption: if compatible all three operators implement the same (most specific) IMoveOperator interface
    358354        foreach (IMoveGenerator generator in Problem.Operators.OfType<IMoveGenerator>().OrderBy(x => x.Name)) {
    359355          // get all interfaces equal to or derived from IMoveOperator that this move generator implements
     
    364360            if (moveTypes.Any(t => t != type && type.IsAssignableFrom(t))) moveTypes.Remove(type);
    365361          }
    366           // keep move generator only if there is a tabu checker and a tabu maker that is derived from
    367           // one of the most specific interfaces in moveTypes (e.g. IPermutationTranslocationMoveOperator)
     362          // keep move generator only if there is a tabu checker and a tabu maker that is derived from the same move interface
    368363          if (Problem.Operators.OfType<ITabuChecker>().Any(op => moveTypes.Any(m => m.IsInstanceOfType(op)))
    369364            && Problem.Operators.OfType<ITabuMaker>().Any(op => moveTypes.Any(m => m.IsInstanceOfType(op))))
Note: See TracChangeset for help on using the changeset viewer.