Changeset 11587 for branches/ProgrammableProblem/HeuristicLab.Problems.Programmable/3.3/Encodings/BinaryEncoding.cs
- Timestamp:
- 11/26/14 13:24:20 (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/ProgrammableProblem/HeuristicLab.Problems.Programmable/3.3/Encodings/BinaryEncoding.cs
r11582 r11587 48 48 } 49 49 public override IEnumerable<IValueParameter> Parameters { 50 get { return base.Parameters.Concat(new IValueParameter[] { LengthParameter }); }50 get { return new IValueParameter[] { LengthParameter }; } 51 51 } 52 52 #endregion … … 73 73 : base(name) { 74 74 lengthParameter = new FixedValueParameter<IntValue>(Name + "Length", new IntValue(length)); 75 SolutionCreator = new RandomBinaryVectorCreator(); 75 76 RegisterParameterEvents(); 76 77 DiscoverOperators(); 77 SolutionCreator = Operators.OfType<RandomBinaryVectorCreator>().Single();78 78 } 79 79 … … 106 106 var discoveredTypes = ApplicationManager.Manager.GetTypes(encodingSpecificOperatorTypes, pluginDescription, true, false, false); 107 107 var operators = discoveredTypes.Select(t => (IOperator)Activator.CreateInstance(t)); 108 var newOperators = operators.Except( encodingOperators, new TypeEqualityComparer<IOperator>()).ToList();108 var newOperators = operators.Except(Operators, new TypeEqualityComparer<IOperator>()).ToList(); 109 109 110 110 ConfigureOperators(newOperators); 111 encodingOperators.AddRange(newOperators); 111 foreach (var @operator in newOperators) 112 encodingOperators.Add(@operator); 112 113 } 113 114 #endregion
Note: See TracChangeset
for help on using the changeset viewer.