Changeset 17695 for branches/2521_ProblemRefactoring/HeuristicLab.Encodings.BinaryVectorEncoding/3.3
- Timestamp:
- 07/23/20 16:21:55 (4 years ago)
- Location:
- branches/2521_ProblemRefactoring/HeuristicLab.Encodings.BinaryVectorEncoding/3.3
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/2521_ProblemRefactoring/HeuristicLab.Encodings.BinaryVectorEncoding/3.3/BinaryVectorMultiObjectiveProblem.cs
r17620 r17695 20 20 #endregion 21 21 22 using System; 22 23 using System.Linq; 23 24 using HEAL.Attic; … … 57 58 protected BinaryVectorMultiObjectiveProblem(BinaryVectorEncoding encoding) : base(encoding) { 58 59 EncodingParameter.ReadOnly = true; 60 EvaluatorParameter.ReadOnly = true; 59 61 Parameters.Add(BestResultParameter = new ResultParameter<ParetoFrontScatterPlot<BinaryVector>>("Best Pareto Front", "The best Pareto front found.")); 60 62 Parameters.Add(DimensionRefParameter = new ReferenceParameter<IntValue>("Dimension", "The dimension of the binary vector problem.", Encoding.LengthParameter)); … … 74 76 75 77 BestResultParameter.ActualValue = plot; 78 } 79 80 protected override sealed void OnEvaluatorChanged() { 81 throw new InvalidOperationException("Evaluator may not change!"); 82 } 83 84 protected override sealed void OnEncodingChanged() { 85 throw new InvalidOperationException("Encoding may not change!"); 76 86 } 77 87 -
branches/2521_ProblemRefactoring/HeuristicLab.Encodings.BinaryVectorEncoding/3.3/BinaryVectorProblem.cs
r17620 r17695 20 20 #endregion 21 21 22 using System; 22 23 using System.Linq; 23 24 using HEAL.Attic; … … 63 64 protected BinaryVectorProblem(BinaryVectorEncoding encoding) : base(encoding) { 64 65 EncodingParameter.ReadOnly = true; 66 EvaluatorParameter.ReadOnly = true; 65 67 Parameters.Add(DimensionRefParameter = new ReferenceParameter<IntValue>("Dimension", "The dimension of the binary vector problem.", Encoding.LengthParameter)); 66 68 Results.Add(BestSolutionResult = new Result<ISingleObjectiveSolutionContext<BinaryVector>>("Best Solution")); … … 80 82 if (BestSolution == null || IsBetter(best, BestSolution)) 81 83 BestSolution = best.Clone() as SingleObjectiveSolutionContext<BinaryVector>; 84 } 85 86 protected override sealed void OnEvaluatorChanged() { 87 throw new InvalidOperationException("Evaluator may not change!"); 88 } 89 90 protected override sealed void OnEncodingChanged() { 91 throw new InvalidOperationException("Encoding may not change!"); 82 92 } 83 93
Note: See TracChangeset
for help on using the changeset viewer.