Changeset 17522 for branches/2521_ProblemRefactoring/HeuristicLab.Encodings.IntegerVectorEncoding/3.3/IntegerVectorProblem.cs
- Timestamp:
- 04/27/20 18:12:39 (4 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/2521_ProblemRefactoring/HeuristicLab.Encodings.IntegerVectorEncoding/3.3/IntegerVectorProblem.cs
r16950 r17522 34 34 [StorableType("c6081457-a3de-45ce-9f47-e0eb1c851bd2")] 35 35 public abstract class IntegerVectorProblem : SingleObjectiveProblem<IntegerVectorEncoding, IntegerVector> { 36 [Storable] protected IResultParameter<IntegerVector> BestResultParameter { get; private set; } 37 public IResultDefinition<IntegerVector> BestResult { get => BestResultParameter; } 38 36 39 public int Length { 37 40 get { return Encoding.Length; } … … 48 51 protected IntegerVectorProblem(IntegerVectorProblem original, Cloner cloner) 49 52 : base(original, cloner) { 53 BestResultParameter = cloner.Clone(original.BestResultParameter); 50 54 RegisterEventHandlers(); 51 55 } … … 54 58 protected IntegerVectorProblem(IntegerVectorEncoding encoding) : base(encoding) { 55 59 EncodingParameter.ReadOnly = true; 60 Parameters.Add(BestResultParameter = new ResultParameter<IntegerVector>("Best Solution", "The best solution.")); 56 61 57 62 Operators.Add(new HammingSimilarityCalculator());
Note: See TracChangeset
for help on using the changeset viewer.