#region License Information
/* HeuristicLab
* Copyright (C) 2002-2014 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
*
* This file is part of HeuristicLab.
*
* HeuristicLab is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* HeuristicLab is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with HeuristicLab. If not, see .
*/
#endregion
using HeuristicLab.Common;
using HeuristicLab.Core;
using HeuristicLab.Data;
using HeuristicLab.Encodings.ScheduleEncoding;
using HeuristicLab.Operators;
using HeuristicLab.Optimization;
using HeuristicLab.Parameters;
using HeuristicLab.Persistence.Default.CompositeSerializers.Storable;
namespace HeuristicLab.Problems.Scheduling {
[Item("SchedulingAnalyzer", "Represents the generalized form of Analyzers for Scheduling Problems.")]
[StorableClass]
public abstract class SchedulingAnalyzer : SingleSuccessorOperator, IAnalyzer {
public virtual bool EnabledByDefault {
get { return true; }
}
[StorableConstructor]
protected SchedulingAnalyzer(bool deserializing) : base(deserializing) { }
protected SchedulingAnalyzer(SchedulingAnalyzer original, Cloner cloner)
: base(original, cloner) {
}
#region Parameter Properties
public LookupParameter MaximizationParameter {
get { return (LookupParameter)Parameters["Maximization"]; }
}
public ScopeTreeLookupParameter QualityParameter {
get { return (ScopeTreeLookupParameter)Parameters["Quality"]; }
}
public LookupParameter BestSolutionParameter {
get { return (LookupParameter)Parameters["BestSolution"]; }
}
public ValueLookupParameter ResultsParameter {
get { return (ValueLookupParameter)Parameters["Results"]; }
}
public LookupParameter BestKnownQualityParameter {
get { return (LookupParameter)Parameters["BestKnownQuality"]; }
}
public LookupParameter BestKnownSolutionParameter {
get { return (LookupParameter)Parameters["BestKnownSolution"]; }
}
public ScopeTreeLookupParameter ScheduleParameter {
get { return (ScopeTreeLookupParameter)Parameters["Schedule"]; }
}
#endregion
public SchedulingAnalyzer()
: base() {
Parameters.Add(new LookupParameter("Maximization", "True if the problem is a maximization problem."));
Parameters.Add(new ScopeTreeLookupParameter("Quality", "The qualities of the JSSP solutions which should be analyzed."));
Parameters.Add(new ScopeTreeLookupParameter("Schedule", "The solutions from which the best solution has to be chosen from."));
Parameters.Add(new LookupParameter("BestSolution", "The best JSSP solution."));
Parameters.Add(new ValueLookupParameter("Results", "The result collection where the best JSSP solution should be stored."));
Parameters.Add(new LookupParameter("BestKnownQuality", "The quality of the best known solution of this JSSP instance."));
Parameters.Add(new LookupParameter("BestKnownSolution", "The best known solution of this JSSP instance."));
}
}
}