- Timestamp:
- 01/21/15 13:10:24 (10 years ago)
- Location:
- branches/ProgrammableProblem/HeuristicLab.Problems.Programmable/3.3
- Files:
-
- 5 edited
- 2 moved
Legend:
- Unmodified
- Added
- Removed
-
branches/ProgrammableProblem/HeuristicLab.Problems.Programmable/3.3/HeuristicLab.Problems.Programmable-3.3.csproj
r11813 r11814 150 150 <Compile Include="New\BasicProblem.cs" /> 151 151 <Compile Include="New\MultiObjectiveBasicProblem.cs" /> 152 <Compile Include="New\MultiObjective ScriptableProblem.cs" />152 <Compile Include="New\MultiObjectiveProgrammableProblem.cs" /> 153 153 <Compile Include="New\Scripts\Templates\CompiledMultiObjectiveProblemDefinition.cs" /> 154 154 <Compile Include="New\Scripts\Templates\CompiledSingleObjectiveProblemDefinition.cs" /> … … 176 176 <Compile Include="New\OneMaxNew.cs" /> 177 177 <Compile Include="New\SingleObjectiveBasicProblem.cs" /> 178 <Compile Include="New\SingleObjective ScriptableProblem.cs" />178 <Compile Include="New\SingleObjectiveProgrammableProblem.cs" /> 179 179 <Compile Include="New\Scripts\MultiObjectiveProblemDefinitionScript.cs" /> 180 180 <Compile Include="New\Scripts\SingleObjectiveProblemDefinitionScript.cs" /> -
branches/ProgrammableProblem/HeuristicLab.Problems.Programmable/3.3/New/BasicProblem.cs
r11813 r11814 31 31 namespace HeuristicLab.Problems.Programmable { 32 32 [StorableClass] 33 public abstract class ProgrammableProblem<TEncoding, TEvaluator> : HeuristicOptimizationProblem<TEvaluator, ISolutionCreator>, IProblemDefinition, IStorableContent33 public abstract class BasicProblem<TEncoding, TEvaluator> : HeuristicOptimizationProblem<TEvaluator, ISolutionCreator>, IProblemDefinition, IStorableContent 34 34 where TEncoding : class, IEncoding 35 35 where TEvaluator : class, IEvaluator { … … 64 64 } 65 65 66 protected ProgrammableProblem()66 protected BasicProblem() 67 67 : base() { 68 68 Parameters.Add(new ValueParameter<TEncoding>("Encoding", "Describes the configuration of the encoding, what the variables are called, what type they are and their bounds if any.")); … … 71 71 } 72 72 73 protected ProgrammableProblem(ProgrammableProblem<TEncoding, TEvaluator> original, Cloner cloner)73 protected BasicProblem(BasicProblem<TEncoding, TEvaluator> original, Cloner cloner) 74 74 : base(original, cloner) { 75 75 oldEncoding = cloner.Clone(original.oldEncoding); … … 78 78 79 79 [StorableConstructor] 80 protected ProgrammableProblem(bool deserializing) : base(deserializing) { }80 protected BasicProblem(bool deserializing) : base(deserializing) { } 81 81 [StorableHook(HookType.AfterDeserialization)] 82 82 private void AfterDeserialization() { -
branches/ProgrammableProblem/HeuristicLab.Problems.Programmable/3.3/New/MultiObjectiveBasicProblem.cs
r11813 r11814 30 30 namespace HeuristicLab.Problems.Programmable { 31 31 [StorableClass] 32 public abstract class MultiObjective ProgrammableProblem<TEncoding> : ProgrammableProblem<TEncoding, MultiObjectiveEvaluator>, IMultiObjectiveHeuristicOptimizationProblem, IMultiObjectiveProblemDefinition32 public abstract class MultiObjectiveBasicProblem<TEncoding> : BasicProblem<TEncoding, MultiObjectiveEvaluator>, IMultiObjectiveHeuristicOptimizationProblem, IMultiObjectiveProblemDefinition 33 33 where TEncoding : class, IEncoding { 34 34 [StorableConstructor] 35 protected MultiObjective ProgrammableProblem(bool deserializing) : base(deserializing) { }35 protected MultiObjectiveBasicProblem(bool deserializing) : base(deserializing) { } 36 36 37 protected MultiObjective ProgrammableProblem(MultiObjectiveProgrammableProblem<TEncoding> original, Cloner cloner)37 protected MultiObjectiveBasicProblem(MultiObjectiveBasicProblem<TEncoding> original, Cloner cloner) 38 38 : base(original, cloner) { 39 39 ParameterizeOperators(); 40 40 } 41 41 42 protected MultiObjective ProgrammableProblem()42 protected MultiObjectiveBasicProblem() 43 43 : base() { 44 44 Parameters.Add(new ValueParameter<BoolArray>("Maximization", "Set to false if the problem should be minimized.", new BoolArray())); -
branches/ProgrammableProblem/HeuristicLab.Problems.Programmable/3.3/New/MultiObjectiveProgrammableProblem.cs
r11812 r11814 28 28 29 29 namespace HeuristicLab.Problems.Programmable { 30 [Item(" Scriptable Problem (multi-objective)", "Represents a multi-objective problem that can be scripted.")]30 [Item("Programmable Problem (multi-objective)", "Represents a multi-objective problem that can be programmed with a script.")] 31 31 [Creatable("1 Test")] 32 32 [StorableClass] 33 public sealed class MultiObjective ScriptableProblem : MultiObjectiveProgrammableProblem<IEncoding> {33 public sealed class MultiObjectiveProgrammableProblem : MultiObjectiveBasicProblem<IEncoding> { 34 34 35 35 private FixedValueParameter<MultiObjectiveProblemDefinitionScript> MultiObjectiveProblemScriptParameter { … … 45 45 } 46 46 47 private MultiObjective ScriptableProblem(MultiObjectiveScriptableProblem original, Cloner cloner)47 private MultiObjectiveProgrammableProblem(MultiObjectiveProgrammableProblem original, Cloner cloner) 48 48 : base(original, cloner) { 49 49 RegisterEvents(); … … 55 55 } 56 56 } 57 public override IDeepCloneable Clone(Cloner cloner) { return new MultiObjective ScriptableProblem(this, cloner); }57 public override IDeepCloneable Clone(Cloner cloner) { return new MultiObjectiveProgrammableProblem(this, cloner); } 58 58 59 59 60 60 [StorableConstructor] 61 private MultiObjective ScriptableProblem(bool deserializing) : base(deserializing) { }61 private MultiObjectiveProgrammableProblem(bool deserializing) : base(deserializing) { } 62 62 63 public MultiObjective ScriptableProblem()63 public MultiObjectiveProgrammableProblem() 64 64 : base() { 65 65 Parameters.Add(new FixedValueParameter<MultiObjectiveProblemDefinitionScript>("ProblemScript", "Defines the problem.", new MultiObjectiveProblemDefinitionScript() { Name = Name })); -
branches/ProgrammableProblem/HeuristicLab.Problems.Programmable/3.3/New/OneMaxNew.cs
r11813 r11814 32 32 [Creatable("1 Test")] 33 33 [StorableClass] 34 public class OneMaxNew : SingleObjective ProgrammableProblem<BinaryEncoding> {34 public class OneMaxNew : SingleObjectiveBasicProblem<BinaryEncoding> { 35 35 public override bool Maximization { 36 36 get { return true; } -
branches/ProgrammableProblem/HeuristicLab.Problems.Programmable/3.3/New/SingleObjectiveBasicProblem.cs
r11813 r11814 32 32 namespace HeuristicLab.Problems.Programmable { 33 33 [StorableClass] 34 public abstract class SingleObjective ProgrammableProblem<TEncoding> : ProgrammableProblem<TEncoding, SingleObjectiveEvaluator>,34 public abstract class SingleObjectiveBasicProblem<TEncoding> : BasicProblem<TEncoding, SingleObjectiveEvaluator>, 35 35 ISingleObjectiveProblemDefinition, ISingleObjectiveHeuristicOptimizationProblem 36 36 where TEncoding : class, IEncoding { 37 37 [StorableConstructor] 38 protected SingleObjective ProgrammableProblem(bool deserializing) : base(deserializing) { }38 protected SingleObjectiveBasicProblem(bool deserializing) : base(deserializing) { } 39 39 40 protected SingleObjective ProgrammableProblem(SingleObjectiveProgrammableProblem<TEncoding> original, Cloner cloner)40 protected SingleObjectiveBasicProblem(SingleObjectiveBasicProblem<TEncoding> original, Cloner cloner) 41 41 : base(original, cloner) { 42 42 ParameterizeOperators(); 43 43 } 44 44 45 protected SingleObjective ProgrammableProblem()45 protected SingleObjectiveBasicProblem() 46 46 : base() { 47 47 Parameters.Add(new FixedValueParameter<BoolValue>("Maximization", "Set to false if the problem should be minimized.", new BoolValue())); -
branches/ProgrammableProblem/HeuristicLab.Problems.Programmable/3.3/New/SingleObjectiveProgrammableProblem.cs
r11812 r11814 29 29 30 30 namespace HeuristicLab.Problems.Programmable { 31 [Item(" Scriptable Problem (single-objective)", "Represents a single-objective problem that can be scripted.")]31 [Item("Programmable Problem (single-objective)", "Represents a single-objective problem that can be programmed with a script.")] 32 32 [Creatable("1 Test")] 33 33 [StorableClass] 34 public sealed class SingleObjective ScriptableProblem : SingleObjectiveProgrammableProblem<IEncoding> {34 public sealed class SingleObjectiveProgrammableProblem : SingleObjectiveBasicProblem<IEncoding> { 35 35 36 36 private FixedValueParameter<SingleObjectiveProblemDefinitionScript> SingleObjectiveProblemScriptParameter { … … 46 46 } 47 47 48 private SingleObjective ScriptableProblem(SingleObjectiveScriptableProblem original, Cloner cloner)48 private SingleObjectiveProgrammableProblem(SingleObjectiveProgrammableProblem original, Cloner cloner) 49 49 : base(original, cloner) { 50 50 RegisterEvents(); … … 56 56 } 57 57 } 58 public override IDeepCloneable Clone(Cloner cloner) { return new SingleObjective ScriptableProblem(this, cloner); }58 public override IDeepCloneable Clone(Cloner cloner) { return new SingleObjectiveProgrammableProblem(this, cloner); } 59 59 60 60 61 61 [StorableConstructor] 62 private SingleObjective ScriptableProblem(bool deserializing) : base(deserializing) { }62 private SingleObjectiveProgrammableProblem(bool deserializing) : base(deserializing) { } 63 63 64 public SingleObjective ScriptableProblem()64 public SingleObjectiveProgrammableProblem() 65 65 : base() { 66 66 Parameters.Add(new FixedValueParameter<SingleObjectiveProblemDefinitionScript>("ProblemScript", "Defines the problem.", new SingleObjectiveProblemDefinitionScript() { Name = Name }));
Note: See TracChangeset
for help on using the changeset viewer.