- Timestamp:
- 12/04/15 10:35:04 (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/ProblemRefactoring/HeuristicLab.Problems.Scheduling/3.3/Analyzers/BestSchedulingSolutionAnalyzer.cs
r12012 r13435 20 20 #endregion 21 21 22 using System.Collections.Generic; 22 23 using System.Linq; 23 24 using HeuristicLab.Common; … … 77 78 if (bestSolution == null) { 78 79 bestSolution = (Schedule)solutions[i].Clone(); 79 bestSolution.Quality = (DoubleValue)qualities[i].Clone();80 bestSolution.Quality = qualities[i].Value; 80 81 BestSolutionParameter.ActualValue = bestSolution; 81 82 results.Add(new Result("Best Scheduling Solution", bestSolution)); 82 83 } else { 83 if (max && bestSolution.Quality.Value < qualities[i].Value || 84 !max && bestSolution.Quality.Value > qualities[i].Value) { 85 bestSolution.Quality.Value = qualities[i].Value; 86 bestSolution.Resources = (ItemList<Resource>)solutions[i].Resources.Clone(); 84 if (max && bestSolution.Quality < qualities[i].Value || 85 !max && bestSolution.Quality > qualities[i].Value) { 86 bestSolution.Quality = qualities[i].Value; 87 bestSolution.Resources.Clear(); 88 bestSolution.Resources.AddRange((IEnumerable<Resource>)solutions[i].Resources.Clone()); 87 89 } 88 90 }
Note: See TracChangeset
for help on using the changeset viewer.