Free cookie consent management tool by TermsFeed Policy Generator

Changeset 6364


Ignore:
Timestamp:
06/06/11 11:23:43 (13 years ago)
Author:
jhelm
Message:

#1329: Did some minor refactoring.

Location:
branches/Scheduling
Files:
2 added
5 deleted
29 edited
6 moved

Legend:

Unmodified
Added
Removed
  • branches/Scheduling/HeuristicLab 3.3.sln

    r6294 r6364  
    402402EndProject
    403403Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "HeuristicLab.Encodings.SchedulingEncoding-3.3", "HeuristicLab.Encodings.SchedulingEncoding\3.3\HeuristicLab.Encodings.SchedulingEncoding-3.3.csproj", "{17F3EF80-B2C3-4B8D-A4D5-BE9CE3BA2606}"
     404EndProject
     405Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "HeuristicLab.Encodings.SchedulingEncoding.Views-3.3", "HeuristicLab.Encodings.SchedulingEncoding.Views\3.3\HeuristicLab.Encodings.SchedulingEncoding.Views-3.3.csproj", "{0C378762-D5DB-488A-8931-2BA42B1B7CBF}"
    404406EndProject
    405407Global
     
    18801882    {17F3EF80-B2C3-4B8D-A4D5-BE9CE3BA2606}.Release|x64.ActiveCfg = Release|Any CPU
    18811883    {17F3EF80-B2C3-4B8D-A4D5-BE9CE3BA2606}.Release|x86.ActiveCfg = Release|Any CPU
     1884    {0C378762-D5DB-488A-8931-2BA42B1B7CBF}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
     1885    {0C378762-D5DB-488A-8931-2BA42B1B7CBF}.Debug|Any CPU.Build.0 = Debug|Any CPU
     1886    {0C378762-D5DB-488A-8931-2BA42B1B7CBF}.Debug|x64.ActiveCfg = Debug|Any CPU
     1887    {0C378762-D5DB-488A-8931-2BA42B1B7CBF}.Debug|x86.ActiveCfg = Debug|Any CPU
     1888    {0C378762-D5DB-488A-8931-2BA42B1B7CBF}.Release|Any CPU.ActiveCfg = Release|Any CPU
     1889    {0C378762-D5DB-488A-8931-2BA42B1B7CBF}.Release|Any CPU.Build.0 = Release|Any CPU
     1890    {0C378762-D5DB-488A-8931-2BA42B1B7CBF}.Release|x64.ActiveCfg = Release|Any CPU
     1891    {0C378762-D5DB-488A-8931-2BA42B1B7CBF}.Release|x86.ActiveCfg = Release|Any CPU
    18821892  EndGlobalSection
    18831893  GlobalSection(SolutionProperties) = preSolution
  • branches/Scheduling/HeuristicLab.Encodings.SchedulingEncoding.Views/3.3/GanttChart.Designer.cs

    r6292 r6364  
    1 namespace HeuristicLab.Problems.Scheduling.Views {
     1namespace HeuristicLab.Encodings.SchedulingEncoding.Views {
    22  partial class GanttChart {
    33    /// <summary>
  • branches/Scheduling/HeuristicLab.Encodings.SchedulingEncoding.Views/3.3/GanttChart.cs

    r6292 r6364  
    66using System.Windows.Forms.DataVisualization.Charting;
    77
    8 namespace HeuristicLab.Problems.Scheduling.Views {
     8namespace HeuristicLab.Encodings.SchedulingEncoding.Views {
    99  public partial class GanttChart : UserControl {
    1010
  • branches/Scheduling/HeuristicLab.Encodings.SchedulingEncoding.Views/3.3/HeuristicLab.Encodings.SchedulingEncoding.Views-3.3.csproj

    r6297 r6364  
    4040    <Reference Include="System" />
    4141    <Reference Include="System.Core" />
     42    <Reference Include="System.Drawing" />
     43    <Reference Include="System.Windows.Forms" />
     44    <Reference Include="System.Windows.Forms.DataVisualization" />
    4245    <Reference Include="System.Xml.Linq" />
    4346    <Reference Include="System.Data.DataSetExtensions" />
     
    4750  </ItemGroup>
    4851  <ItemGroup>
     52    <Compile Include="GanttChart.cs">
     53      <SubType>UserControl</SubType>
     54    </Compile>
     55    <Compile Include="GanttChart.Designer.cs">
     56      <DependentUpon>GanttChart.cs</DependentUpon>
     57    </Compile>
    4958    <Compile Include="Plugin.cs" />
    5059    <Compile Include="Properties\AssemblyInfo.cs" />
     60    <Compile Include="ScheduleView.cs">
     61      <SubType>UserControl</SubType>
     62    </Compile>
     63    <Compile Include="ScheduleView.Designer.cs">
     64      <DependentUpon>ScheduleView.cs</DependentUpon>
     65    </Compile>
    5166  </ItemGroup>
    5267  <ItemGroup>
     
    6782      <Name>HeuristicLab.Common-3.3</Name>
    6883    </ProjectReference>
     84    <ProjectReference Include="..\..\HeuristicLab.Core.Views\3.3\HeuristicLab.Core.Views-3.3.csproj">
     85      <Project>{E226881D-315F-423D-B419-A766FE0D8685}</Project>
     86      <Name>HeuristicLab.Core.Views-3.3</Name>
     87    </ProjectReference>
    6988    <ProjectReference Include="..\..\HeuristicLab.Core\3.3\HeuristicLab.Core-3.3.csproj">
    7089      <Project>{C36BD924-A541-4A00-AFA8-41701378DDC5}</Project>
    7190      <Name>HeuristicLab.Core-3.3</Name>
    7291    </ProjectReference>
     92    <ProjectReference Include="..\..\HeuristicLab.Data.Views\3.3\HeuristicLab.Data.Views-3.3.csproj">
     93      <Project>{72104A0B-90E7-42F3-9ABE-9BBBADD4B943}</Project>
     94      <Name>HeuristicLab.Data.Views-3.3</Name>
     95    </ProjectReference>
    7396    <ProjectReference Include="..\..\HeuristicLab.Data\3.3\HeuristicLab.Data-3.3.csproj">
    7497      <Project>{BBAB9DF5-5EF3-4BA8-ADE9-B36E82114937}</Project>
     
    83106      <Name>HeuristicLab.Encodings.PermutationEncoding-3.3</Name>
    84107    </ProjectReference>
     108    <ProjectReference Include="..\..\HeuristicLab.Encodings.SchedulingEncoding\3.3\HeuristicLab.Encodings.SchedulingEncoding-3.3.csproj">
     109      <Project>{17F3EF80-B2C3-4B8D-A4D5-BE9CE3BA2606}</Project>
     110      <Name>HeuristicLab.Encodings.SchedulingEncoding-3.3</Name>
     111    </ProjectReference>
     112    <ProjectReference Include="..\..\HeuristicLab.Encodings.SymbolicExpressionTreeEncoding\3.4\HeuristicLab.Encodings.SymbolicExpressionTreeEncoding-3.4.csproj">
     113      <Project>{06D4A186-9319-48A0-BADE-A2058D462EEA}</Project>
     114      <Name>HeuristicLab.Encodings.SymbolicExpressionTreeEncoding-3.4</Name>
     115    </ProjectReference>
     116    <ProjectReference Include="..\..\HeuristicLab.MainForm.WindowsForms\3.3\HeuristicLab.MainForm.WindowsForms-3.3.csproj">
     117      <Project>{AB687BBE-1BFE-476B-906D-44237135431D}</Project>
     118      <Name>HeuristicLab.MainForm.WindowsForms-3.3</Name>
     119    </ProjectReference>
     120    <ProjectReference Include="..\..\HeuristicLab.MainForm\3.3\HeuristicLab.MainForm-3.3.csproj">
     121      <Project>{3BD61258-31DA-4B09-89C0-4F71FEF5F05A}</Project>
     122      <Name>HeuristicLab.MainForm-3.3</Name>
     123    </ProjectReference>
    85124    <ProjectReference Include="..\..\HeuristicLab.Operators\3.3\HeuristicLab.Operators-3.3.csproj">
    86125      <Project>{23DA7FF4-D5B8-41B6-AA96-F0561D24F3EE}</Project>
    87126      <Name>HeuristicLab.Operators-3.3</Name>
    88127    </ProjectReference>
     128    <ProjectReference Include="..\..\HeuristicLab.Optimization.Views\3.3\HeuristicLab.Optimization.Views-3.3.csproj">
     129      <Project>{662B4B15-8F4D-4AE5-B3EB-D91C215F5AF2}</Project>
     130      <Name>HeuristicLab.Optimization.Views-3.3</Name>
     131    </ProjectReference>
    89132    <ProjectReference Include="..\..\HeuristicLab.Optimization\3.3\HeuristicLab.Optimization-3.3.csproj">
    90133      <Project>{14AB8D24-25BC-400C-A846-4627AA945192}</Project>
     
    103146      <Name>HeuristicLab.PluginInfrastructure-3.3</Name>
    104147    </ProjectReference>
     148    <ProjectReference Include="..\..\HeuristicLab.Problems.DataAnalysis.Symbolic.Regression.Views\3.4\HeuristicLab.Problems.DataAnalysis.Symbolic.Regression.Views-3.4.csproj">
     149      <Project>{20831A74-D18F-42D9-A667-1CE3AF53DF93}</Project>
     150      <Name>HeuristicLab.Problems.DataAnalysis.Symbolic.Regression.Views-3.4</Name>
     151    </ProjectReference>
     152    <ProjectReference Include="..\..\HeuristicLab.Problems.DataAnalysis.Symbolic.Regression\3.4\HeuristicLab.Problems.DataAnalysis.Symbolic.Regression-3.4.csproj">
     153      <Project>{5AC82412-911B-4FA2-A013-EDC5E3F3FCC2}</Project>
     154      <Name>HeuristicLab.Problems.DataAnalysis.Symbolic.Regression-3.4</Name>
     155    </ProjectReference>
     156    <ProjectReference Include="..\..\HeuristicLab.Problems.DataAnalysis.Symbolic.Views\3.4\HeuristicLab.Problems.DataAnalysis.Symbolic.Views-3.4.csproj">
     157      <Project>{7A2531CE-3F7C-4F13-BCCA-ED6DC27A7086}</Project>
     158      <Name>HeuristicLab.Problems.DataAnalysis.Symbolic.Views-3.4</Name>
     159    </ProjectReference>
     160    <ProjectReference Include="..\..\HeuristicLab.Problems.DataAnalysis.Symbolic\3.4\HeuristicLab.Problems.DataAnalysis.Symbolic-3.4.csproj">
     161      <Project>{3D28463F-EC96-4D82-AFEE-38BE91A0CA00}</Project>
     162      <Name>HeuristicLab.Problems.DataAnalysis.Symbolic-3.4</Name>
     163    </ProjectReference>
     164    <ProjectReference Include="..\..\HeuristicLab.Problems.DataAnalysis.Views\3.4\HeuristicLab.Problems.DataAnalysis.Views-3.4.csproj">
     165      <Project>{3E9E8944-44FF-40BB-A622-3A4A7DD0F198}</Project>
     166      <Name>HeuristicLab.Problems.DataAnalysis.Views-3.4</Name>
     167    </ProjectReference>
     168    <ProjectReference Include="..\..\HeuristicLab.Problems.DataAnalysis\3.4\HeuristicLab.Problems.DataAnalysis-3.4.csproj">
     169      <Project>{DF87C13E-A889-46FF-8153-66DCAA8C5674}</Project>
     170      <Name>HeuristicLab.Problems.DataAnalysis-3.4</Name>
     171    </ProjectReference>
     172    <ProjectReference Include="..\..\HeuristicLab.Problems.Scheduling\3.3\HeuristicLab.Problems.Scheduling-3.3.csproj">
     173      <Project>{2BF1D639-1A74-44ED-AAAD-41ECD395AD93}</Project>
     174      <Name>HeuristicLab.Problems.Scheduling-3.3</Name>
     175    </ProjectReference>
     176    <ProjectReference Include="..\..\HeuristicLab.Problems.VehicleRouting\3.3\HeuristicLab.Problems.VehicleRouting-3.3.csproj">
     177      <Project>{6410BDA6-3641-42B2-BABA-AA626E2F6F71}</Project>
     178      <Name>HeuristicLab.Problems.VehicleRouting-3.3</Name>
     179    </ProjectReference>
     180    <ProjectReference Include="..\..\HeuristicLab.Visualization.ChartControlsExtensions\3.3\HeuristicLab.Visualization.ChartControlsExtensions-3.3.csproj">
     181      <Project>{315BDA09-3F4F-49B3-9790-B37CFC1C5750}</Project>
     182      <Name>HeuristicLab.Visualization.ChartControlsExtensions-3.3</Name>
     183    </ProjectReference>
     184  </ItemGroup>
     185  <ItemGroup>
     186    <EmbeddedResource Include="GanttChart.resx">
     187      <DependentUpon>GanttChart.cs</DependentUpon>
     188    </EmbeddedResource>
     189    <EmbeddedResource Include="ScheduleView.resx">
     190      <DependentUpon>ScheduleView.cs</DependentUpon>
     191    </EmbeddedResource>
    105192  </ItemGroup>
    106193  <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
  • branches/Scheduling/HeuristicLab.Encodings.SchedulingEncoding.Views/3.3/Plugin.cs

    r6297 r6364  
    2222using HeuristicLab.PluginInfrastructure;
    2323
    24 namespace HeuristicLab.Encodings.SchedulingEncoding.View {
    25   [Plugin("HeuristicLab.Encodings.SchedulingEncoding.View", "3.3.3.0")]
    26   [PluginFile("HeuristicLab.Encodings.SchedulingEncoding.View-3.3.dll", PluginFileType.Assembly)]
    27   public class HeuristicLabEncodingsSchedulingEncodingViewPlugin : PluginBase {
     24namespace HeuristicLab.Encodings.SchedulingEncoding.Views {
     25  [Plugin("HeuristicLab.Encodings.SchedulingEncoding.Views", "3.3.3.6297")]
     26  [PluginFile("HeuristicLab.Encodings.SchedulingEncoding.Views-3.3.dll", PluginFileType.Assembly)]
     27  public class HeuristicLabEncodingsSchedulingEncodingViewsPlugin : PluginBase {
    2828  }
    2929}
  • branches/Scheduling/HeuristicLab.Encodings.SchedulingEncoding.Views/3.3/Plugin.cs.frame

    r6297 r6364  
    2222using HeuristicLab.PluginInfrastructure;
    2323
    24 namespace HeuristicLab.Encodings.SchedulingEncoding.View {
    25   [Plugin("HeuristicLab.Encodings.SchedulingEncoding.View", "3.3.3.$WCREV$")]
    26   [PluginFile("HeuristicLab.Encodings.SchedulingEncoding.View-3.3.dll", PluginFileType.Assembly)]
    27   public class HeuristicLabEncodingsSchedulingEncodingViewPlugin : PluginBase {
     24namespace HeuristicLab.Encodings.SchedulingEncoding.Views {
     25  [Plugin("HeuristicLab.Encodings.SchedulingEncoding.Views", "3.3.3.$WCREV$")]
     26  [PluginFile("HeuristicLab.Encodings.SchedulingEncoding.Views-3.3.dll", PluginFileType.Assembly)]
     27  public class HeuristicLabEncodingsSchedulingEncodingViewsPlugin : PluginBase {
    2828  }
    2929}
  • branches/Scheduling/HeuristicLab.Encodings.SchedulingEncoding.Views/3.3/ScheduleView.Designer.cs

    r6292 r6364  
    1 namespace HeuristicLab.Problems.Scheduling.Views {
     1namespace HeuristicLab.Encodings.SchedulingEncoding.Views {
    22  partial class ScheduleView {
    33    /// <summary>
     
    2424    /// </summary>
    2525    private void InitializeComponent() {
    26       this.ganttChart = new HeuristicLab.Problems.Scheduling.Views.GanttChart();
     26      this.ganttChart = new GanttChart();
    2727      ((System.ComponentModel.ISupportInitialize)(this.errorProvider)).BeginInit();
    2828      this.SuspendLayout();
  • branches/Scheduling/HeuristicLab.Encodings.SchedulingEncoding.Views/3.3/ScheduleView.cs

    r6294 r6364  
    3333using HeuristicLab.Encodings.SchedulingEncoding;
    3434
    35 namespace HeuristicLab.Problems.Scheduling.Views {
     35namespace HeuristicLab.Encodings.SchedulingEncoding.Views {
    3636  [View("Schedule View")]
    3737  [Content(typeof(Schedule), true)]
  • branches/Scheduling/HeuristicLab.Encodings.SchedulingEncoding/3.3/HeuristicLab.Encodings.SchedulingEncoding-3.3.csproj

    r6294 r6364  
    4747  </ItemGroup>
    4848  <ItemGroup>
     49    <Compile Include="Interfaces\ISchedulingEvaluationAlgorithm.cs" />
    4950    <Compile Include="Interfaces\IJSMOperator.cs" />
    5051    <Compile Include="Interfaces\IPRVOperator.cs" />
     
    8283    <Compile Include="PriorityRulesVector\PRVRandomCreator.cs" />
    8384    <Compile Include="Properties\AssemblyInfo.cs" />
    84     <Compile Include="ScheduleEncoding\IndexedScheduledTaskList.cs" />
    8585    <Compile Include="ScheduleEncoding\Resource.cs" />
    8686    <Compile Include="ScheduleEncoding\Schedule.cs" />
     
    8989    <Compile Include="SchedulingCrossover.cs" />
    9090    <Compile Include="SchedulingDecoder.cs" />
    91     <Compile Include="SchedulingEncodingTypes.cs" />
    9291    <Compile Include="SchedulingManipulator.cs" />
    9392  </ItemGroup>
     
    148147  <ItemGroup />
    149148  <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
     149  <PropertyGroup>
     150    <PreBuildEvent>set Path=%25Path%25;$(ProjectDir);$(SolutionDir)
     151set ProjectDir=$(ProjectDir)
     152set SolutionDir=$(SolutionDir)
     153set Outdir=$(Outdir)
     154
     155call PreBuildEvent.cmd
     156SubWCRev "%25ProjectDir%25\" "%25ProjectDir%25\Plugin.cs.frame" "%25ProjectDir%25\Plugin.cs"</PreBuildEvent>
     157  </PropertyGroup>
    150158  <!-- To modify your build process, add your task inside one of the targets below and uncomment it.
    151159       Other similar extension points exist, see Microsoft.Common.targets.
  • branches/Scheduling/HeuristicLab.Encodings.SchedulingEncoding/3.3/JobSequenceMatrix/JSMEncoding.cs

    r6294 r6364  
    3232
    3333namespace HeuristicLab.Encodings.SchedulingEncoding.JobSequenceMatrix {
    34   [Item("Job Sequencing Matrix Encoding", "Represents a solution for a standard JobShop Scheduling Problem.")]
     34  [Item("Job Sequence Matrix Encoding", "Represents a solution for a standard JobShop Scheduling Problem.")]
    3535  [StorableClass]
    3636  public class JSMEncoding : ParameterizedNamedItem, ISchedulingEncoding{
  • branches/Scheduling/HeuristicLab.Encodings.SchedulingEncoding/3.3/JobSequenceMatrix/JSMRandomCreator.cs

    r6294 r6364  
    3434
    3535namespace HeuristicLab.Encodings.SchedulingEncoding.JobSequenceMatrix {
    36   [Item("Job Sequencing Matrix Creator", "Creator class used to create Job Sequencing Matrix solutions for standard JobShop scheduling problems.")]
     36  [Item("Job Sequence Matrix Creator", "Creator class used to create Job Sequence Matrix solutions for standard JobShop scheduling problems.")]
    3737  [StorableClass]
    3838  public class JSMRandomCreator : SchedulingCreator<JSMEncoding>, IStochasticOperator {
  • branches/Scheduling/HeuristicLab.Encodings.SchedulingEncoding/3.3/JobSequenceMatrix/Manipulators/JSMManipulator.cs

    r6294 r6364  
    2929
    3030namespace HeuristicLab.Encodings.SchedulingEncoding.JobSequenceMatrix.Manipulators {
    31   [Item("AlbaManipulator", "An operator which manipulates a VRP representation.")]
     31  [Item("JSMManipulator", "An operator which manipulates a JSM representation.")]
    3232  [StorableClass]
    3333  public abstract class JSMManipulator : SchedulingManipulator<JSMEncoding>, IJSMOperator {
  • branches/Scheduling/HeuristicLab.Encodings.SchedulingEncoding/3.3/JobSequenceMatrix/Manipulators/JSMShiftChangeManipulator.cs

    r6294 r6364  
    3131namespace HeuristicLab.Encodings.SchedulingEncoding.JobSequenceMatrix.Manipulators {
    3232
    33   [Item("JSM Shift Change Manipulator", "Represents a manipulation operation inserting parts of the individual at another position.")]
     33  [Item("JSM Shift Change Manipulator", "Represents a manipulation operation where the operations of a randomly determined job are shifted in one direction for all resources.")]
    3434  [StorableClass]
    3535  public class JSMShiftChangeManipulator : JSMManipulator {
  • branches/Scheduling/HeuristicLab.Encodings.SchedulingEncoding/3.3/JobSequenceMatrix/Manipulators/JSMSwapManipulator.cs

    r6294 r6364  
    3131namespace HeuristicLab.Encodings.SchedulingEncoding.JobSequenceMatrix.Manipulators {
    3232
    33   [Item("JSM Swap Manipulator", "Represents a manipulation operation inserting parts of the individual at another position.")]
     33  [Item("JSM Swap Manipulator", "Represents a manipulation operation swapping parts of the individual.")]
    3434  [StorableClass]
    3535  public class JSMSwapManipulator : JSMManipulator {
  • branches/Scheduling/HeuristicLab.Encodings.SchedulingEncoding/3.3/Plugin.cs

    r6294 r6364  
    2323
    2424namespace HeuristicLab.Encodings.SchedulingEncoding {
    25   [Plugin("HeuristicLab.Encodings.SchedulingEncoding", "3.3.3.6266")]
     25  [Plugin("HeuristicLab.Encodings.SchedulingEncoding", "3.3.3.6294")]
    2626  [PluginFile("HeuristicLab.Encodings.SchedulingEncoding-3.3.dll", PluginFileType.Assembly)]
    2727  public class HeuristicLabEncodingsSchedulingEncodingPlugin : PluginBase {
  • branches/Scheduling/HeuristicLab.Encodings.SchedulingEncoding/3.3/ScheduleEncoding/Resource.cs

    r6294 r6364  
    3333  [Item("Resource Class", "Represents a resource used in scheduling problems.")]
    3434  [StorableClass]
    35   public class Resource : IndexedScheduledTaskList {
     35  public class Resource : Item {
    3636    [StorableConstructor]
    3737    protected Resource(bool deserializing) : base(deserializing) { }
    3838    protected Resource(Resource original, Cloner cloner)
    3939      : base(original, cloner) {
     40        this.Index = cloner.Clone(original.Index);
     41        this.Tasks = cloner.Clone(original.Tasks);
    4042    }
    4143    public override IDeepCloneable Clone(Cloner cloner) {
     
    4345    }
    4446
    45     public Resource(IntValue index) : base (index) { }
     47    public Resource(IntValue index) : base () {
     48      Index = index;
     49      Tasks = new ItemList<ScheduledTask>();
     50    }
     51
     52    public IntValue Index {
     53      get;
     54      set;
     55    }
     56    public ItemList<ScheduledTask> Tasks {
     57      get;
     58      set;
     59    }
     60
     61
     62    public DoubleValue TotalDuration {
     63      get {
     64        double result = 0;
     65        foreach (ScheduledTask t in Tasks) {
     66          if (t.EndTime.Value > result)
     67            result = t.EndTime.Value;
     68        }
     69        return new DoubleValue(result);
     70      }
     71    }
    4672
    4773    public override string ToString() {
  • branches/Scheduling/HeuristicLab.Problems.Scheduling.Views/3.3/HeuristicLab.Problems.Scheduling.Views-3.3.csproj

    r6294 r6364  
    6262  </ItemGroup>
    6363  <ItemGroup>
    64     <Compile Include="GanttChart.cs">
    65       <SubType>UserControl</SubType>
    66     </Compile>
    67     <Compile Include="GanttChart.Designer.cs">
    68       <DependentUpon>GanttChart.cs</DependentUpon>
    69     </Compile>
    7064    <Compile Include="JobShopSchedulingProblemView.cs">
    7165      <SubType>UserControl</SubType>
     
    7670    <Compile Include="Plugin.cs" />
    7771    <Compile Include="Properties\AssemblyInfo.cs" />
    78     <Compile Include="ScheduleView.cs">
    79       <SubType>UserControl</SubType>
    80     </Compile>
    81     <Compile Include="ScheduleView.Designer.cs">
    82       <DependentUpon>ScheduleView.cs</DependentUpon>
    83     </Compile>
    8472    <Compile Include="SchedulingProblemImportDialog.cs">
    8573      <SubType>Form</SubType>
     
    126114      <Project>{DBECB8B0-B166-4133-BAF1-ED67C3FD7FCA}</Project>
    127115      <Name>HeuristicLab.Encodings.PermutationEncoding-3.3</Name>
     116    </ProjectReference>
     117    <ProjectReference Include="..\..\HeuristicLab.Encodings.SchedulingEncoding.Views\3.3\HeuristicLab.Encodings.SchedulingEncoding.Views-3.3.csproj">
     118      <Project>{0C378762-D5DB-488A-8931-2BA42B1B7CBF}</Project>
     119      <Name>HeuristicLab.Encodings.SchedulingEncoding.Views-3.3</Name>
    128120    </ProjectReference>
    129121    <ProjectReference Include="..\..\HeuristicLab.Encodings.SchedulingEncoding\3.3\HeuristicLab.Encodings.SchedulingEncoding-3.3.csproj">
     
    181173  </ItemGroup>
    182174  <ItemGroup>
    183     <EmbeddedResource Include="GanttChart.resx">
    184       <DependentUpon>GanttChart.cs</DependentUpon>
    185     </EmbeddedResource>
    186175    <EmbeddedResource Include="JobShopSchedulingProblemView.resx">
    187176      <DependentUpon>JobShopSchedulingProblemView.cs</DependentUpon>
    188     </EmbeddedResource>
    189     <EmbeddedResource Include="ScheduleView.resx">
    190       <DependentUpon>ScheduleView.cs</DependentUpon>
    191177    </EmbeddedResource>
    192178    <EmbeddedResource Include="SchedulingProblemImportDialog.resx">
  • branches/Scheduling/HeuristicLab.Problems.Scheduling.Views/3.3/JobShopSchedulingProblemView.Designer.cs

    r6260 r6364  
    1 namespace HeuristicLab.Problems.Scheduling.Views {
     1using HeuristicLab.Encodings.SchedulingEncoding.Views;
     2namespace HeuristicLab.Problems.Scheduling.Views {
    23  partial class JobShopSchedulingProblemView {
    34    /// <summary>
     
    2930      this.tabPage1 = new System.Windows.Forms.TabPage();
    3031      this.tabPage2 = new System.Windows.Forms.TabPage();
    31       this.ganttChart = new HeuristicLab.Problems.Scheduling.Views.GanttChart();
     32      this.ganttChart = new GanttChart();
    3233      ((System.ComponentModel.ISupportInitialize)(this.errorProvider)).BeginInit();
    3334      this.tabControl1.SuspendLayout();
  • branches/Scheduling/HeuristicLab.Problems.Scheduling.Views/3.3/Plugin.cs

    r6294 r6364  
    2323
    2424namespace HeuristicLab.Problems.Scheduling.Views {
    25   [Plugin("HeuristicLab.Problems.Scheduling.Views", "3.3.3.6266")]
     25  [Plugin("HeuristicLab.Problems.Scheduling.Views", "3.3.3.6294")]
    2626  [PluginFile("HeuristicLab.Problems.Scheduling.Views-3.3.dll", PluginFileType.Assembly)]
    2727  public class HeuristicLabProblemsSchedulingViewsPlugin : PluginBase {
  • branches/Scheduling/HeuristicLab.Problems.Scheduling.Views/3.3/Properties/AssemblyInfo.cs

    r6294 r6364  
    5353// by using the '*' as shown below:
    5454[assembly: AssemblyVersion("3.3.0.0")]
    55 [assembly: AssemblyFileVersion("3.3.0.6266")]
     55[assembly: AssemblyFileVersion("3.3.0.6294")]
  • branches/Scheduling/HeuristicLab.Problems.Scheduling/3.3/Decoders/JSMDecoder.cs

    r6293 r6364  
    3636
    3737namespace HeuristicLab.Problems.Scheduling.Decoders {
    38   [Item("Job Sequencing Matrix Decoder", "Applies the GifflerThompson algorithm to create an active schedule from a JobSequencing Matrix.")]
     38  [Item("Job Sequence Matrix Decoder", "Applies the GifflerThompson algorithm to create an active schedule from a JobSequence Matrix.")]
    3939  [StorableClass]
    4040  public class JSMDecoder : SchedulingDecoder<JSMEncoding>, IStochasticOperator, IJSSPOperator {
     
    7676      : base() {
    7777      Parameters.Add(new LookupParameter<IRandom>("Random", "The pseudo random number generator which should be used for stochastic manipulation operators."));
    78       Parameters.Add(new LookupParameter<ItemList<Job>>("JobData", "Job data taken from the JSSP - Instance."));
     78      Parameters.Add(new LookupParameter<ItemList<Job>>("JobData", "Job data taken from the Schedulingproblem - Instance."));
    7979    }
    8080
  • branches/Scheduling/HeuristicLab.Problems.Scheduling/3.3/Decoders/PRVDecoder.cs

    r6293 r6364  
    197197    }
    198198
    199     private ItemList<Task> GetEarliestNotScheduledTasks() {
    200       ItemList<Task> result = new ItemList<Task>();
    201       foreach (Job j in jobs) {
    202         foreach (Task t in j.Tasks) {
    203           if (!t.IsScheduled.Value) {
    204             result.Add(t);
    205             break;
    206           }
    207         }
    208       }
    209       return result;
    210     }
    211     private Task GetTaskWithMinimalEC(ItemList<Task> earliestTasksList) {
    212       double minEct = double.MaxValue;
    213       Task result = null;
    214       foreach (Task t in earliestTasksList) {
    215         double ect = GTAlgorithmUtils.ComputeEarliestCompletionTime(t, resultingSchedule);
    216         if (ect < minEct) {
    217           result = t;
    218           minEct = ect;
    219         }
    220       }
    221       return result;
    222     }
    223     private ItemList<Task> GetConflictSetForTask(Task conflictedTask, ItemList<Task> earliestTasksList) {
    224       ItemList<Task> result = new ItemList<Task>();
    225       double conflictedCompletionTime = GTAlgorithmUtils.ComputeEarliestCompletionTime(conflictedTask, resultingSchedule);
    226       foreach (Task t in earliestTasksList) {
    227         if (t.ResourceNr.Value == conflictedTask.ResourceNr.Value) {
    228           if (GTAlgorithmUtils.ComputeEarliestStartTime(t, resultingSchedule) < conflictedCompletionTime)
    229             result.Add(t);
    230         }
    231       }
    232       return result;
    233     }
     199
     200
    234201    private Task SelectTaskFromConflictSet(ItemList<Task> conflictSet, int ruleIndex, int nrOfRules) {
    235202      if (conflictSet.Count == 1)
    236203        return conflictSet[0];
    237      
     204
    238205      ruleIndex = ruleIndex % nrOfRules;
    239206      switch (ruleIndex) {
     
    249216        case 9: return RandomRule(conflictSet);
    250217        default: return RandomRule(conflictSet);
    251       } 
     218      }
    252219    }
    253220
     
    265232      //GT-Algorithm
    266233      //STEP 0 - Compute a list of "earliest operations"
    267       ItemList<Task> earliestTasksList = GetEarliestNotScheduledTasks();
    268       int currentDecisionIndex = 0;
     234      ItemList<Task> earliestTasksList = GTAlgorithmUtils.GetEarliestNotScheduledTasks(jobs);
     235      //int currentDecisionIndex = 0;
    269236      while (earliestTasksList.Count > 0) {
    270237        //STEP 1 - Get earliest not scheduled operation with minimal earliest completing time
    271         Task minimal = GetTaskWithMinimalEC(earliestTasksList);
     238        Task minimal = GTAlgorithmUtils.GetTaskWithMinimalEC(earliestTasksList, resultingSchedule);
    272239
    273240        //STEP 2 - Compute a conflict set of all operations that can be scheduled on the machine the previously selected operation runs on
    274         ItemList<Task> conflictSet = GetConflictSetForTask(minimal, earliestTasksList);
     241        ItemList<Task> conflictSet = GTAlgorithmUtils.GetConflictSetForTask(minimal, earliestTasksList, jobs, resultingSchedule);
    275242
    276243        //STEP 3 - Select an operation from the conflict set (various methods depending on how the algorithm should work..)
    277         Task selectedTask = SelectTaskFromConflictSet(conflictSet, solution.PriorityRulesVector [currentDecisionIndex++], solution.NrOfRules.Value);
     244        //Task selectedTask = SelectTaskFromConflictSet(conflictSet, solution.PriorityRulesVector [currentDecisionIndex++], solution.NrOfRules.Value);
     245        Task selectedTask = SelectTaskFromConflictSet(conflictSet, solution.PriorityRulesVector[minimal.JobNr.Value], solution.NrOfRules.Value);
    278246
    279247        //STEP 4 - Adding the selected operation to the current schedule
     
    283251
    284252        //STEP 5 - Back to STEP 1
    285         earliestTasksList = GetEarliestNotScheduledTasks();
     253        earliestTasksList = GTAlgorithmUtils.GetEarliestNotScheduledTasks(jobs);
    286254      }
    287255
  • branches/Scheduling/HeuristicLab.Problems.Scheduling/3.3/Evaluators/MeanTardinessEvaluator.cs

    r6293 r6364  
    3131using HeuristicLab.Parameters;
    3232using HeuristicLab.Encodings.SchedulingEncoding;
     33using HeuristicLab.Problems.Scheduling.Interfaces;
    3334
    3435namespace HeuristicLab.Problems.Scheduling.Evaluators {
    35   [Item("Men tardiness Evaluator", "Represents an evaluator using the mean tardiness of a schedule.")]
     36  [Item("Mean tardiness Evaluator", "Represents an evaluator using the mean tardiness of a schedule.")]
    3637  [StorableClass]
    37   public class MeanTardinessEvaluator : SchedulingEvaluator {
     38  public class MeanTardinessEvaluator : SchedulingEvaluator, IJSSPOperator {
    3839    [StorableConstructor]
    3940    protected MeanTardinessEvaluator(bool deserializing) : base(deserializing) { }
     
    4647
    4748    #region Parameter Properties
    48     public ILookupParameter<ItemList<Job>> JobsParameter {
    49       get { return (ILookupParameter<ItemList<Job>>)Parameters["Jobs"]; }
     49    public ILookupParameter<ItemList<Job>> JobDataParameter {
     50      get { return (ILookupParameter<ItemList<Job>>)Parameters["JobData"]; }
    5051    }
    5152    #endregion
    5253    #region Properties
    53     public ItemList<Job> Jobs {
    54       get { return JobsParameter.ActualValue; }
     54    public ItemList<Job> JobData {
     55      get { return JobDataParameter.ActualValue; }
    5556    }
    5657    #endregion
    5758
    5859    public MeanTardinessEvaluator() : base() {
    59       Parameters.Add(new LookupParameter<ItemList<Job>>("Jobs", "Jobdata defining the precedence relationships and the duration of the tasks in this JSSP-Instance."));
     60      Parameters.Add(new LookupParameter<ItemList<Job>>("JobData", "Jobdata defining the precedence relationships and the duration of the tasks in this JSSP-Instance."));
    6061    }
    6162
     
    6364      double totalTardiness = 0;
    6465      foreach (Resource r in schedule.Resources) {
    65         double tardiness = r.Tasks[r.Tasks.Count - 1].EndTime.Value - Jobs[r.Tasks[r.Tasks.Count - 1].JobNr.Value].DueDate.Value;
     66        double tardiness = r.Tasks[r.Tasks.Count - 1].EndTime.Value - JobData[r.Tasks[r.Tasks.Count - 1].JobNr.Value].DueDate.Value;
    6667        if (tardiness > 0)
    6768          totalTardiness += tardiness;
  • branches/Scheduling/HeuristicLab.Problems.Scheduling/3.3/Evaluators/SchedulingEvaluationAlgorithm.cs

    r6293 r6364  
    3535
    3636namespace HeuristicLab.Problems.Scheduling.Evaluators {
    37   [Item("Scheduling Evaluator", "Represents a general evaluator class for scheduling problems.")]
     37  [Item("Scheduling Evaluation Algorithm", "Represents a composition of a decoder and an evaluator for scheduling problems.")]
    3838  [StorableClass]
    39   public class SchedulingEvaluationAlgorithm : AlgorithmOperator, ISchedulingEvaluator {
     39  public class SchedulingEvaluationAlgorithm : AlgorithmOperator, ISchedulingEvaluationAlgorithm {
    4040    [StorableConstructor]
    4141    protected SchedulingEvaluationAlgorithm(bool deserializing) : base(deserializing) { }
    4242    protected SchedulingEvaluationAlgorithm(SchedulingEvaluationAlgorithm original, Cloner cloner)
    4343      : base(original, cloner) {
     44        this.evaluator = cloner.Clone(original.evaluator);
    4445    }
    4546    public override IDeepCloneable Clone(Cloner cloner) {
    4647      return new SchedulingEvaluationAlgorithm(this, cloner);
    4748    }
     49
     50    [Storable]
     51    private Placeholder evaluator;
    4852
    4953    public ILookupParameter<DoubleValue> QualityParameter {
     
    5660    }
    5761
    58     public void InitializeOperatorGraph<T>(SchedulingDecoder<T> decoder, SchedulingEvaluator evaluator) where T: Item, ISchedulingEncoding{
     62    public void InitializeOperatorGraph<T>(SchedulingDecoder<T> decoder) where T: Item, ISchedulingEncoding{
    5963      OperatorGraph.Operators.Clear();
    6064      OperatorGraph.InitialOperator = decoder;
     
    6569      : base() {
    6670        Parameters.Add(new LookupParameter<DoubleValue>("Quality", "The quality value aka fitness value of the solution."));
     71        evaluator = new Placeholder();
     72        evaluator.OperatorParameter.ActualName = "SolutionEvaluator";
    6773    }
    6874
  • branches/Scheduling/HeuristicLab.Problems.Scheduling/3.3/Evaluators/SchedulingEvaluator.cs

    r6293 r6364  
    3535
    3636namespace HeuristicLab.Problems.Scheduling.Evaluators {
    37   [Item("JSSP Evaluator", "Represents a evaluator class for standard job shop scheduling problems.")]
     37  [Item("Scheduling Evaluator", "Represents a evaluator class for standard scheduling problems.")]
    3838  [StorableClass]
    3939  public abstract class SchedulingEvaluator : SingleSuccessorOperator, ISchedulingEvaluator {
  • branches/Scheduling/HeuristicLab.Problems.Scheduling/3.3/HeuristicLab.Problems.Scheduling-3.3.csproj

    r6293 r6364  
    5656    <Compile Include="Decoders\PRVDecoder.cs" />
    5757    <Compile Include="Decoders\PWRDecoder.cs" />
    58     <Compile Include="Evaluators\SchedulingEvaluatorType.cs" />
    59     <Compile Include="Evaluators\SchedulingEvaluatorTypes.cs" />
    6058    <Compile Include="Evaluators\MeanTardinessEvaluator.cs" />
    6159    <Compile Include="Evaluators\MakespanEvaluator.cs" />
  • branches/Scheduling/HeuristicLab.Problems.Scheduling/3.3/Job.cs

    r6293 r6364  
    3131
    3232namespace HeuristicLab.Problems.Scheduling {
    33   [Item("Job Class", "Represents a composition of tasks that require processing in a job shop scheduling problem.")]
     33  [Item("Job Class", "Represents a composition of tasks that require processing in a scheduling problem.")]
    3434  [StorableClass]
    35   public class Job : IndexedTaskList {
     35  public class Job : Item {
    3636    [StorableConstructor]
    3737    protected Job(bool deserializing) : base(deserializing) { }
     
    3939      : base(original, cloner) {
    4040        this.DueDate = cloner.Clone(original.DueDate);
     41        this.Index = cloner.Clone(original.Index);
     42        this.Tasks = cloner.Clone(original.Tasks);
    4143    }
    4244    public override IDeepCloneable Clone(Cloner cloner) {
     
    4648    public DoubleValue DueDate { get; set; }
    4749
    48     public Job(IntValue index, DoubleValue dueDate) : base (index) {
     50    public IntValue Index {
     51      get;
     52      set;
     53    }
     54    public ItemList<Task> Tasks {
     55      get;
     56      set;
     57    }
     58
     59
     60    public Job(IntValue index, DoubleValue dueDate) : base () {
     61      Index = index;
     62      Tasks = new ItemList<Task>();
     63
    4964      if (dueDate != null)
    5065        DueDate = (DoubleValue)dueDate.Clone();
  • branches/Scheduling/HeuristicLab.Problems.Scheduling/3.3/JobShopSchedulingProblem.cs

    r6293 r6364  
    5252    private JobShopSchedulingProblem(JobShopSchedulingProblem original, Cloner cloner)
    5353      : base(original, cloner) {
    54       this.encodingType = original.encodingType;
    5554      this.Jobs = cloner.Clone(original.Jobs);
    56       this.EvaluatorType = cloner.Clone(original.EvaluatorType);
    57         AttachEventHandlers();
     55      this.Resources = cloner.Clone(original.Resources);
     56      this.JobData = cloner.Clone(original.JobData);
     57      this.SolutionEvaluator = cloner.Clone(original.SolutionEvaluator);
     58      this.DueDates = cloner.Clone(original.DueDates);
    5859    }
    5960    public override IDeepCloneable Clone(Cloner cloner) {
     
    6667      get { return (ValueParameter<ItemList<Job>>)Parameters["JobData"]; }
    6768    }
    68     public ValueParameter<SchedulingEvaluatorType> EvaluatorTypeParameter {
    69       get { return (ValueParameter<SchedulingEvaluatorType>)Parameters["EvaluatorType"]; }
    70     }
    7169    public OptionalValueParameter<Schedule> BestKnownSolutionParameter {
    7270      get { return (OptionalValueParameter<Schedule>)Parameters["BestKnownSolution"]; }
     
    7977      get { return (ValueParameter<IntValue>)Parameters["Resources"]; }
    8078    }
    81 
     79    public ValueParameter<SchedulingEvaluator> SolutionEvaluatorParameter {
     80      get { return (ValueParameter<SchedulingEvaluator>)Parameters["SolutionEvaluator"]; }
     81    }
     82    public ValueParameter<BoolValue> DueDatesParameter {
     83      get { return (ValueParameter<BoolValue>)Parameters["DueDates"]; }
     84    }
    8285    #endregion
    8386
     
    8790      set { JobDataParameter.Value = value; }
    8891    }
    89     public SchedulingEvaluatorType EvaluatorType {
    90       get { return EvaluatorTypeParameter.Value; }
    91       set { EvaluatorTypeParameter.Value = value; }
    92     }
    9392    public Schedule BestKnownSolution {
    9493      get { return BestKnownSolutionParameter.Value; }
     
    103102      set { ResourcesParameter.Value = value; }
    104103    }
    105     #endregion
    106 
    107     [Storable]
    108     private SchedulingEncodingTypes encodingType;
     104    public SchedulingEvaluator SolutionEvaluator {
     105      get { return SolutionEvaluatorParameter.Value; }
     106      set { SolutionEvaluatorParameter.Value = value; }
     107    }
     108    public BoolValue DueDates {
     109      get { return DueDatesParameter.Value; }
     110      set { DueDatesParameter.Value = value; }
     111    }
     112    #endregion
     113
    109114
    110115    public JobShopSchedulingProblem()
    111116      : base(new SchedulingEvaluationAlgorithm (), new JSMRandomCreator ()) {
    112117      Parameters.Add(new ValueParameter<ItemList<Job>>("JobData", "Jobdata defining the precedence relationships and the duration of the tasks in this JSSP-Instance.", new ItemList<Job>()));
    113       Parameters.Add(new ValueParameter<SchedulingEvaluatorType>("EvaluatorType", "Type of the evaluator used to determine the quality of an individual.", new SchedulingEvaluatorType(SchedulingEvaluatorTypes.MakespanEvaluator)));
    114118      Parameters.Add(new OptionalValueParameter<Schedule>("BestKnownSolution", "The best known solution of this JSSP instance."));
    115      
    116       Parameters.Add(new ValueParameter<IntValue>("Jobs", "The number of jobs used in this JSSP instance.", new IntValue ()));
     119
     120      Parameters.Add(new ValueParameter<IntValue>("Jobs", "The number of jobs used in this JSSP instance.", new IntValue()));
    117121      Parameters.Add(new ValueParameter<IntValue>("Resources", "The number of resources used this JSSP instance.", new IntValue()));
    118       encodingType = SchedulingEncodingTypes.JSMEncoding;
    119         InitializeOperators();
    120         AttachEventHandlers();
     122      Parameters.Add(new ValueParameter<BoolValue>("DueDates", "Determines whether the problem instance uses due dates or not.", new BoolValue()));
     123      Parameters.Add(new ValueParameter<SchedulingEvaluator>("SolutionEvaluator", "The evaluator used to determine the quality of a solution.", new MakespanEvaluator()));
     124
     125      InitializeOperators();
     126      InitializeProblemInstance();
    121127    }
    122128
    123129    #region Events
    124     //TODO: Implement event handlers for problem specific events!
    125130    protected override void OnSolutionCreatorChanged() {
    126       if (SolutionCreator.GetType().Equals(typeof(JSMRandomCreator)))
    127         encodingType = SchedulingEncodingTypes.JSMEncoding;
    128       else {
    129         if (SolutionCreator.GetType().Equals(typeof(PRVRandomCreator)))
    130           encodingType = SchedulingEncodingTypes.PRVEncoding;
    131         else
    132           encodingType = SchedulingEncodingTypes.PWREncoding;
    133       }
    134131      InitializeOperators();
    135132    }
     
    137134
    138135    #region Helpers
     136    private void InitializeProblemInstance () {
     137      Jobs = new IntValue (10);
     138      Resources = new IntValue (10);
     139      BestKnownQuality = new DoubleValue (930);
     140      JobData = new ItemList<Job>();
     141      List<string> data = new List<string>
     142      {"0 29 1 78 2  9 3 36 4 49 5 11 6 62 7 56 8 44 9 21",
     143       "0 43 2 90 4 75 9 11 3 69 1 28 6 46 5 46 7 72 8 30",
     144       "1 91 0 85 3 39 2 74 8 90 5 10 7 12 6 89 9 45 4 33",
     145       "1 81 2 95 0 71 4 99 6  9 8 52 7 85 3 98 9 22 5 43",
     146       "2 14 0  6 1 22 5 61 3 26 4 69 8 21 7 49 9 72 6 53",
     147       "2 84 1  2 5 52 3 95 8 48 9 72 0 47 6 65 4  6 7 25",
     148       "1 46 0 37 3 61 2 13 6 32 5 21 9 32 8 89 7 30 4 55",
     149       "2 31 0 86 1 46 5 74 4 32 6 88 8 19 9 48 7 36 3 79",
     150       "0 76 1 69 3 76 5 51 2 85 9 11 6 40 7 89 4 26 8 74",
     151       "1 85 0 13 2 61 6  7 8 64 9 76 5 47 3 52 4 90 7 45" };
     152
     153      int jobCount = 0;
     154      foreach (string s in data) {
     155        List<string> split = SplitString(s);
     156        JobData.Add(CreateJobFromData(split, jobCount++));
     157      }
     158    }
     159
    139160    private void InitializeOperators() {
    140161      Operators.Clear();
    141162      ApplyEncoding();
    142163      Operators.Add(new BestSchedulingSolutionAnalyzer());
    143       //ParameterizeAnalyzer();
    144       //ParameterizeOperators();
    145164    }
    146165
    147166    private void ApplyEncoding() {
    148       if (EvaluatorType.Value == SchedulingEvaluatorTypes.MakespanEvaluator) {
    149         if (encodingType == SchedulingEncodingTypes.JSMEncoding) {
    150           Operators.AddRange(ApplicationManager.Manager.GetInstances<IJSMOperator>());
    151           ((SchedulingEvaluationAlgorithm)this.EvaluatorParameter.ActualValue).InitializeOperatorGraph<JSMEncoding>(new JSMDecoder(), new MakespanEvaluator());
     167      if (SolutionCreator.GetType().Equals(typeof(JSMRandomCreator))) {
     168        Operators.AddRange(ApplicationManager.Manager.GetInstances<IJSMOperator>());
     169        ((SchedulingEvaluationAlgorithm)this.EvaluatorParameter.ActualValue).InitializeOperatorGraph<JSMEncoding>(new JSMDecoder());
     170      } else {
     171        if (SolutionCreator.GetType().Equals(typeof(PRVRandomCreator))) {
     172          Operators.AddRange(ApplicationManager.Manager.GetInstances<IPRVOperator>());
     173          ((SchedulingEvaluationAlgorithm)this.EvaluatorParameter.ActualValue).InitializeOperatorGraph<PRVEncoding>(new PRVDecoder());
    152174        } else {
    153           if (encodingType == SchedulingEncodingTypes.PRVEncoding) {
    154             Operators.AddRange(ApplicationManager.Manager.GetInstances<IPRVOperator>());
    155             ((SchedulingEvaluationAlgorithm)this.EvaluatorParameter.ActualValue).InitializeOperatorGraph<PRVEncoding>(new PRVDecoder(), new MakespanEvaluator());
    156           } else {
    157             if (encodingType == SchedulingEncodingTypes.PWREncoding) {
    158               Operators.AddRange(ApplicationManager.Manager.GetInstances<IPWROperator>());
    159               ((SchedulingEvaluationAlgorithm)this.EvaluatorParameter.ActualValue).InitializeOperatorGraph<PWREncoding>(new PWRDecoder(), new MakespanEvaluator());
    160             }
     175          if (SolutionCreator.GetType().Equals(typeof(PWRRandomCreator))) {
     176            Operators.AddRange(ApplicationManager.Manager.GetInstances<IPWROperator>());
     177            ((SchedulingEvaluationAlgorithm)this.EvaluatorParameter.ActualValue).InitializeOperatorGraph<PWREncoding>(new PWRDecoder());
    161178          }
    162179        }
    163       } else {
    164         if (encodingType == SchedulingEncodingTypes.JSMEncoding) {
    165           Operators.AddRange(ApplicationManager.Manager.GetInstances<IJSMOperator>());
    166           ((SchedulingEvaluationAlgorithm)this.EvaluatorParameter.ActualValue).InitializeOperatorGraph<JSMEncoding>(new JSMDecoder(), new MeanTardinessEvaluator());
    167         } else {
    168           if (encodingType == SchedulingEncodingTypes.PRVEncoding) {
    169             Operators.AddRange(ApplicationManager.Manager.GetInstances<IPRVOperator>());
    170             ((SchedulingEvaluationAlgorithm)this.EvaluatorParameter.ActualValue).InitializeOperatorGraph<PRVEncoding>(new PRVDecoder(), new MeanTardinessEvaluator());
    171           } else {
    172             if (encodingType == SchedulingEncodingTypes.PWREncoding) {
    173               Operators.AddRange(ApplicationManager.Manager.GetInstances<IPWROperator>());
    174               ((SchedulingEvaluationAlgorithm)this.EvaluatorParameter.ActualValue).InitializeOperatorGraph<PWREncoding>(new PWRDecoder(), new MeanTardinessEvaluator());
    175             }
    176           }
    177         }
    178       }
    179     }
    180 
    181     private void AttachEventHandlers() {
    182       //TODO: Attach event handlers implemented aabove to appropriate events of the problem.
    183     }
    184 
    185     private void ParameterizeOperators() {
    186       throw new NotImplementedException();
    187     }
    188 
    189     private void ParameterizeAnalyzer() {
    190       throw new NotImplementedException();
     180      }
    191181    }
    192182    #endregion
     
    213203      return arr;
    214204    }
     205    private Job CreateJobFromData (List<string> data, int jobCount)   {
     206      DoubleValue dueDate = null;
     207      int dataCount = data.Count;
     208      if (DueDates.Value) {
     209        dueDate = new DoubleValue(Double.Parse(data[data.Count - 1]));
     210        dataCount--;
     211      }
     212      Job j = new Job(new IntValue(jobCount), dueDate);
     213      for (int i = 0; i < dataCount; i++) {
     214        Task t = new Task(i / 2, Int32.Parse(data[i]), jobCount, Double.Parse(data[i + 1]));
     215        j.Tasks.Add(t);
     216        i++;
     217      }//for
     218      return j;
     219    }
     220
    215221    public void ImportFromORLibrary(string fileName) {
    216222      if (!File.Exists(fileName))
     
    231237          //data[2] = bestKnownQuality (double)
    232238          //data[3] = dueDates (0|1)
    233           bool withDueDates = false;
     239          DueDates.Value = false;
    234240          if (data.Count > 2)
    235241            BestKnownQualityParameter.ActualValue = new DoubleValue(Double.Parse (data[2]));
    236242          if (data.Count > 3 && data[3] == "1")
    237             withDueDates = true;
     243            DueDates.Value = true;
    238244          line = problemFile.ReadLine();
    239245          data = SplitString(line);
    240246          while (!problemFile.EndOfStream && data.Count > 0 && ((int)data[0][0] >= 48 && (int)data[0][0] <= 57)) {
    241             DoubleValue dueDate = null;
    242             int dataCount = data.Count;
    243             if (withDueDates) {
    244               dueDate = new DoubleValue(Double.Parse(data[data.Count - 1]));
    245               dataCount--;
    246             }
    247             Job j = new Job(new IntValue(jobCount), dueDate);
    248             for (int i = 0; i < dataCount; i++) {
    249               Task t = new Task(i / 2, Int32.Parse(data[i]), jobCount, Double.Parse(data[i + 1]));
    250               j.Tasks.Add(t);
    251               i++;
    252             }//for
     247            Job j = CreateJobFromData(data, jobCount);
    253248            this.JobData.Add(j);
    254249            jobCount++;
  • branches/Scheduling/HeuristicLab.Problems.Scheduling/3.3/Plugin.cs

    r6293 r6364  
    2323
    2424namespace HeuristicLab.Problems.Scheduling {
    25   [Plugin("HeuristicLab.Problems.Scheduling", "3.3.3.6266")]
     25  [Plugin("HeuristicLab.Problems.Scheduling", "3.3.3.6293")]
    2626  [PluginFile("HeuristicLab.Problems.Scheduling-3.3.dll", PluginFileType.Assembly)]
    2727  public class HeuristicLabProblemsSchedulingPlugin : PluginBase {
  • branches/Scheduling/HeuristicLab.Problems.Scheduling/3.3/SchedulingProblem.cs

    r6293 r6364  
    3333  [Item("Scheduling Problem", "Abstract class that represents a Scheduling Problem")]
    3434  [StorableClass]
    35   public abstract class SchedulingProblem : SingleObjectiveHeuristicOptimizationProblem<ISchedulingEvaluator, ISchedulingCreator> {
     35  public abstract class SchedulingProblem : SingleObjectiveHeuristicOptimizationProblem<ISchedulingEvaluationAlgorithm, ISchedulingCreator> {
    3636    [StorableConstructor]
    3737    protected SchedulingProblem(bool deserializing) : base(deserializing) { }
     
    4040    }
    4141
    42     protected SchedulingProblem (ISchedulingEvaluator se, ISchedulingCreator sc) : base (se, sc) {}
     42    protected SchedulingProblem (ISchedulingEvaluationAlgorithm se, ISchedulingCreator sc) : base (se, sc) {}
    4343
    4444  }
  • branches/Scheduling/HeuristicLab.Problems.TravelingSalesman.Views/3.3/HeuristicLab.Problems.TravelingSalesman.Views-3.3.csproj

    r5832 r6364  
    9696  </PropertyGroup>
    9797  <ItemGroup>
     98    <Reference Include="HeuristicLab.Problems.Scheduling-3.3">
     99      <HintPath>..\..\HeuristicLab.Problems.Scheduling\3.3\bin\Debug\HeuristicLab.Problems.Scheduling-3.3.dll</HintPath>
     100    </Reference>
     101    <Reference Include="HeuristicLab.Visualization.ChartControlsExtensions-3.3, Version=3.3.0.0, Culture=neutral, PublicKeyToken=ba48961d6f65dcec, processorArchitecture=MSIL" />
    98102    <Reference Include="System" />
    99103    <Reference Include="System.Core">
     
    102106    <Reference Include="System.Drawing" />
    103107    <Reference Include="System.Windows.Forms" />
     108    <Reference Include="System.Windows.Forms.DataVisualization" />
    104109    <Reference Include="System.Xml.Linq">
    105110      <RequiredTargetFramework>3.5</RequiredTargetFramework>
     
    190195      <Project>{94186A6A-5176-4402-AE83-886557B53CCA}</Project>
    191196      <Name>HeuristicLab.PluginInfrastructure-3.3</Name>
     197    </ProjectReference>
     198    <ProjectReference Include="..\..\HeuristicLab.Problems.Scheduling.Views\3.3\HeuristicLab.Problems.Scheduling.Views-3.3.csproj">
     199      <Project>{78763A4E-E163-48C2-98EB-709760D06F25}</Project>
     200      <Name>HeuristicLab.Problems.Scheduling.Views-3.3</Name>
    192201    </ProjectReference>
    193202    <ProjectReference Include="..\..\HeuristicLab.Problems.TravelingSalesman\3.3\HeuristicLab.Problems.TravelingSalesman-3.3.csproj">
     
    212221      <Install>true</Install>
    213222    </BootstrapperPackage>
     223  </ItemGroup>
     224  <ItemGroup>
     225    <EmbeddedResource Include="PathTSPTourView.resx">
     226      <DependentUpon>PathTSPTourView.cs</DependentUpon>
     227    </EmbeddedResource>
    214228  </ItemGroup>
    215229  <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
  • branches/Scheduling/HeuristicLab/3.3/Files.txt

    r6294 r6364  
    3232HeuristicLab.Encodings.IntegerVectorEncoding\3.3:HeuristicLab.Encodings.IntegerVectorEncoding-3.3.dll
    3333HeuristicLab.Encodings.PermutationEncoding\3.3:HeuristicLab.Encodings.PermutationEncoding-3.3.dll
     34HeuristicLab.Encodings.PermutationEncoding.Views\3.3:HeuristicLab.Encodings.PermutationEncoding.Views-3.3.dll
    3435HeuristicLab.Encodings.SchedulingEncoding\3.3:HeuristicLab.Encodings.SchedulingEncoding-3.3.dll
    35 HeuristicLab.Encodings.PermutationEncoding.Views\3.3:HeuristicLab.Encodings.PermutationEncoding.Views-3.3.dll
     36HeuristicLab.Encodings.SchedulingEncoding.Views\3.3:HeuristicLab.Encodings.SchedulingEncoding.Views-3.3.dll
    3637HeuristicLab.Encodings.RealVectorEncoding\3.3:HeuristicLab.Encodings.RealVectorEncoding-3.3.dll
    3738HeuristicLab.Encodings.SymbolicExpressionTreeEncoding\3.3:HeuristicLab.Encodings.SymbolicExpressionTreeEncoding-3.3.dll
  • branches/Scheduling/HeuristicLab/3.3/Tests/HeuristicLab-3.3.Tests.csproj

    r6294 r6364  
    252252      <Name>HeuristicLab.Encodings.RealVectorEncoding-3.3</Name>
    253253    </ProjectReference>
     254    <ProjectReference Include="..\..\..\HeuristicLab.Encodings.SchedulingEncoding.Views\3.3\HeuristicLab.Encodings.SchedulingEncoding.Views-3.3.csproj">
     255      <Project>{0C378762-D5DB-488A-8931-2BA42B1B7CBF}</Project>
     256      <Name>HeuristicLab.Encodings.SchedulingEncoding.Views-3.3</Name>
     257    </ProjectReference>
     258    <ProjectReference Include="..\..\..\HeuristicLab.Encodings.SchedulingEncoding\3.3\HeuristicLab.Encodings.SchedulingEncoding-3.3.csproj">
     259      <Project>{17F3EF80-B2C3-4B8D-A4D5-BE9CE3BA2606}</Project>
     260      <Name>HeuristicLab.Encodings.SchedulingEncoding-3.3</Name>
     261    </ProjectReference>
    254262    <ProjectReference Include="..\..\..\HeuristicLab.Encodings.SymbolicExpressionTreeEncoding.Views\3.3\HeuristicLab.Encodings.SymbolicExpressionTreeEncoding.Views-3.3.csproj">
    255263      <Project>{6F42C5F8-16CD-43EE-8208-FD4573A69D85}</Project>
Note: See TracChangeset for help on using the changeset viewer.