Free cookie consent management tool by TermsFeed Policy Generator

Changeset 6519


Ignore:
Timestamp:
07/06/11 20:52:53 (13 years ago)
Author:
abeham
Message:

#1516

  • fixed code formatting
  • added some license headers
  • removed unnecessary resx file
Location:
trunk/sources
Files:
1 deleted
7 edited

Legend:

Unmodified
Added
Removed
  • trunk/sources/HeuristicLab.Problems.ExternalEvaluation.Views/3.3/EvaluationCacheView.Designer.cs

    r6265 r6519  
    1 namespace HeuristicLab.Problems.ExternalEvaluation.Views {
     1#region License Information
     2/* HeuristicLab
     3 * Copyright (C) 2002-2011 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
     4 *
     5 * This file is part of HeuristicLab.
     6 *
     7 * HeuristicLab is free software: you can redistribute it and/or modify
     8 * it under the terms of the GNU General Public License as published by
     9 * the Free Software Foundation, either version 3 of the License, or
     10 * (at your option) any later version.
     11 *
     12 * HeuristicLab is distributed in the hope that it will be useful,
     13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
     14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
     15 * GNU General Public License for more details.
     16 *
     17 * You should have received a copy of the GNU General Public License
     18 * along with HeuristicLab. If not, see <http://www.gnu.org/licenses/>.
     19 */
     20#endregion
     21
     22namespace HeuristicLab.Problems.ExternalEvaluation.Views {
    223  partial class EvaluationCacheView {
    324    /// <summary>
     
    5374      // hits_sizeTextBox
    5475      //
    55       this.hits_sizeTextBox.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left) 
     76      this.hits_sizeTextBox.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left)
    5677            | System.Windows.Forms.AnchorStyles.Right)));
    5778      this.hits_sizeTextBox.Location = new System.Drawing.Point(59, 26);
  • trunk/sources/HeuristicLab.Problems.ExternalEvaluation.Views/3.3/EvaluationCacheView.cs

    r6291 r6519  
    1 using System;
     1#region License Information
     2/* HeuristicLab
     3 * Copyright (C) 2002-2011 Heuristic and Evolutionary Algorithms Laboratory (HEAL)
     4 *
     5 * This file is part of HeuristicLab.
     6 *
     7 * HeuristicLab is free software: you can redistribute it and/or modify
     8 * it under the terms of the GNU General Public License as published by
     9 * the Free Software Foundation, either version 3 of the License, or
     10 * (at your option) any later version.
     11 *
     12 * HeuristicLab is distributed in the hope that it will be useful,
     13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
     14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
     15 * GNU General Public License for more details.
     16 *
     17 * You should have received a copy of the GNU General Public License
     18 * along with HeuristicLab. If not, see <http://www.gnu.org/licenses/>.
     19 */
     20#endregion
     21
     22using System;
     23using System.ComponentModel;
    224using System.Windows.Forms;
    325using HeuristicLab.Core.Views;
    426using HeuristicLab.MainForm;
    5 using System.Threading;
    6 using System.IO;
    7 using System.ComponentModel;
    827
    928namespace HeuristicLab.Problems.ExternalEvaluation.Views {
     
    6281    }
    6382    #endregion
    64    
     83
    6584    private void saveButton_Click(object sender, EventArgs e) {
    6685      if (saveFileDialog.ShowDialog() == DialogResult.OK) {
     
    7594        worker.RunWorkerAsync(saveFileDialog.FileName);
    7695      }
    77     }   
     96    }
    7897  }
    7998}
  • trunk/sources/HeuristicLab.Problems.ExternalEvaluation.Views/3.3/HeuristicLab.Problems.ExternalEvaluation.Views-3.3.csproj

    r6140 r6519  
    9494  </PropertyGroup>
    9595  <ItemGroup>
     96    <Reference Include="HeuristicLab.Data.Views-3.3">
     97      <HintPath>..\..\HeuristicLab.Data.Views\3.3\bin\x86\Release\HeuristicLab.Data.Views-3.3.dll</HintPath>
     98    </Reference>
     99    <Reference Include="HeuristicLab.Optimization-3.3, Version=3.3.0.0, Culture=neutral, PublicKeyToken=ba48961d6f65dcec, processorArchitecture=x86" />
    96100    <Reference Include="System" />
    97101    <Reference Include="System.Core">
     
    173177      <Project>{3BD61258-31DA-4B09-89C0-4F71FEF5F05A}</Project>
    174178      <Name>HeuristicLab.MainForm-3.3</Name>
     179    </ProjectReference>
     180    <ProjectReference Include="..\..\HeuristicLab.Optimization.Views\3.3\HeuristicLab.Optimization.Views-3.3.csproj">
     181      <Project>{662B4B15-8F4D-4AE5-B3EB-D91C215F5AF2}</Project>
     182      <Name>HeuristicLab.Optimization.Views-3.3</Name>
    175183    </ProjectReference>
    176184    <ProjectReference Include="..\..\HeuristicLab.PluginInfrastructure\3.3\HeuristicLab.PluginInfrastructure-3.3.csproj">
     
    203211    </BootstrapperPackage>
    204212  </ItemGroup>
    205   <ItemGroup>
    206     <EmbeddedResource Include="EvaluationCacheView.resx">
    207       <DependentUpon>EvaluationCacheView.cs</DependentUpon>
    208     </EmbeddedResource>
    209   </ItemGroup>
    210213  <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
    211214  <PropertyGroup>
  • trunk/sources/HeuristicLab.Problems.ExternalEvaluation/3.3/CachedExternalEvaluator.cs

    r6189 r6519  
    2020#endregion
    2121
    22 
    2322using System.Threading;
    2423using HeuristicLab.Common;
     
    2726using HeuristicLab.Parameters;
    2827using HeuristicLab.Persistence.Default.CompositeSerializers.Storable;
     28
    2929namespace HeuristicLab.Problems.ExternalEvaluation {
    3030
  • trunk/sources/HeuristicLab.Problems.ExternalEvaluation/3.3/Drivers/EvaluationServiceClient.cs

    r6470 r6519  
    5252    [StorableConstructor]
    5353    protected EvaluationServiceClient(bool deserializing) : base(deserializing) { }
    54     protected EvaluationServiceClient(EvaluationServiceClient original, Cloner cloner) : base(original, cloner) {
     54    protected EvaluationServiceClient(EvaluationServiceClient original, Cloner cloner)
     55      : base(original, cloner) {
    5556      RegisterEvents();
    56     }   
     57    }
    5758    public EvaluationServiceClient()
    5859      : base() {
     
    8384          result = (QualityMessage)Channel.Receive(QualityMessage.CreateBuilder());
    8485          success = true;
    85         }
    86         catch (InvalidOperationException) {
     86        } catch (InvalidOperationException) {
    8787          throw;
    88         }
    89         catch {
     88        } catch {
    9089          if (tries >= maxTries)
    9190            throw;
     
    104103          Channel.Send(solution);
    105104          success = true;
    106         }
    107         catch (InvalidOperationException) {
     105        } catch (InvalidOperationException) {
    108106          throw;
    109         }
    110         catch {
     107        } catch {
    111108          if (tries >= maxTries)
    112109            throw;
     
    123120        try {
    124121          Channel.Open();
    125         }
    126         catch (Exception e) {
     122        } catch (Exception e) {
    127123          throw new InvalidOperationException(Name + ": The channel could not be opened.", e);
    128124        }
     
    134130      try {
    135131        message = (QualityMessage)Channel.Receive(QualityMessage.CreateBuilder());
    136       }
    137       catch { }
     132      } catch { }
    138133      ((Action<QualityMessage>)callback).Invoke(message);
    139134    }
  • trunk/sources/HeuristicLab.Problems.ExternalEvaluation/3.3/EvaluationCache.cs

    r6291 r6519  
    2525using System;
    2626using System.Collections.Generic;
     27using System.Globalization;
     28using System.IO;
    2729using System.Linq;
     30using System.Text.RegularExpressions;
    2831using System.Threading;
    2932using HeuristicLab.Common;
     
    3336using HeuristicLab.Parameters;
    3437using HeuristicLab.Persistence.Default.CompositeSerializers.Storable;
    35 using HeuristicLab.Analysis;
    36 using System.IO;
    37 using System.Globalization;
    38 using System.Text.RegularExpressions;
     38
    3939namespace HeuristicLab.Problems.ExternalEvaluation {
    4040
     
    8282
    8383    private HashSet<string> activeEvaluations = new HashSet<string>();
    84     private object cacheLock = new object();   
     84    private object cacheLock = new object();
    8585    #endregion
    8686
     
    126126
    127127    #region Persistence
    128     [Storable(Name="Cache")]
     128    [Storable(Name = "Cache")]
    129129    private IEnumerable<KeyValuePair<string, double>> Cache_Persistence {
    130130      get {
     
    194194      bool lockTaken = false;
    195195      bool waited = false;
    196       try {       
     196      try {
    197197        Monitor.Enter(cacheLock, ref lockTaken);
    198198        while (true) {
  • trunk/sources/HeuristicLab.Problems.ExternalEvaluation/3.3/ExternalEvaluator.cs

    r6460 r6519  
    5959    #region Fields
    6060    protected HashSet<IEvaluationServiceClient> activeClients = new HashSet<IEvaluationServiceClient>();
    61     protected object clientLock = new object();   
     61    protected object clientLock = new object();
    6262    #endregion
    6363
Note: See TracChangeset for help on using the changeset viewer.