Changeset 10115
- Timestamp:
- 11/08/13 10:10:07 (11 years ago)
- Location:
- branches/HeuristicLab.Analysis.AlgorithmBehavior
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/HeuristicLab.Analysis.AlgorithmBehavior/HeuristicLab.Analysis.SolutionCaching.Views/3.3/HeuristicLab.Analysis.SolutionCaching.Views-3.3.csproj
r10113 r10115 178 178 </ItemGroup> 179 179 <ItemGroup> 180 <EmbeddedResource Include="RunCollectionModifierTasksConfigurator.resx">181 <DependentUpon>RunCollectionModifierTasksConfigurator.cs</DependentUpon>182 </EmbeddedResource>183 180 <EmbeddedResource Include="SolutionCacheView.resx"> 184 181 <DependentUpon>SolutionCacheView.cs</DependentUpon> -
branches/HeuristicLab.Analysis.AlgorithmBehavior/HeuristicLab.Analysis.SolutionCaching.Views/3.3/RunCollectionModifierTasksConfigurator.Designer.cs
r10113 r10115 32 32 // 33 33 this.okButton.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); 34 this.okButton.Location = new System.Drawing.Point( 502, 325);34 this.okButton.Location = new System.Drawing.Point(707, 437); 35 35 this.okButton.Name = "okButton"; 36 36 this.okButton.Size = new System.Drawing.Size(75, 23); … … 43 43 // 44 44 this.cancelButton.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right))); 45 this.cancelButton.Location = new System.Drawing.Point( 583, 325);45 this.cancelButton.Location = new System.Drawing.Point(788, 437); 46 46 this.cancelButton.Name = "cancelButton"; 47 47 this.cancelButton.Size = new System.Drawing.Size(75, 23); … … 62 62 this.viewHost.Name = "viewHost"; 63 63 this.viewHost.ReadOnly = false; 64 this.viewHost.Size = new System.Drawing.Size( 646, 307);64 this.viewHost.Size = new System.Drawing.Size(851, 419); 65 65 this.viewHost.TabIndex = 2; 66 66 this.viewHost.ViewsLabelVisible = true; … … 71 71 this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); 72 72 this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; 73 this.ClientSize = new System.Drawing.Size( 670, 360);73 this.ClientSize = new System.Drawing.Size(875, 472); 74 74 this.Controls.Add(this.viewHost); 75 75 this.Controls.Add(this.cancelButton); -
branches/HeuristicLab.Analysis.AlgorithmBehavior/HeuristicLab.Analysis.SolutionCaching.Views/3.3/RunCollectionModifierTasksConfigurator.cs
r10114 r10115 55 55 56 56 private void RunCollectionModifierTasksConfigurator_Load(object sender, EventArgs e) { 57 runCollectionModifierExecutable.RunCollection.AddRange(Content.Runs); 57 58 viewHost.Content = runCollectionModifierExecutable; 58 59 } 59 60 60 61 private void CreateTask() { 61 runCollectionModifierExecutable. RunCollection.AddRange(Content.Runs);62 runCollectionModifierExecutable.Prepare(); 62 63 MainFormManager.MainForm.ShowContent(runCollectionModifierExecutable); 63 64 } -
branches/HeuristicLab.Analysis.AlgorithmBehavior/HeuristicLab.Analysis.SolutionCaching/3.3/RunCollectionModifiers/RunCollectionModifierExecutable.cs
r10114 r10115 62 62 get { return (ValueParameter<ItemList<IRunCollectionModifier>>)Parameters["RunCollectionModifiers"]; } 63 63 } 64 public RunCollection RunCollection { 65 get { return RunCollectionParameter.Value; } 66 protected set { RunCollectionParameter.Value = value; } 67 } 68 public ValueParameter<RunCollection> RunCollectionParameter { 69 get { return (ValueParameter<RunCollection>)Parameters["RunCollection"]; } 70 } 64 71 public ItemList<IRunCollectionModifier> RunCollectionModifiers { 65 72 get { return RunCollectionModifiersParameter.Value; } 66 }67 68 [Storable]69 protected RunCollection runCollection;70 public RunCollection RunCollection {71 get { return runCollection; }72 73 } 73 74 … … 90 91 public RunCollectionModifierExecutable() { 91 92 Parameters.Add(new ValueParameter<ItemList<IRunCollectionModifier>>("RunCollectionModifiers", "List of RunCollectionModifiers that are executed. ", new ItemList<IRunCollectionModifier>())); 93 Parameters.Add(new ValueParameter<RunCollection>("RunCollection", "RunCollection on which the modifiers are applied. ", new RunCollection())); 92 94 executionStack = new Stack<IRunCollectionModifier>(); 93 runCollection = new RunCollection();94 95 log = new Log(); 95 96 } … … 100 101 executionTime = original.executionTime; 101 102 executionState = original.executionState; 102 runCollection = (RunCollection)original.runCollection.Clone(cloner);103 103 executionStack = new Stack<IRunCollectionModifier>(); 104 104 foreach (var runCollectionModifier in original.executionStack) { … … 165 165 CancellationToken ct = (CancellationToken)state; 166 166 OnStarted(); 167 var runs = RunCollection.ToList(); 167 168 168 169 IRunCollectionModifier next; … … 171 172 try { 172 173 ct.ThrowIfCancellationRequested(); 173 next.Modify(run Collection.ToList());174 next.Modify(runs); 174 175 } 175 176 catch (Exception ex) { … … 177 178 if (ex is OperationCanceledException) throw ex; 178 179 else throw new Exception("IRunCollectionModifier " + next + "threw an exception.", ex); 180 } 181 finally { 182 RunCollection = new RunCollection(runs); 179 183 } 180 184 }
Note: See TracChangeset
for help on using the changeset viewer.