Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
07/25/20 01:23:08 (4 years ago)
Author:
abeham
Message:

#2521: Made encodings non-generic classes (the TEncodedSolution type parameter is not actually used), this will make it considerably easier to port the VRP to the new architecture

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/2521_ProblemRefactoring/HeuristicLab.Optimization/3.3/BasicProblems/Operators/SingleObjectiveMoveMaker.cs

    r17226 r17699  
    3131  [Item("Single-objective MoveMaker", "Applies a move.")]
    3232  [StorableType("C0ABF392-C825-4B98-8FB9-5749A9091FD6")]
    33   internal sealed class SingleObjectiveMoveMaker<TEncodedSolution> : InstrumentedOperator, IMoveMaker, ISingleObjectiveMoveOperator
    34   where TEncodedSolution : class, IEncodedSolution {
    35     public ILookupParameter<IEncoding<TEncodedSolution>> EncodingParameter {
    36       get { return (ILookupParameter<IEncoding<TEncodedSolution>>)Parameters["Encoding"]; }
     33  internal sealed class SingleObjectiveMoveMaker : InstrumentedOperator, IMoveMaker, ISingleObjectiveMoveOperator {
     34    public ILookupParameter<IEncoding> EncodingParameter {
     35      get { return (ILookupParameter<IEncoding>)Parameters["Encoding"]; }
    3736    }
    3837
     
    4746    [StorableConstructor]
    4847    private SingleObjectiveMoveMaker(StorableConstructorFlag _) : base(_) { }
    49     private SingleObjectiveMoveMaker(SingleObjectiveMoveMaker<TEncodedSolution> original, Cloner cloner) : base(original, cloner) { }
     48    private SingleObjectiveMoveMaker(SingleObjectiveMoveMaker original, Cloner cloner) : base(original, cloner) { }
    5049    public SingleObjectiveMoveMaker() {
    51       Parameters.Add(new LookupParameter<IEncoding<TEncodedSolution>>("Encoding", "An item that holds the problem's encoding."));
     50      Parameters.Add(new LookupParameter<IEncoding>("Encoding", "An item that holds the problem's encoding."));
    5251      Parameters.Add(new LookupParameter<DoubleValue>("Quality", "The quality of the parameter vector."));
    5352      Parameters.Add(new LookupParameter<DoubleValue>("MoveQuality", "The quality of the move."));
     
    5554
    5655    public override IDeepCloneable Clone(Cloner cloner) {
    57       return new SingleObjectiveMoveMaker<TEncodedSolution>(this, cloner);
     56      return new SingleObjectiveMoveMaker(this, cloner);
    5857    }
    5958
Note: See TracChangeset for help on using the changeset viewer.