Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
05/04/17 17:19:35 (7 years ago)
Author:
gkronber
Message:

#2520: changed all usages of StorableClass to use StorableType with an auto-generated GUID (did not add StorableType to other type definitions yet)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/PersistenceReintegration/HeuristicLab.Algorithms.Benchmarks/3.3/BenchmarkAlgorithm.cs

    r14185 r14927  
    3232using HeuristicLab.Optimization;
    3333using HeuristicLab.Parameters;
    34 using HeuristicLab.Persistence.Default.CompositeSerializers.Storable;
     34using HeuristicLab.Persistence;
    3535using HeuristicLab.PluginInfrastructure;
    3636
     
    3838  [Item("Benchmark Algorithm", "An algorithm to execute performance benchmarks (Linpack, Dhrystone, Whetstone, etc.).")]
    3939  [Creatable(CreatableAttribute.Categories.TestingAndAnalysis, Priority = 130)]
    40   [StorableClass]
     40  [StorableType("ba854a73-3342-471c-a7f9-314435879f90")]
    4141  public sealed class BenchmarkAlgorithm : IAlgorithm {
    4242    private CancellationTokenSource cancellationTokenSource;
     
    308308        try {
    309309          t.Wait();
    310         }
    311         catch (AggregateException ex) {
     310        } catch (AggregateException ex) {
    312311          try {
    313312            ex.Flatten().Handle(x => x is OperationCanceledException);
    314           }
    315           catch (AggregateException remaining) {
     313          } catch (AggregateException remaining) {
    316314            if (remaining.InnerExceptions.Count == 1) OnExceptionOccurred(remaining.InnerExceptions[0]);
    317315            else OnExceptionOccurred(remaining);
     
    346344        Benchmark.TimeLimit = timelimit;
    347345        Benchmark.Run(cancellationToken, results);
    348       }
    349       catch (OperationCanceledException) {
    350       }
    351       finally {
     346      } catch (OperationCanceledException) {
     347      } finally {
    352348        timer.Elapsed -= new System.Timers.ElapsedEventHandler(timer_Elapsed);
    353349        timer.Stop();
Note: See TracChangeset for help on using the changeset viewer.