Changeset 4558 for branches/OKB
- Timestamp:
- 10/06/10 02:51:43 (14 years ago)
- Location:
- branches/OKB
- Files:
-
- 10 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/OKB/HeuristicLab.Clients.OKB-3.3/OKBExperiment.cs
r4553 r4558 43 43 } 44 44 45 [Storable] 46 private long AlgorithmId { get; set; } 47 [Storable] 45 private long algorithmId; 46 public long AlgorithmId { 47 get { return algorithmId; } 48 private set { 49 if (algorithmId != value) { 50 algorithmId = value; 51 OnAlgorithmIdChanged(); 52 } 53 } 54 } 48 55 private IAlgorithm algorithm; 49 56 private IAlgorithm Algorithm { … … 53 60 algorithm = value; 54 61 RegisterAlgorithmEvents(); 55 if (algorithm != null) algorithm.Problem = Problem; 56 OnChanged(); 57 } 58 } 59 [Storable] 60 private long ProblemId { get; set; } 61 [Storable] 62 if ((algorithm != null) && (problem != null)) { 63 algorithm.Problem = problem; 64 algorithm.Prepare(true); 65 } 66 } 67 } 68 private long problemId; 69 public long ProblemId { 70 get { return problemId; } 71 private set { 72 if (problemId != value) { 73 problemId = value; 74 OnProblemIdChanged(); 75 } 76 } 77 } 62 78 private IProblem problem; 63 p ublicIProblem Problem {79 private IProblem Problem { 64 80 get { return problem; } 65 privateset {81 set { 66 82 problem = value; 67 if (Algorithm != null) Algorithm.Problem = problem; 68 OnChanged(); 83 if ((algorithm != null) && (problem != null)) { 84 algorithm.Problem = problem; 85 algorithm.Prepare(true); 86 } 69 87 } 70 88 } … … 72 90 public ExecutionState ExecutionState { 73 91 get { 74 if ( Algorithm != null) return Algorithm.ExecutionState;92 if ((Algorithm != null) && (Problem != null)) return Algorithm.ExecutionState; 75 93 else return ExecutionState.Stopped; 76 94 } … … 82 100 } 83 101 } 84 public IKeyedItemCollection<string, IParameter> Parameters {102 public IKeyedItemCollection<string, IParameter> AlgorithmParameters { 85 103 get { 86 104 if (Algorithm != null) return Algorithm.Parameters; … … 88 106 } 89 107 } 108 public IKeyedItemCollection<string, IParameter> ProblemParameters { 109 get { 110 if (Problem != null) return Problem.Parameters; 111 else return null; 112 } 113 } 90 114 public ResultCollection Results { 91 115 get { … … 100 124 } 101 125 } 126 127 #region Persistence Properties 128 [Storable(Name = "AlgorithmId")] 129 private long AlgorithmIdPersistence { 130 get { return algorithmId; } 131 set { algorithmId = value; } 132 } 133 [Storable(Name = "Algorithm")] 134 private IAlgorithm AlgorithmPersistence { 135 get { return Algorithm; } 136 set { Algorithm = value; } 137 } 138 [Storable(Name = "ProblemId")] 139 private long ProblemIdPersistence { 140 get { return problemId; } 141 set { problemId = value; } 142 } 143 [Storable(Name = "Problem")] 144 private IProblem ProblemPersistence { 145 get { return Problem; } 146 set { Problem = value; } 147 } 148 #endregion 102 149 103 150 public OKBExperiment() … … 107 154 } 108 155 [StorableConstructor] 109 private OKBExperiment(bool deserializing) 110 : base(deserializing) { 156 private OKBExperiment(bool deserializing) : base(deserializing) { } 157 158 [StorableHook(HookType.AfterDeserialization)] 159 private void Initialize() { 111 160 RegisterAlgorithmEvents(); 112 161 } … … 114 163 public void Load(Algorithm algorithm) { 115 164 if (algorithm == null) { 165 Algorithm = null; 116 166 AlgorithmId = 0; 117 Algorithm = null;118 167 } else { 119 AlgorithmId = algorithm.Id; 120 AlgorithmData algorithmData = OKBClient.Instance.GetAlgorithmData(algorithm.Id); 121 122 using (MemoryStream stream = new MemoryStream(algorithmData.Data)) { 123 Algorithm = XmlParser.Deserialize<IAlgorithm>(stream); 168 try { 169 if (AlgorithmId != algorithm.Id) { 170 AlgorithmData algorithmData = OKBClient.Instance.GetAlgorithmData(algorithm.Id); 171 using (MemoryStream stream = new MemoryStream(algorithmData.Data)) { 172 Algorithm = XmlParser.Deserialize<IAlgorithm>(stream); 173 } 174 } 175 AlgorithmId = algorithm.Id; 176 } 177 catch (Exception ex) { 178 Algorithm = null; 179 AlgorithmId = 0; 180 OnExceptionOccurred(ex); 124 181 } 125 182 } … … 127 184 public void Load(Problem problem) { 128 185 if (problem == null) { 186 Problem = null; 129 187 ProblemId = 0; 130 Problem = null;131 188 } else { 132 ProblemId = problem.Id; 133 ProblemData problemData = OKBClient.Instance.GetProblemData(problem.Id); 134 135 using (MemoryStream stream = new MemoryStream(problemData.Data)) { 136 Problem = XmlParser.Deserialize<IProblem>(stream); 189 try { 190 if (ProblemId != problem.Id) { 191 ProblemData problemData = OKBClient.Instance.GetProblemData(problem.Id); 192 using (MemoryStream stream = new MemoryStream(problemData.Data)) { 193 Problem = XmlParser.Deserialize<IProblem>(stream); 194 } 195 } 196 ProblemId = problem.Id; 197 } 198 catch (Exception ex) { 199 Problem = null; 200 ProblemId = 0; 201 OnExceptionOccurred(ex); 137 202 } 138 203 } … … 156 221 157 222 #region Events 158 public event EventHandler Changed; 159 private void OnChanged() { 160 EventHandler handler = Changed; 223 public event EventHandler AlgorithmIdChanged; 224 private void OnAlgorithmIdChanged() { 225 EventHandler handler = AlgorithmIdChanged; 226 if (handler != null) handler(this, EventArgs.Empty); 227 } 228 public event EventHandler ProblemIdChanged; 229 private void OnProblemIdChanged() { 230 EventHandler handler = ProblemIdChanged; 161 231 if (handler != null) handler(this, EventArgs.Empty); 162 232 } … … 199 269 private void RegisterAlgorithmEvents() { 200 270 if (Algorithm != null) { 201 Algorithm.ExceptionOccurred += new EventHandler<EventArgs<Exception>>( Algorithm_ExceptionOccurred);202 Algorithm.ExecutionStateChanged += new EventHandler( Algorithm_ExecutionStateChanged);203 Algorithm.ExecutionTimeChanged += new EventHandler( Algorithm_ExecutionTimeChanged);204 Algorithm.ItemImageChanged += new EventHandler( Algorithm_ItemImageChanged);205 Algorithm.Paused += new EventHandler( Algorithm_Paused);206 Algorithm.Prepared += new EventHandler( Algorithm_Prepared);207 Algorithm.Started += new EventHandler( Algorithm_Started);208 Algorithm.Stopped += new EventHandler( Algorithm_Stopped);271 Algorithm.ExceptionOccurred += new EventHandler<EventArgs<Exception>>(algorithm_ExceptionOccurred); 272 Algorithm.ExecutionStateChanged += new EventHandler(algorithm_ExecutionStateChanged); 273 Algorithm.ExecutionTimeChanged += new EventHandler(algorithm_ExecutionTimeChanged); 274 Algorithm.ItemImageChanged += new EventHandler(algorithm_ItemImageChanged); 275 Algorithm.Paused += new EventHandler(algorithm_Paused); 276 Algorithm.Prepared += new EventHandler(algorithm_Prepared); 277 Algorithm.Started += new EventHandler(algorithm_Started); 278 Algorithm.Stopped += new EventHandler(algorithm_Stopped); 209 279 } 210 280 } 211 281 private void DeregisterAlgorithmEvents() { 212 282 if (Algorithm != null) { 213 Algorithm.ExceptionOccurred -= new EventHandler<EventArgs<Exception>>( Algorithm_ExceptionOccurred);214 Algorithm.ExecutionStateChanged -= new EventHandler( Algorithm_ExecutionStateChanged);215 Algorithm.ExecutionTimeChanged -= new EventHandler( Algorithm_ExecutionTimeChanged);216 Algorithm.ItemImageChanged -= new EventHandler( Algorithm_ItemImageChanged);217 Algorithm.Paused -= new EventHandler( Algorithm_Paused);218 Algorithm.Prepared -= new EventHandler( Algorithm_Prepared);219 Algorithm.Started -= new EventHandler( Algorithm_Started);220 Algorithm.Stopped -= new EventHandler( Algorithm_Stopped);221 } 222 } 223 private void Algorithm_ExceptionOccurred(object sender, EventArgs<Exception> e) {283 Algorithm.ExceptionOccurred -= new EventHandler<EventArgs<Exception>>(algorithm_ExceptionOccurred); 284 Algorithm.ExecutionStateChanged -= new EventHandler(algorithm_ExecutionStateChanged); 285 Algorithm.ExecutionTimeChanged -= new EventHandler(algorithm_ExecutionTimeChanged); 286 Algorithm.ItemImageChanged -= new EventHandler(algorithm_ItemImageChanged); 287 Algorithm.Paused -= new EventHandler(algorithm_Paused); 288 Algorithm.Prepared -= new EventHandler(algorithm_Prepared); 289 Algorithm.Started -= new EventHandler(algorithm_Started); 290 Algorithm.Stopped -= new EventHandler(algorithm_Stopped); 291 } 292 } 293 private void algorithm_ExceptionOccurred(object sender, EventArgs<Exception> e) { 224 294 OnExceptionOccurred(e.Value); 225 295 } 226 private void Algorithm_ExecutionStateChanged(object sender, EventArgs e) {296 private void algorithm_ExecutionStateChanged(object sender, EventArgs e) { 227 297 OnExecutionStateChanged(); 228 298 } 229 private void Algorithm_ExecutionTimeChanged(object sender, EventArgs e) {299 private void algorithm_ExecutionTimeChanged(object sender, EventArgs e) { 230 300 OnExecutionTimeChanged(); 231 301 } 232 private void Algorithm_ItemImageChanged(object sender, EventArgs e) {302 private void algorithm_ItemImageChanged(object sender, EventArgs e) { 233 303 OnItemImageChanged(); 234 304 } 235 private void Algorithm_Paused(object sender, EventArgs e) {305 private void algorithm_Paused(object sender, EventArgs e) { 236 306 OnPaused(); 237 307 } 238 private void Algorithm_Prepared(object sender, EventArgs e) {308 private void algorithm_Prepared(object sender, EventArgs e) { 239 309 OnPrepared(); 240 310 } 241 private void Algorithm_Started(object sender, EventArgs e) {311 private void algorithm_Started(object sender, EventArgs e) { 242 312 OnStarted(); 243 313 } 244 private void Algorithm_Stopped(object sender, EventArgs e) {314 private void algorithm_Stopped(object sender, EventArgs e) { 245 315 OnStopped(); 246 316 } -
branches/OKB/HeuristicLab.Clients.OKB-3.3/Views/AlgorithmDataView.cs
r4549 r4558 21 21 22 22 using System; 23 using System.Collections.Generic; 23 24 using System.ComponentModel; 24 25 using System.IO; … … 37 38 [Content(typeof(AlgorithmData), true)] 38 39 public partial class AlgorithmDataView : AsynchronousContentView { 40 private List<DataType> dataTypeComboBoxValues; 41 39 42 private long algorithmId; 40 43 public long AlgorithmId { … … 60 63 protected override void OnInitialized(System.EventArgs e) { 61 64 base.OnInitialized(e); 62 dataTypeComboBox.DataSource = OKBClient.Instance.DataTypes.ToList(); 65 dataTypeComboBoxValues = OKBClient.Instance.DataTypes.ToList(); 66 dataTypeComboBox.DataSource = dataTypeComboBoxValues; 63 67 dataTypeComboBox.SelectedIndex = -1; 64 68 } … … 80 84 noViewAvailableLabel.Visible = false; 81 85 } else { 82 dataTypeComboBox.SelectedItem = OKBClient.Instance.DataTypes.FirstOrDefault(d => d.Id == Content.DataTypeId);86 dataTypeComboBox.SelectedItem = dataTypeComboBoxValues.FirstOrDefault(d => d.Id == Content.DataTypeId); 83 87 84 88 using (MemoryStream stream = new MemoryStream(Content.Data)) { … … 111 115 switch (e.PropertyName) { 112 116 case "DataTypeId": 113 dataTypeComboBox.SelectedItem = OKBClient.Instance.DataTypes.FirstOrDefault(d => d.Id == Content.DataTypeId);117 dataTypeComboBox.SelectedItem = dataTypeComboBoxValues.FirstOrDefault(d => d.Id == Content.DataTypeId); 114 118 break; 115 119 } … … 159 163 dataType.Store(); 160 164 OKBClient.Instance.DataTypes.Add(dataType); 161 dataTypeComboBox.DataSource = OKBClient.Instance.DataTypes.OrderBy(d => d.Name).ToList(); 165 dataTypeComboBoxValues = OKBClient.Instance.DataTypes.OrderBy(d => d.Name).ToList(); 166 dataTypeComboBox.DataSource = dataTypeComboBoxValues; 162 167 } 163 168 dataTypeComboBox.SelectedItem = dataType; … … 191 196 dataType.Store(); 192 197 OKBClient.Instance.DataTypes.Add(dataType); 193 dataTypeComboBox.DataSource = OKBClient.Instance.DataTypes.OrderBy(d => d.Name).ToList(); 198 dataTypeComboBoxValues = OKBClient.Instance.DataTypes.OrderBy(d => d.Name).ToList(); 199 dataTypeComboBox.DataSource = dataTypeComboBoxValues; 194 200 } 195 201 dataTypeComboBox.SelectedItem = dataType; -
branches/OKB/HeuristicLab.Clients.OKB-3.3/Views/AlgorithmView.cs
r4549 r4558 31 31 [Content(typeof(Algorithm), true)] 32 32 public partial class AlgorithmView : NamedOKBItemView { 33 private List<Platform> platformComboBoxValues; 34 private List<AlgorithmClass> algorithmClassComboBoxValues; 35 33 36 public new Algorithm Content { 34 37 get { return (Algorithm)base.Content; } … … 42 45 protected override void OnInitialized(System.EventArgs e) { 43 46 base.OnInitialized(e); 44 platformComboBox.DataSource = OKBClient.Instance.Platforms.ToList(); 45 algorithmClassComboBox.DataSource = OKBClient.Instance.AlgorithmClasses.ToList(); 47 platformComboBoxValues = OKBClient.Instance.Platforms.ToList(); 48 platformComboBox.DataSource = platformComboBoxValues; 49 algorithmClassComboBoxValues = OKBClient.Instance.AlgorithmClasses.ToList(); 50 algorithmClassComboBox.DataSource = algorithmClassComboBoxValues; 46 51 } 47 52 … … 53 58 algorithmDataView.AlgorithmId = 0; 54 59 } else { 55 platformComboBox.SelectedItem = OKBClient.Instance.Platforms.FirstOrDefault(p => p.Id == Content.PlatformId);56 algorithmClassComboBox.SelectedItem = OKBClient.Instance.AlgorithmClasses.FirstOrDefault(a => a.Id == Content.AlgorithmClassId);60 platformComboBox.SelectedItem = platformComboBoxValues.FirstOrDefault(p => p.Id == Content.PlatformId); 61 algorithmClassComboBox.SelectedItem = algorithmClassComboBoxValues.FirstOrDefault(a => a.Id == Content.AlgorithmClassId); 57 62 algorithmDataView.AlgorithmId = Content.Id; 58 63 } … … 77 82 break; 78 83 case "PlatformId": 79 platformComboBox.SelectedItem = OKBClient.Instance.Platforms.FirstOrDefault(p => p.Id == Content.PlatformId);84 platformComboBox.SelectedItem = platformComboBoxValues.FirstOrDefault(p => p.Id == Content.PlatformId); 80 85 break; 81 86 case "AlgorithmClassId": 82 algorithmClassComboBox.SelectedItem = OKBClient.Instance.AlgorithmClasses.FirstOrDefault(a => a.Id == Content.AlgorithmClassId);87 algorithmClassComboBox.SelectedItem = algorithmClassComboBoxValues.FirstOrDefault(a => a.Id == Content.AlgorithmClassId); 83 88 break; 84 89 } -
branches/OKB/HeuristicLab.Clients.OKB-3.3/Views/DataTypeView.cs
r4549 r4558 21 21 22 22 using System; 23 using System.Collections.Generic; 23 24 using System.Linq; 24 25 using System.Windows.Forms; … … 30 31 [Content(typeof(DataType), true)] 31 32 public partial class DataTypeView : OKBItemView { 33 private List<Platform> platformComboBoxValues; 34 32 35 public new DataType Content { 33 36 get { return (DataType)base.Content; } … … 41 44 protected override void OnInitialized(System.EventArgs e) { 42 45 base.OnInitialized(e); 43 platformComboBox.DataSource = OKBClient.Instance.Platforms.ToList(); 46 platformComboBoxValues = OKBClient.Instance.Platforms.ToList(); 47 platformComboBox.DataSource = platformComboBoxValues; 44 48 } 45 49 … … 57 61 nameTextBox.Text = Content.Name; 58 62 sqlNameComboBox.Text = Content.SqlName; 59 platformComboBox.SelectedItem = OKBClient.Instance.Platforms.FirstOrDefault(p => p.Id == Content.PlatformId);63 platformComboBox.SelectedItem = platformComboBoxValues.FirstOrDefault(p => p.Id == Content.PlatformId); 60 64 Caption = Content.Name; 61 65 } … … 80 84 break; 81 85 case "PlatformId": 82 platformComboBox.SelectedItem = OKBClient.Instance.Platforms.FirstOrDefault(p => p.Id == Content.PlatformId);86 platformComboBox.SelectedItem = platformComboBoxValues.FirstOrDefault(p => p.Id == Content.PlatformId); 83 87 break; 84 88 } -
branches/OKB/HeuristicLab.Clients.OKB-3.3/Views/OKBExperimentView.Designer.cs
r4549 r4558 57 57 this.executionTimeTextBox = new System.Windows.Forms.TextBox(); 58 58 this.tabControl = new System.Windows.Forms.TabControl(); 59 this.problem TabPage = new System.Windows.Forms.TabPage();60 this. parametersTabPage = new System.Windows.Forms.TabPage();59 this.problemParametersTabPage = new System.Windows.Forms.TabPage(); 60 this.algorithmParametersTabPage = new System.Windows.Forms.TabPage(); 61 61 this.resultsTabPage = new System.Windows.Forms.TabPage(); 62 62 this.runsTabPage = new System.Windows.Forms.TabPage(); 63 this.problem ViewHost = new HeuristicLab.MainForm.WindowsForms.ViewHost();64 this. parametersViewHost = new HeuristicLab.MainForm.WindowsForms.ViewHost();63 this.problemParametersViewHost = new HeuristicLab.MainForm.WindowsForms.ViewHost(); 64 this.algorithmParametersViewHost = new HeuristicLab.MainForm.WindowsForms.ViewHost(); 65 65 this.resultsViewHost = new HeuristicLab.MainForm.WindowsForms.ViewHost(); 66 66 this.runsViewHost = new HeuristicLab.MainForm.WindowsForms.ViewHost(); 67 67 ((System.ComponentModel.ISupportInitialize)(this.errorProvider)).BeginInit(); 68 68 this.tabControl.SuspendLayout(); 69 this.problem TabPage.SuspendLayout();70 this. parametersTabPage.SuspendLayout();69 this.problemParametersTabPage.SuspendLayout(); 70 this.algorithmParametersTabPage.SuspendLayout(); 71 71 this.resultsTabPage.SuspendLayout(); 72 72 this.runsTabPage.SuspendLayout(); … … 203 203 | System.Windows.Forms.AnchorStyles.Left) 204 204 | System.Windows.Forms.AnchorStyles.Right))); 205 this.tabControl.Controls.Add(this.problem TabPage);206 this.tabControl.Controls.Add(this. parametersTabPage);205 this.tabControl.Controls.Add(this.problemParametersTabPage); 206 this.tabControl.Controls.Add(this.algorithmParametersTabPage); 207 207 this.tabControl.Controls.Add(this.resultsTabPage); 208 208 this.tabControl.Controls.Add(this.runsTabPage); … … 213 213 this.tabControl.TabIndex = 9; 214 214 // 215 // problem TabPage216 // 217 this.problem TabPage.Controls.Add(this.problemViewHost);218 this.problem TabPage.Location = new System.Drawing.Point(4, 22);219 this.problem TabPage.Name = "problemTabPage";220 this.problem TabPage.Padding = new System.Windows.Forms.Padding(3);221 this.problem TabPage.Size = new System.Drawing.Size(702, 282);222 this.problem TabPage.TabIndex = 0;223 this.problem TabPage.Text = "Problem";224 this.problem TabPage.UseVisualStyleBackColor = true;225 // 226 // parametersTabPage227 // 228 this. parametersTabPage.Controls.Add(this.parametersViewHost);229 this. parametersTabPage.Location = new System.Drawing.Point(4, 22);230 this. parametersTabPage.Name = "parametersTabPage";231 this. parametersTabPage.Padding = new System.Windows.Forms.Padding(3);232 this. parametersTabPage.Size = new System.Drawing.Size(702, 282);233 this. parametersTabPage.TabIndex = 1;234 this. parametersTabPage.Text = "Parameters";235 this. parametersTabPage.UseVisualStyleBackColor = true;215 // problemParametersTabPage 216 // 217 this.problemParametersTabPage.Controls.Add(this.problemParametersViewHost); 218 this.problemParametersTabPage.Location = new System.Drawing.Point(4, 22); 219 this.problemParametersTabPage.Name = "problemParametersTabPage"; 220 this.problemParametersTabPage.Padding = new System.Windows.Forms.Padding(3); 221 this.problemParametersTabPage.Size = new System.Drawing.Size(702, 282); 222 this.problemParametersTabPage.TabIndex = 0; 223 this.problemParametersTabPage.Text = "Problem Parameters"; 224 this.problemParametersTabPage.UseVisualStyleBackColor = true; 225 // 226 // algorithmParametersTabPage 227 // 228 this.algorithmParametersTabPage.Controls.Add(this.algorithmParametersViewHost); 229 this.algorithmParametersTabPage.Location = new System.Drawing.Point(4, 22); 230 this.algorithmParametersTabPage.Name = "algorithmParametersTabPage"; 231 this.algorithmParametersTabPage.Padding = new System.Windows.Forms.Padding(3); 232 this.algorithmParametersTabPage.Size = new System.Drawing.Size(702, 282); 233 this.algorithmParametersTabPage.TabIndex = 1; 234 this.algorithmParametersTabPage.Text = "Algorithm Parameters"; 235 this.algorithmParametersTabPage.UseVisualStyleBackColor = true; 236 236 // 237 237 // resultsTabPage … … 255 255 this.runsTabPage.UseVisualStyleBackColor = true; 256 256 // 257 // problem ViewHost258 // 259 this.problem ViewHost.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)260 | System.Windows.Forms.AnchorStyles.Left) 261 | System.Windows.Forms.AnchorStyles.Right))); 262 this.problem ViewHost.Caption = "View";263 this.problem ViewHost.Content = null;264 this.problem ViewHost.Location = new System.Drawing.Point(6, 6);265 this.problem ViewHost.Name = "problemViewHost";266 this.problem ViewHost.ReadOnly = false;267 this.problem ViewHost.Size = new System.Drawing.Size(690, 270);268 this.problem ViewHost.TabIndex = 0;269 this.problem ViewHost.ViewType = null;270 // 271 // parametersViewHost272 // 273 this. parametersViewHost.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom)274 | System.Windows.Forms.AnchorStyles.Left) 275 | System.Windows.Forms.AnchorStyles.Right))); 276 this. parametersViewHost.Caption = "View";277 this. parametersViewHost.Content = null;278 this. parametersViewHost.Location = new System.Drawing.Point(6, 6);279 this. parametersViewHost.Name = "parametersViewHost";280 this. parametersViewHost.ReadOnly = false;281 this. parametersViewHost.Size = new System.Drawing.Size(690, 270);282 this. parametersViewHost.TabIndex = 1;283 this. parametersViewHost.ViewType = null;257 // problemParametersViewHost 258 // 259 this.problemParametersViewHost.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) 260 | System.Windows.Forms.AnchorStyles.Left) 261 | System.Windows.Forms.AnchorStyles.Right))); 262 this.problemParametersViewHost.Caption = "View"; 263 this.problemParametersViewHost.Content = null; 264 this.problemParametersViewHost.Location = new System.Drawing.Point(6, 6); 265 this.problemParametersViewHost.Name = "problemParametersViewHost"; 266 this.problemParametersViewHost.ReadOnly = false; 267 this.problemParametersViewHost.Size = new System.Drawing.Size(690, 270); 268 this.problemParametersViewHost.TabIndex = 0; 269 this.problemParametersViewHost.ViewType = null; 270 // 271 // algorithmParametersViewHost 272 // 273 this.algorithmParametersViewHost.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) 274 | System.Windows.Forms.AnchorStyles.Left) 275 | System.Windows.Forms.AnchorStyles.Right))); 276 this.algorithmParametersViewHost.Caption = "View"; 277 this.algorithmParametersViewHost.Content = null; 278 this.algorithmParametersViewHost.Location = new System.Drawing.Point(6, 6); 279 this.algorithmParametersViewHost.Name = "algorithmParametersViewHost"; 280 this.algorithmParametersViewHost.ReadOnly = false; 281 this.algorithmParametersViewHost.Size = new System.Drawing.Size(690, 270); 282 this.algorithmParametersViewHost.TabIndex = 1; 283 this.algorithmParametersViewHost.ViewType = null; 284 284 // 285 285 // resultsViewHost … … 347 347 ((System.ComponentModel.ISupportInitialize)(this.errorProvider)).EndInit(); 348 348 this.tabControl.ResumeLayout(false); 349 this.problem TabPage.ResumeLayout(false);350 this. parametersTabPage.ResumeLayout(false);349 this.problemParametersTabPage.ResumeLayout(false); 350 this.algorithmParametersTabPage.ResumeLayout(false); 351 351 this.resultsTabPage.ResumeLayout(false); 352 352 this.runsTabPage.ResumeLayout(false); … … 370 370 private System.Windows.Forms.TextBox executionTimeTextBox; 371 371 private System.Windows.Forms.TabControl tabControl; 372 private System.Windows.Forms.TabPage problem TabPage;373 private System.Windows.Forms.TabPage parametersTabPage;374 private MainForm.WindowsForms.ViewHost problem ViewHost;375 private MainForm.WindowsForms.ViewHost parametersViewHost;372 private System.Windows.Forms.TabPage problemParametersTabPage; 373 private System.Windows.Forms.TabPage algorithmParametersTabPage; 374 private MainForm.WindowsForms.ViewHost problemParametersViewHost; 375 private MainForm.WindowsForms.ViewHost algorithmParametersViewHost; 376 376 private System.Windows.Forms.TabPage resultsTabPage; 377 377 private MainForm.WindowsForms.ViewHost resultsViewHost; -
branches/OKB/HeuristicLab.Clients.OKB-3.3/Views/OKBExperimentView.cs
r4553 r4558 47 47 OKBClient.Instance.Refreshing += new EventHandler(OKBClient_Refreshing); 48 48 OKBClient.Instance.Refreshed += new EventHandler(OKBClient_Refreshed); 49 // TODO: do not forget to deregister events 49 50 PopulateComboBoxes(); 50 51 } 51 52 52 53 protected override void DeregisterContentEvents() { 53 Content.Changed -= new EventHandler(Content_Changed); 54 Content.AlgorithmIdChanged -= new EventHandler(Content_AlgorithmIdChanged); 55 Content.ProblemIdChanged -= new EventHandler(Content_ProblemIdChanged); 54 56 Content.ExceptionOccurred -= new EventHandler<EventArgs<Exception>>(Content_ExceptionOccurred); 55 57 Content.ExecutionStateChanged -= new EventHandler(Content_ExecutionStateChanged); … … 63 65 protected override void RegisterContentEvents() { 64 66 base.RegisterContentEvents(); 65 Content.Changed += new EventHandler(Content_Changed); 67 Content.AlgorithmIdChanged += new EventHandler(Content_AlgorithmIdChanged); 68 Content.ProblemIdChanged += new EventHandler(Content_ProblemIdChanged); 66 69 Content.ExceptionOccurred += new EventHandler<EventArgs<Exception>>(Content_ExceptionOccurred); 67 70 Content.ExecutionStateChanged += new EventHandler(Content_ExecutionStateChanged); … … 76 79 base.OnContentChanged(); 77 80 if (Content == null) { 78 problemViewHost.Content = null; 79 parametersViewHost.Content = null; 81 algorithmComboBox.SelectedIndex = -1; 82 problemComboBox.SelectedIndex = -1; 83 problemParametersViewHost.Content = null; 84 algorithmParametersViewHost.Content = null; 80 85 resultsViewHost.Content = null; 81 86 runsViewHost.Content = null; 82 87 executionTimeTextBox.Text = "-"; 83 88 } else { 84 problemViewHost.Content = Content.Problem; 85 parametersViewHost.Content = Content.Parameters; 89 algorithmComboBox.SelectedItem = OKBClient.Instance.Algorithms.FirstOrDefault(x => x.Id == Content.AlgorithmId); 90 problemComboBox.SelectedItem = OKBClient.Instance.Problems.FirstOrDefault(x => x.Id == Content.ProblemId); 91 problemParametersViewHost.Content = Content.ProblemParameters; 92 algorithmParametersViewHost.Content = Content.AlgorithmParameters; 86 93 resultsViewHost.Content = Content.Results; 87 94 runsViewHost.Content = Content.Runs; … … 99 106 100 107 private void PopulateComboBoxes() { 108 algorithmComboBox.DataSource = null; 109 problemComboBox.DataSource = null; 101 110 Platform platform = OKBClient.Instance.Platforms.FirstOrDefault(x => x.Name == "HeuristicLab 3.3"); 102 111 if (platform != null) { 103 112 algorithmComboBox.DataSource = OKBClient.Instance.Algorithms.Where(x => x.PlatformId == platform.Id).ToList(); 104 113 algorithmComboBox.DisplayMember = "Name"; 105 algorithmComboBox.SelectedIndex = -1;106 114 problemComboBox.DataSource = OKBClient.Instance.Problems.Where(x => x.PlatformId == platform.Id).ToList(); 107 115 problemComboBox.DisplayMember = "Name"; 108 problemComboBox.SelectedIndex = -1;109 116 } 110 117 } … … 120 127 } else { 121 128 Cursor = Cursors.AppStarting; 122 Enabled = false;129 algorithmComboBox.Enabled = problemComboBox.Enabled = tabControl.Enabled = prepareButton.Enabled = startButton.Enabled = pauseButton.Enabled = stopButton.Enabled = executionTimeTextBox.Enabled = false; 123 130 } 124 131 } … … 128 135 } else { 129 136 PopulateComboBoxes(); 130 Enabled = true;137 SetEnabledStateOfControls(); 131 138 Cursor = Cursors.Default; 132 139 } … … 134 141 135 142 #region Content Events 136 private void Content_Changed(object sender, EventArgs e) { 137 OnContentChanged(); 138 SetEnabledStateOfControls(); 143 private void Content_AlgorithmIdChanged(object sender, EventArgs e) { 144 if (InvokeRequired) 145 Invoke(new EventHandler(Content_AlgorithmIdChanged), sender, e); 146 else { 147 algorithmComboBox.SelectedItem = OKBClient.Instance.Algorithms.FirstOrDefault(x => x.Id == Content.AlgorithmId); 148 algorithmParametersViewHost.Content = Content.AlgorithmParameters; 149 resultsViewHost.Content = Content.Results; 150 runsViewHost.Content = Content.Runs; 151 executionTimeTextBox.Text = Content.ExecutionTime.ToString(); 152 SetEnabledStateOfExecutableButtons(); 153 } 154 } 155 private void Content_ProblemIdChanged(object sender, EventArgs e) { 156 if (InvokeRequired) 157 Invoke(new EventHandler(Content_ProblemIdChanged), sender, e); 158 else { 159 problemComboBox.SelectedItem = OKBClient.Instance.Problems.FirstOrDefault(x => x.Id == Content.ProblemId); 160 problemParametersViewHost.Content = Content.ProblemParameters; 161 SetEnabledStateOfExecutableButtons(); 162 } 139 163 } 140 164 private void Content_ExceptionOccurred(object sender, EventArgs<Exception> e) { … … 219 243 #region Helpers 220 244 private void SetEnabledStateOfExecutableButtons() { 221 if ( Content == null) {245 if ((Content == null) || (Content.AlgorithmId == 0) || (Content.ProblemId == 0)) { 222 246 startButton.Enabled = pauseButton.Enabled = stopButton.Enabled = prepareButton.Enabled = false; 223 247 } else { -
branches/OKB/HeuristicLab.Clients.OKB-3.3/Views/ProblemDataView.cs
r4549 r4558 21 21 22 22 using System; 23 using System.Collections.Generic; 23 24 using System.ComponentModel; 24 25 using System.IO; … … 37 38 [Content(typeof(ProblemData), true)] 38 39 public partial class ProblemDataView : AsynchronousContentView { 40 private List<DataType> dataTypeComboBoxValues; 41 39 42 private long problemId; 40 43 public long ProblemId { … … 60 63 protected override void OnInitialized(System.EventArgs e) { 61 64 base.OnInitialized(e); 62 dataTypeComboBox.DataSource = OKBClient.Instance.DataTypes.ToList(); 65 dataTypeComboBoxValues = OKBClient.Instance.DataTypes.ToList(); 66 dataTypeComboBox.DataSource = dataTypeComboBoxValues; 63 67 dataTypeComboBox.SelectedIndex = -1; 64 68 } … … 80 84 noViewAvailableLabel.Visible = false; 81 85 } else { 82 dataTypeComboBox.SelectedItem = OKBClient.Instance.DataTypes.FirstOrDefault(d => d.Id == Content.DataTypeId);86 dataTypeComboBox.SelectedItem = dataTypeComboBoxValues.FirstOrDefault(d => d.Id == Content.DataTypeId); 83 87 84 88 using (MemoryStream stream = new MemoryStream(Content.Data)) { … … 111 115 switch (e.PropertyName) { 112 116 case "DataTypeId": 113 dataTypeComboBox.SelectedItem = OKBClient.Instance.DataTypes.FirstOrDefault(d => d.Id == Content.DataTypeId);117 dataTypeComboBox.SelectedItem = dataTypeComboBoxValues.FirstOrDefault(d => d.Id == Content.DataTypeId); 114 118 break; 115 119 } … … 158 162 dataType.Store(); 159 163 OKBClient.Instance.DataTypes.Add(dataType); 160 dataTypeComboBox.DataSource = OKBClient.Instance.DataTypes.OrderBy(d => d.Name).ToList(); 164 dataTypeComboBoxValues = OKBClient.Instance.DataTypes.OrderBy(d => d.Name).ToList(); 165 dataTypeComboBox.DataSource = dataTypeComboBoxValues; 161 166 } 162 167 dataTypeComboBox.SelectedItem = dataType; … … 190 195 dataType.Store(); 191 196 OKBClient.Instance.DataTypes.Add(dataType); 192 dataTypeComboBox.DataSource = OKBClient.Instance.DataTypes.OrderBy(d => d.Name).ToList(); 197 dataTypeComboBoxValues = OKBClient.Instance.DataTypes.OrderBy(d => d.Name).ToList(); 198 dataTypeComboBox.DataSource = dataTypeComboBoxValues; 193 199 } 194 200 dataTypeComboBox.SelectedItem = dataType; -
branches/OKB/HeuristicLab.Clients.OKB-3.3/Views/ProblemView.cs
r4549 r4558 31 31 [Content(typeof(Problem), true)] 32 32 public partial class ProblemView : NamedOKBItemView { 33 private List<Platform> platformComboBoxValues; 34 private List<ProblemClass> problemClassComboBoxValues; 35 33 36 public new Problem Content { 34 37 get { return (Problem)base.Content; } … … 42 45 protected override void OnInitialized(System.EventArgs e) { 43 46 base.OnInitialized(e); 44 platformComboBox.DataSource = OKBClient.Instance.Platforms.ToList(); 45 problemClassComboBox.DataSource = OKBClient.Instance.ProblemClasses.ToList(); 47 platformComboBoxValues = OKBClient.Instance.Platforms.ToList(); 48 platformComboBox.DataSource = platformComboBoxValues; 49 problemClassComboBoxValues = OKBClient.Instance.ProblemClasses.ToList(); 50 problemClassComboBox.DataSource = problemClassComboBoxValues; 46 51 } 47 52 … … 53 58 problemDataView.ProblemId = 0; 54 59 } else { 55 platformComboBox.SelectedItem = OKBClient.Instance.Platforms.FirstOrDefault(p => p.Id == Content.PlatformId);56 problemClassComboBox.SelectedItem = OKBClient.Instance.ProblemClasses.FirstOrDefault(a => a.Id == Content.ProblemClassId);60 platformComboBox.SelectedItem = platformComboBoxValues.FirstOrDefault(p => p.Id == Content.PlatformId); 61 problemClassComboBox.SelectedItem = problemClassComboBoxValues.FirstOrDefault(a => a.Id == Content.ProblemClassId); 57 62 problemDataView.ProblemId = Content.Id; 58 63 } … … 77 82 break; 78 83 case "PlatformId": 79 platformComboBox.SelectedItem = OKBClient.Instance.Platforms.FirstOrDefault(p => p.Id == Content.PlatformId);84 platformComboBox.SelectedItem = platformComboBoxValues.FirstOrDefault(p => p.Id == Content.PlatformId); 80 85 break; 81 86 case "ProblemClassId": 82 problemClassComboBox.SelectedItem = OKBClient.Instance.ProblemClasses.FirstOrDefault(a => a.Id == Content.ProblemClassId);87 problemClassComboBox.SelectedItem = problemClassComboBoxValues.FirstOrDefault(a => a.Id == Content.ProblemClassId); 83 88 break; 84 89 } -
branches/OKB/HeuristicLab.OKB.sln
r4480 r4558 2 2 Microsoft Visual Studio Solution File, Format Version 11.00 3 3 # Visual Studio 2010 4 Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "HeuristicLab.OKB.ParameterTable-3.3", "HeuristicLab.OKB.ParameterTable\HeuristicLab.OKB.ParameterTable-3.3.csproj", "{009C72FD-CE2D-4027-87A2-4151B03D2E8F}"5 EndProject6 Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "HeuristicLab.MainForm.WPF-3.3", "HeuristicLab.MainForm.WPF\HeuristicLab.MainForm.WPF-3.3.csproj", "{1DBC4D60-0064-4A53-B48C-63D144A67B07}"7 EndProject8 Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "HeuristicLab.OKB.Cockpit-3.3", "HeuristicLab.OKB.Cockpit\HeuristicLab.OKB.Cockpit-3.3.csproj", "{52567721-66A9-4411-9ED6-48DE37732868}"9 EndProject10 Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "HeuristicLab.AvalonDock-1.2.2691.0", "HeuristicLab.AvalonDock\HeuristicLab.AvalonDock-1.2.2691.0.csproj", "{D86DEAB6-61EA-4008-B2AB-8D8CD5665023}"11 EndProject12 Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "HeuristicLab.OKB.Cockpit.Admin-3.3", "HeuristicLab.OKB.Cockpit.Admin\HeuristicLab.OKB.Cockpit.Admin-3.3.csproj", "{9AADAE96-361F-48F0-B9B0-31B7DACD0492}"13 EndProject14 Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "HeuristicLab.OKB.Cockpit.Query-3.3", "HeuristicLab.OKB.Cockpit.Query\HeuristicLab.OKB.Cockpit.Query-3.3.csproj", "{AD85761D-D716-45D4-96E0-5AEF6BD3DE59}"15 EndProject16 Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "HeuristicLab.OKB.Client-3.3", "HeuristicLab.OKB.Client\HeuristicLab.OKB.Client-3.3.csproj", "{B157FAB7-9B6D-4BAE-ACF2-C6FB7D22EBBD}"17 EndProject18 Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "HeuristicLab.BackgroundProcessing-3.3", "HeuristicLab.BackgroundProcessing\HeuristicLab.BackgroundProcessing-3.3.csproj", "{589BECAE-69B0-4EB1-8C06-C073531762B7}"19 EndProject20 Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "HeuristicLab.OKB.AlgorithmHost-3.3", "HeuristicLab.OKB.AlgorithmHost\HeuristicLab.OKB.AlgorithmHost-3.3.csproj", "{7B60CBDC-E7E3-4610-91E2-7CE831A02D35}"21 EndProject22 Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "HeuristicLab.OKB.Cockpit.Admin.ItemEditor-3.3", "HeuristicLab.OKB.Cockpit.Admin.ItemEditor\HeuristicLab.OKB.Cockpit.Admin.ItemEditor-3.3.csproj", "{CFBF2410-99A1-44EC-BFEA-F1AD4C3DA622}"23 EndProject24 4 Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{9E843318-7235-4B2B-81A7-160FDDADD9E1}" 25 5 ProjectSection(SolutionItems) = preProject … … 32 12 EndProject 33 13 Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "HeuristicLab.Services.OKB.DataAccess-3.3", "HeuristicLab.Services.OKB.DataAccess\3.3\HeuristicLab.Services.OKB.DataAccess-3.3.csproj", "{E36BE58F-F3CE-40BB-9AB3-9F9E30AD5CCF}" 34 EndProject35 Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "HeuristicLab.Services.OKB.AttributeSelection-3.3", "HeuristicLab.Services.OKB.AttributeSelection\3.3\HeuristicLab.Services.OKB.AttributeSelection-3.3.csproj", "{E80A68DB-D6E1-4395-ABF0-AFE09E4DEF8B}"36 14 EndProject 37 15 Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "HeuristicLab.Services.OKB-3.3", "HeuristicLab.Services.OKB\3.3\HeuristicLab.Services.OKB-3.3.csproj", "{766DA4B7-2A0E-4CDE-8F90-93D8B1AD62CF}" … … 49 27 EndGlobalSection 50 28 GlobalSection(ProjectConfigurationPlatforms) = postSolution 51 {009C72FD-CE2D-4027-87A2-4151B03D2E8F}.Debug|Any CPU.ActiveCfg = Debug|Any CPU52 {009C72FD-CE2D-4027-87A2-4151B03D2E8F}.Debug|Any CPU.Build.0 = Debug|Any CPU53 {009C72FD-CE2D-4027-87A2-4151B03D2E8F}.Debug|x64.ActiveCfg = Debug|x6454 {009C72FD-CE2D-4027-87A2-4151B03D2E8F}.Debug|x64.Build.0 = Debug|x6455 {009C72FD-CE2D-4027-87A2-4151B03D2E8F}.Debug|x86.ActiveCfg = Debug|x8656 {009C72FD-CE2D-4027-87A2-4151B03D2E8F}.Debug|x86.Build.0 = Debug|x8657 {009C72FD-CE2D-4027-87A2-4151B03D2E8F}.Release|Any CPU.ActiveCfg = Release|Any CPU58 {009C72FD-CE2D-4027-87A2-4151B03D2E8F}.Release|Any CPU.Build.0 = Release|Any CPU59 {009C72FD-CE2D-4027-87A2-4151B03D2E8F}.Release|x64.ActiveCfg = Release|x6460 {009C72FD-CE2D-4027-87A2-4151B03D2E8F}.Release|x64.Build.0 = Release|x6461 {009C72FD-CE2D-4027-87A2-4151B03D2E8F}.Release|x86.ActiveCfg = Release|x8662 {009C72FD-CE2D-4027-87A2-4151B03D2E8F}.Release|x86.Build.0 = Release|x8663 {1DBC4D60-0064-4A53-B48C-63D144A67B07}.Debug|Any CPU.ActiveCfg = Debug|Any CPU64 {1DBC4D60-0064-4A53-B48C-63D144A67B07}.Debug|Any CPU.Build.0 = Debug|Any CPU65 {1DBC4D60-0064-4A53-B48C-63D144A67B07}.Debug|x64.ActiveCfg = Debug|x6466 {1DBC4D60-0064-4A53-B48C-63D144A67B07}.Debug|x64.Build.0 = Debug|x6467 {1DBC4D60-0064-4A53-B48C-63D144A67B07}.Debug|x86.ActiveCfg = Debug|x8668 {1DBC4D60-0064-4A53-B48C-63D144A67B07}.Debug|x86.Build.0 = Debug|x8669 {1DBC4D60-0064-4A53-B48C-63D144A67B07}.Release|Any CPU.ActiveCfg = Release|Any CPU70 {1DBC4D60-0064-4A53-B48C-63D144A67B07}.Release|Any CPU.Build.0 = Release|Any CPU71 {1DBC4D60-0064-4A53-B48C-63D144A67B07}.Release|x64.ActiveCfg = Release|x6472 {1DBC4D60-0064-4A53-B48C-63D144A67B07}.Release|x64.Build.0 = Release|x6473 {1DBC4D60-0064-4A53-B48C-63D144A67B07}.Release|x86.ActiveCfg = Release|x8674 {1DBC4D60-0064-4A53-B48C-63D144A67B07}.Release|x86.Build.0 = Release|x8675 {52567721-66A9-4411-9ED6-48DE37732868}.Debug|Any CPU.ActiveCfg = Debug|Any CPU76 {52567721-66A9-4411-9ED6-48DE37732868}.Debug|Any CPU.Build.0 = Debug|Any CPU77 {52567721-66A9-4411-9ED6-48DE37732868}.Debug|x64.ActiveCfg = Debug|x6478 {52567721-66A9-4411-9ED6-48DE37732868}.Debug|x64.Build.0 = Debug|x6479 {52567721-66A9-4411-9ED6-48DE37732868}.Debug|x86.ActiveCfg = Debug|x8680 {52567721-66A9-4411-9ED6-48DE37732868}.Debug|x86.Build.0 = Debug|x8681 {52567721-66A9-4411-9ED6-48DE37732868}.Release|Any CPU.ActiveCfg = Release|Any CPU82 {52567721-66A9-4411-9ED6-48DE37732868}.Release|Any CPU.Build.0 = Release|Any CPU83 {52567721-66A9-4411-9ED6-48DE37732868}.Release|x64.ActiveCfg = Release|x6484 {52567721-66A9-4411-9ED6-48DE37732868}.Release|x64.Build.0 = Release|x6485 {52567721-66A9-4411-9ED6-48DE37732868}.Release|x86.ActiveCfg = Release|x8686 {52567721-66A9-4411-9ED6-48DE37732868}.Release|x86.Build.0 = Release|x8687 {D86DEAB6-61EA-4008-B2AB-8D8CD5665023}.Debug|Any CPU.ActiveCfg = Debug|Any CPU88 {D86DEAB6-61EA-4008-B2AB-8D8CD5665023}.Debug|Any CPU.Build.0 = Debug|Any CPU89 {D86DEAB6-61EA-4008-B2AB-8D8CD5665023}.Debug|x64.ActiveCfg = Debug|x6490 {D86DEAB6-61EA-4008-B2AB-8D8CD5665023}.Debug|x64.Build.0 = Debug|x6491 {D86DEAB6-61EA-4008-B2AB-8D8CD5665023}.Debug|x86.ActiveCfg = Debug|x8692 {D86DEAB6-61EA-4008-B2AB-8D8CD5665023}.Debug|x86.Build.0 = Debug|x8693 {D86DEAB6-61EA-4008-B2AB-8D8CD5665023}.Release|Any CPU.ActiveCfg = Release|Any CPU94 {D86DEAB6-61EA-4008-B2AB-8D8CD5665023}.Release|Any CPU.Build.0 = Release|Any CPU95 {D86DEAB6-61EA-4008-B2AB-8D8CD5665023}.Release|x64.ActiveCfg = Release|x6496 {D86DEAB6-61EA-4008-B2AB-8D8CD5665023}.Release|x64.Build.0 = Release|x6497 {D86DEAB6-61EA-4008-B2AB-8D8CD5665023}.Release|x86.ActiveCfg = Release|x8698 {D86DEAB6-61EA-4008-B2AB-8D8CD5665023}.Release|x86.Build.0 = Release|x8699 {9AADAE96-361F-48F0-B9B0-31B7DACD0492}.Debug|Any CPU.ActiveCfg = Debug|Any CPU100 {9AADAE96-361F-48F0-B9B0-31B7DACD0492}.Debug|Any CPU.Build.0 = Debug|Any CPU101 {9AADAE96-361F-48F0-B9B0-31B7DACD0492}.Debug|x64.ActiveCfg = Debug|x64102 {9AADAE96-361F-48F0-B9B0-31B7DACD0492}.Debug|x64.Build.0 = Debug|x64103 {9AADAE96-361F-48F0-B9B0-31B7DACD0492}.Debug|x86.ActiveCfg = Debug|x86104 {9AADAE96-361F-48F0-B9B0-31B7DACD0492}.Debug|x86.Build.0 = Debug|x86105 {9AADAE96-361F-48F0-B9B0-31B7DACD0492}.Release|Any CPU.ActiveCfg = Release|Any CPU106 {9AADAE96-361F-48F0-B9B0-31B7DACD0492}.Release|Any CPU.Build.0 = Release|Any CPU107 {9AADAE96-361F-48F0-B9B0-31B7DACD0492}.Release|x64.ActiveCfg = Release|x64108 {9AADAE96-361F-48F0-B9B0-31B7DACD0492}.Release|x64.Build.0 = Release|x64109 {9AADAE96-361F-48F0-B9B0-31B7DACD0492}.Release|x86.ActiveCfg = Release|x86110 {9AADAE96-361F-48F0-B9B0-31B7DACD0492}.Release|x86.Build.0 = Release|x86111 {AD85761D-D716-45D4-96E0-5AEF6BD3DE59}.Debug|Any CPU.ActiveCfg = Debug|Any CPU112 {AD85761D-D716-45D4-96E0-5AEF6BD3DE59}.Debug|Any CPU.Build.0 = Debug|Any CPU113 {AD85761D-D716-45D4-96E0-5AEF6BD3DE59}.Debug|x64.ActiveCfg = Debug|x64114 {AD85761D-D716-45D4-96E0-5AEF6BD3DE59}.Debug|x64.Build.0 = Debug|x64115 {AD85761D-D716-45D4-96E0-5AEF6BD3DE59}.Debug|x86.ActiveCfg = Debug|x86116 {AD85761D-D716-45D4-96E0-5AEF6BD3DE59}.Debug|x86.Build.0 = Debug|x86117 {AD85761D-D716-45D4-96E0-5AEF6BD3DE59}.Release|Any CPU.ActiveCfg = Release|Any CPU118 {AD85761D-D716-45D4-96E0-5AEF6BD3DE59}.Release|Any CPU.Build.0 = Release|Any CPU119 {AD85761D-D716-45D4-96E0-5AEF6BD3DE59}.Release|x64.ActiveCfg = Release|x64120 {AD85761D-D716-45D4-96E0-5AEF6BD3DE59}.Release|x64.Build.0 = Release|x64121 {AD85761D-D716-45D4-96E0-5AEF6BD3DE59}.Release|x86.ActiveCfg = Release|x86122 {AD85761D-D716-45D4-96E0-5AEF6BD3DE59}.Release|x86.Build.0 = Release|x86123 {B157FAB7-9B6D-4BAE-ACF2-C6FB7D22EBBD}.Debug|Any CPU.ActiveCfg = Debug|Any CPU124 {B157FAB7-9B6D-4BAE-ACF2-C6FB7D22EBBD}.Debug|Any CPU.Build.0 = Debug|Any CPU125 {B157FAB7-9B6D-4BAE-ACF2-C6FB7D22EBBD}.Debug|x64.ActiveCfg = Debug|x64126 {B157FAB7-9B6D-4BAE-ACF2-C6FB7D22EBBD}.Debug|x64.Build.0 = Debug|x64127 {B157FAB7-9B6D-4BAE-ACF2-C6FB7D22EBBD}.Debug|x86.ActiveCfg = Debug|x86128 {B157FAB7-9B6D-4BAE-ACF2-C6FB7D22EBBD}.Debug|x86.Build.0 = Debug|x86129 {B157FAB7-9B6D-4BAE-ACF2-C6FB7D22EBBD}.Release|Any CPU.ActiveCfg = Release|Any CPU130 {B157FAB7-9B6D-4BAE-ACF2-C6FB7D22EBBD}.Release|Any CPU.Build.0 = Release|Any CPU131 {B157FAB7-9B6D-4BAE-ACF2-C6FB7D22EBBD}.Release|x64.ActiveCfg = Release|x64132 {B157FAB7-9B6D-4BAE-ACF2-C6FB7D22EBBD}.Release|x64.Build.0 = Release|x64133 {B157FAB7-9B6D-4BAE-ACF2-C6FB7D22EBBD}.Release|x86.ActiveCfg = Release|x86134 {B157FAB7-9B6D-4BAE-ACF2-C6FB7D22EBBD}.Release|x86.Build.0 = Release|x86135 {589BECAE-69B0-4EB1-8C06-C073531762B7}.Debug|Any CPU.ActiveCfg = Debug|Any CPU136 {589BECAE-69B0-4EB1-8C06-C073531762B7}.Debug|Any CPU.Build.0 = Debug|Any CPU137 {589BECAE-69B0-4EB1-8C06-C073531762B7}.Debug|x64.ActiveCfg = Debug|x64138 {589BECAE-69B0-4EB1-8C06-C073531762B7}.Debug|x64.Build.0 = Debug|x64139 {589BECAE-69B0-4EB1-8C06-C073531762B7}.Debug|x86.ActiveCfg = Debug|x86140 {589BECAE-69B0-4EB1-8C06-C073531762B7}.Debug|x86.Build.0 = Debug|x86141 {589BECAE-69B0-4EB1-8C06-C073531762B7}.Release|Any CPU.ActiveCfg = Release|Any CPU142 {589BECAE-69B0-4EB1-8C06-C073531762B7}.Release|Any CPU.Build.0 = Release|Any CPU143 {589BECAE-69B0-4EB1-8C06-C073531762B7}.Release|x64.ActiveCfg = Release|x64144 {589BECAE-69B0-4EB1-8C06-C073531762B7}.Release|x64.Build.0 = Release|x64145 {589BECAE-69B0-4EB1-8C06-C073531762B7}.Release|x86.ActiveCfg = Release|x86146 {589BECAE-69B0-4EB1-8C06-C073531762B7}.Release|x86.Build.0 = Release|x86147 {7B60CBDC-E7E3-4610-91E2-7CE831A02D35}.Debug|Any CPU.ActiveCfg = Debug|Any CPU148 {7B60CBDC-E7E3-4610-91E2-7CE831A02D35}.Debug|Any CPU.Build.0 = Debug|Any CPU149 {7B60CBDC-E7E3-4610-91E2-7CE831A02D35}.Debug|x64.ActiveCfg = Debug|x64150 {7B60CBDC-E7E3-4610-91E2-7CE831A02D35}.Debug|x64.Build.0 = Debug|x64151 {7B60CBDC-E7E3-4610-91E2-7CE831A02D35}.Debug|x86.ActiveCfg = Debug|x86152 {7B60CBDC-E7E3-4610-91E2-7CE831A02D35}.Debug|x86.Build.0 = Debug|x86153 {7B60CBDC-E7E3-4610-91E2-7CE831A02D35}.Release|Any CPU.ActiveCfg = Release|Any CPU154 {7B60CBDC-E7E3-4610-91E2-7CE831A02D35}.Release|Any CPU.Build.0 = Release|Any CPU155 {7B60CBDC-E7E3-4610-91E2-7CE831A02D35}.Release|x64.ActiveCfg = Release|x64156 {7B60CBDC-E7E3-4610-91E2-7CE831A02D35}.Release|x64.Build.0 = Release|x64157 {7B60CBDC-E7E3-4610-91E2-7CE831A02D35}.Release|x86.ActiveCfg = Release|x86158 {7B60CBDC-E7E3-4610-91E2-7CE831A02D35}.Release|x86.Build.0 = Release|x86159 {CFBF2410-99A1-44EC-BFEA-F1AD4C3DA622}.Debug|Any CPU.ActiveCfg = Debug|Any CPU160 {CFBF2410-99A1-44EC-BFEA-F1AD4C3DA622}.Debug|Any CPU.Build.0 = Debug|Any CPU161 {CFBF2410-99A1-44EC-BFEA-F1AD4C3DA622}.Debug|x64.ActiveCfg = Debug|x64162 {CFBF2410-99A1-44EC-BFEA-F1AD4C3DA622}.Debug|x64.Build.0 = Debug|x64163 {CFBF2410-99A1-44EC-BFEA-F1AD4C3DA622}.Debug|x86.ActiveCfg = Debug|x86164 {CFBF2410-99A1-44EC-BFEA-F1AD4C3DA622}.Debug|x86.Build.0 = Debug|x86165 {CFBF2410-99A1-44EC-BFEA-F1AD4C3DA622}.Release|Any CPU.ActiveCfg = Release|Any CPU166 {CFBF2410-99A1-44EC-BFEA-F1AD4C3DA622}.Release|Any CPU.Build.0 = Release|Any CPU167 {CFBF2410-99A1-44EC-BFEA-F1AD4C3DA622}.Release|x64.ActiveCfg = Release|x64168 {CFBF2410-99A1-44EC-BFEA-F1AD4C3DA622}.Release|x64.Build.0 = Release|x64169 {CFBF2410-99A1-44EC-BFEA-F1AD4C3DA622}.Release|x86.ActiveCfg = Release|x86170 {CFBF2410-99A1-44EC-BFEA-F1AD4C3DA622}.Release|x86.Build.0 = Release|x86171 29 {73857A9C-9706-4B72-8D9C-210B5B6A5691}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 172 30 {73857A9C-9706-4B72-8D9C-210B5B6A5691}.Debug|Any CPU.Build.0 = Debug|Any CPU … … 197 55 {E36BE58F-F3CE-40BB-9AB3-9F9E30AD5CCF}.Release|x86.ActiveCfg = Release|x86 198 56 {E36BE58F-F3CE-40BB-9AB3-9F9E30AD5CCF}.Release|x86.Build.0 = Release|x86 199 {E80A68DB-D6E1-4395-ABF0-AFE09E4DEF8B}.Debug|Any CPU.ActiveCfg = Debug|Any CPU200 {E80A68DB-D6E1-4395-ABF0-AFE09E4DEF8B}.Debug|Any CPU.Build.0 = Debug|Any CPU201 {E80A68DB-D6E1-4395-ABF0-AFE09E4DEF8B}.Debug|x64.ActiveCfg = Debug|x64202 {E80A68DB-D6E1-4395-ABF0-AFE09E4DEF8B}.Debug|x64.Build.0 = Debug|x64203 {E80A68DB-D6E1-4395-ABF0-AFE09E4DEF8B}.Debug|x86.ActiveCfg = Debug|x86204 {E80A68DB-D6E1-4395-ABF0-AFE09E4DEF8B}.Debug|x86.Build.0 = Debug|x86205 {E80A68DB-D6E1-4395-ABF0-AFE09E4DEF8B}.Release|Any CPU.ActiveCfg = Release|Any CPU206 {E80A68DB-D6E1-4395-ABF0-AFE09E4DEF8B}.Release|Any CPU.Build.0 = Release|Any CPU207 {E80A68DB-D6E1-4395-ABF0-AFE09E4DEF8B}.Release|x64.ActiveCfg = Release|x64208 {E80A68DB-D6E1-4395-ABF0-AFE09E4DEF8B}.Release|x64.Build.0 = Release|x64209 {E80A68DB-D6E1-4395-ABF0-AFE09E4DEF8B}.Release|x86.ActiveCfg = Release|x86210 {E80A68DB-D6E1-4395-ABF0-AFE09E4DEF8B}.Release|x86.Build.0 = Release|x86211 57 {766DA4B7-2A0E-4CDE-8F90-93D8B1AD62CF}.Debug|Any CPU.ActiveCfg = Debug|Any CPU 212 58 {766DA4B7-2A0E-4CDE-8F90-93D8B1AD62CF}.Debug|Any CPU.Build.0 = Debug|Any CPU -
branches/OKB/HeuristicLab.Services.OKB.DataAccess/3.3/Tests/UnitTest.cs
r4384 r4558 20 20 #endregion 21 21 22 using System; 23 using System.Text; 24 using System.Collections.Generic; 25 using System.Linq; 26 using System.Data.Linq; 22 using HeuristicLab.Services.OKB.DataAccess; 27 23 using Microsoft.VisualStudio.TestTools.UnitTesting; 28 using HeuristicLab.Services.OKB.DataAccess;29 24 30 25 namespace HeuristicLab.Services.OKB.DataAccess_33.Tests { … … 85 80 okb.Algorithms.DeleteAllOnSubmit(okb.Algorithms); 86 81 okb.Problems.DeleteAllOnSubmit(okb.Problems); 87 okb.SolutionRepresentations.DeleteAllOnSubmit(okb.SolutionRepresentations);88 82 okb.ProblemClasses.DeleteAllOnSubmit(okb.ProblemClasses); 89 83 okb.AlgorithmClasses.DeleteAllOnSubmit(okb.AlgorithmClasses); … … 91 85 AlgorithmClass ac = new AlgorithmClass() { Name = "AlgorithmClass" }; 92 86 ProblemClass pc = new ProblemClass() { Name = "ProblemClass" }; 93 SolutionRepresentation sr = new SolutionRepresentation() { Name = "SolutionRepresentation" };94 87 Algorithm a = new Algorithm() { Name = "Alg", AlgorithmClass = ac, PlatformId = 1 }; 95 Problem p = new Problem() { Name = "Prb", ProblemClass = pc, SolutionRepresentation = sr,PlatformId = 1 };88 Problem p = new Problem() { Name = "Prb", ProblemClass = pc, PlatformId = 1 }; 96 89 Experiment e = new Experiment() { Algorithm = a, Problem = p }; 97 90 AlgorithmParameter ap = new AlgorithmParameter() { Name = "Param", Algorithm = a, DataTypeId = 1 };
Note: See TracChangeset
for help on using the changeset viewer.