Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
06/05/12 08:34:36 (12 years ago)
Author:
svonolfe
Message:

Merged changes from trunk into branch (#1177)

Location:
branches/VRP/HeuristicLab.Problems.VehicleRouting/3.4
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • branches/VRP/HeuristicLab.Problems.VehicleRouting/3.4

  • branches/VRP/HeuristicLab.Problems.VehicleRouting/3.4/ProblemInstances/SingleDepotVRP/CVRP/CVRPProblemInstance.cs

    r7864 r7958  
    2323using System.Collections.Generic;
    2424using System.Linq;
    25 using System.Text;
    26 using HeuristicLab.Problems.VehicleRouting.Interfaces;
    27 using HeuristicLab.Persistence.Default.CompositeSerializers.Storable;
     25using HeuristicLab.Common;
    2826using HeuristicLab.Core;
    29 using HeuristicLab.Parameters;
    3027using HeuristicLab.Data;
    3128using HeuristicLab.Optimization;
     29using HeuristicLab.Parameters;
     30using HeuristicLab.Persistence.Default.CompositeSerializers.Storable;
    3231using HeuristicLab.PluginInfrastructure;
     32using HeuristicLab.Problems.VehicleRouting.Interfaces;
    3333using HeuristicLab.Problems.VehicleRouting.Variants;
    34 using HeuristicLab.Common;
    3534
    3635namespace HeuristicLab.Problems.VehicleRouting.ProblemInstances {
    3736  [Item("CVRPProblemInstance", "Represents a single depot CVRP instance.")]
    3837  [StorableClass]
    39   public class CVRPProblemInstance: SingleDepotVRPProblemInstance, IHomogenousCapacitatedProblemInstance {
     38  public class CVRPProblemInstance : SingleDepotVRPProblemInstance, IHomogenousCapacitatedProblemInstance {
    4039    protected IValueParameter<DoubleValue> CapacityParameter {
    4140      get { return (IValueParameter<DoubleValue>)Parameters["Capacity"]; }
     
    6059          return currentOverloadPenalty;
    6160        else
    62           return OverloadPenaltyParameter.Value; }
     61          return OverloadPenaltyParameter.Value;
     62      }
    6363      set { CurrentOverloadPenaltyParameter.Value = value; }
    6464    }
    6565
    6666    protected override IEnumerable<IOperator> GetOperators() {
    67         return base.GetOperators()
    68           .Where(o => o is IHomogenousCapacitatedOperator).Cast<IOperator>();
     67      return base.GetOperators()
     68        .Where(o => o is IHomogenousCapacitatedOperator).Cast<IOperator>();
    6969    }
    7070
     
    8080      }
    8181    }
    82    
     82
    8383    [StorableConstructor]
    8484    protected CVRPProblemInstance(bool deserializing) : base(deserializing) { }
     
    9898    protected CVRPProblemInstance(CVRPProblemInstance original, Cloner cloner)
    9999      : base(original, cloner) {
    100         AttachEventHandlers();
     100      AttachEventHandlers();
    101101    }
    102102
    103103    [StorableHook(HookType.AfterDeserialization)]
    104     private void AfterDeserializationHook() {
     104    private void AfterDeserialization() {
    105105      AttachEventHandlers();
    106106    }
  • branches/VRP/HeuristicLab.Problems.VehicleRouting/3.4/ProblemInstances/SingleDepotVRP/CVRP/CVRPTW/CVRPPDTW/CVRPPDTWProblemInstance.cs

    r7864 r7958  
    2323using System.Collections.Generic;
    2424using System.Linq;
    25 using System.Text;
    26 using HeuristicLab.Problems.VehicleRouting.Interfaces;
    27 using HeuristicLab.Persistence.Default.CompositeSerializers.Storable;
     25using HeuristicLab.Common;
    2826using HeuristicLab.Core;
    29 using HeuristicLab.Parameters;
    3027using HeuristicLab.Data;
    3128using HeuristicLab.Optimization;
     29using HeuristicLab.Parameters;
     30using HeuristicLab.Persistence.Default.CompositeSerializers.Storable;
    3231using HeuristicLab.PluginInfrastructure;
     32using HeuristicLab.Problems.VehicleRouting.Interfaces;
    3333using HeuristicLab.Problems.VehicleRouting.Variants;
    34 using HeuristicLab.Common;
    3534
    3635namespace HeuristicLab.Problems.VehicleRouting.ProblemInstances {
    3736  [Item("CVRPPDTWProblemInstance", "Represents a single depot CVRPPDTW instance.")]
    3837  [StorableClass]
    39   public class CVRPPDTWProblemInstance: CVRPTWProblemInstance, IPickupAndDeliveryProblemInstance {
     38  public class CVRPPDTWProblemInstance : CVRPTWProblemInstance, IPickupAndDeliveryProblemInstance {
    4039    protected IValueParameter<IntArray> PickupDeliveryLocationParameter {
    4140      get { return (IValueParameter<IntArray>)Parameters["PickupDeliveryLocation"]; }
     
    4443      get { return (IValueParameter<DoubleValue>)Parameters["EvalPickupViolationPenalty"]; }
    4544    }
    46    
     45
    4746    public IntArray PickupDeliveryLocation {
    4847      get { return PickupDeliveryLocationParameter.Value; }
     
    6665
    6766    protected override IEnumerable<IOperator> GetOperators() {
    68       return 
     67      return
    6968        ApplicationManager.Manager.GetInstances<IPickupAndDeliveryOperator>()
    7069        .Where(o => !(o is IAnalyzer))
     
    7776        .Cast<IOperator>().Union(base.GetAnalyzers());
    7877    }
    79    
     78
    8079    protected override IVRPEvaluator Evaluator {
    8180      get {
     
    8786      return PickupDeliveryLocation[city];
    8887    }
    89    
     88
    9089    [StorableConstructor]
    9190    protected CVRPPDTWProblemInstance(bool deserializing) : base(deserializing) { }
     
    106105    protected CVRPPDTWProblemInstance(CVRPPDTWProblemInstance original, Cloner cloner)
    107106      : base(original, cloner) {
    108         AttachEventHandlers();
     107      AttachEventHandlers();
    109108    }
    110109
    111110    [StorableHook(HookType.AfterDeserialization)]
    112     private void AfterDeserializationHook() {
     111    private void AfterDeserialization() {
    113112      AttachEventHandlers();
    114113    }
  • branches/VRP/HeuristicLab.Problems.VehicleRouting/3.4/ProblemInstances/SingleDepotVRP/CVRP/CVRPTW/CVRPTWProblemInstance.cs

    r7864 r7958  
    2323using System.Collections.Generic;
    2424using System.Linq;
    25 using System.Text;
    26 using HeuristicLab.Problems.VehicleRouting.Interfaces;
    27 using HeuristicLab.Persistence.Default.CompositeSerializers.Storable;
     25using HeuristicLab.Common;
    2826using HeuristicLab.Core;
    29 using HeuristicLab.Parameters;
    3027using HeuristicLab.Data;
    3128using HeuristicLab.Optimization;
     29using HeuristicLab.Parameters;
     30using HeuristicLab.Persistence.Default.CompositeSerializers.Storable;
    3231using HeuristicLab.PluginInfrastructure;
     32using HeuristicLab.Problems.VehicleRouting.Interfaces;
    3333using HeuristicLab.Problems.VehicleRouting.Variants;
    34 using HeuristicLab.Common;
    3534
    3635namespace HeuristicLab.Problems.VehicleRouting.ProblemInstances {
    3736  [Item("CVRPTWProblemInstance", "Represents a single depot CVRPTW instance.")]
    3837  [StorableClass]
    39   public class CVRPTWProblemInstance: CVRPProblemInstance, ITimeWindowedProblemInstance {
     38  public class CVRPTWProblemInstance : CVRPProblemInstance, ITimeWindowedProblemInstance {
    4039    protected IValueParameter<DoubleArray> ReadyTimeParameter {
    4140      get { return (IValueParameter<DoubleArray>)Parameters["ReadyTime"]; }
     
    9796        .Cast<IOperator>().Union(base.GetAnalyzers());
    9897    }
    99    
     98
    10099    protected override IVRPEvaluator Evaluator {
    101100      get {
     
    103102      }
    104103    }
    105    
     104
    106105    [StorableConstructor]
    107106    protected CVRPTWProblemInstance(bool deserializing) : base(deserializing) { }
     
    125124    protected CVRPTWProblemInstance(CVRPTWProblemInstance original, Cloner cloner)
    126125      : base(original, cloner) {
    127         AttachEventHandlers();
     126      AttachEventHandlers();
    128127    }
    129128
    130129    [StorableHook(HookType.AfterDeserialization)]
    131     private void AfterDeserializationHook() {
     130    private void AfterDeserialization() {
    132131      AttachEventHandlers();
    133132    }
Note: See TracChangeset for help on using the changeset viewer.