Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
11/06/10 01:56:04 (14 years ago)
Author:
swagner
Message:

Merged cloning refactoring branch back into trunk (#922)

Location:
trunk/sources
Files:
7 edited

Legend:

Unmodified
Added
Removed
  • trunk/sources

  • trunk/sources/HeuristicLab.Problems.ExternalEvaluation/3.3/Converters/BoolConverter.cs

    r3881 r4722  
    2222using System;
    2323using System.Linq;
     24using HeuristicLab.Common;
    2425using HeuristicLab.Core;
    2526using HeuristicLab.Data;
     
    3132  public class BoolConverter : Item, IItemToSolutionMessageConverter {
    3233    private static readonly Type[] itemTypes = new Type[] { typeof(ValueTypeValue<bool>), typeof(ValueTypeArray<bool>), typeof(ValueTypeMatrix<bool>) };
     34    [StorableConstructor]
     35    protected BoolConverter(bool deserializing) : base(deserializing) { }
     36    protected BoolConverter(BoolConverter original, Cloner cloner) : base(original, cloner) { }
     37    public override IDeepCloneable Clone(Cloner cloner) {
     38      return new BoolConverter(this, cloner);
     39    }
     40    public BoolConverter() : base() { }
    3341
    3442    #region IItemToSolutionMessageConverter Members
    35    
     43
    3644    public Type[] ItemTypes {
    3745      get { return itemTypes; }
  • trunk/sources/HeuristicLab.Problems.ExternalEvaluation/3.3/Converters/DateTimeValueConverter.cs

    r4068 r4722  
    2121
    2222using System;
     23using HeuristicLab.Common;
    2324using HeuristicLab.Core;
    2425using HeuristicLab.Data;
     
    3031  public class DateTimeValueConverter : Item, IItemToSolutionMessageConverter {
    3132    private static readonly Type[] itemTypes = new Type[] { typeof(DateTimeValue) };
     33    [StorableConstructor]
     34    protected DateTimeValueConverter(bool deserializing) : base(deserializing) { }
     35    protected DateTimeValueConverter(DateTimeValueConverter original, Cloner cloner) : base(original, cloner) { }
     36    public override IDeepCloneable Clone(Cloner cloner) {
     37      return new DateTimeValueConverter(this, cloner);
     38    }
     39    public DateTimeValueConverter() : base() { }
    3240
    3341    #region IItemToSolutionMessageConverter Members
  • trunk/sources/HeuristicLab.Problems.ExternalEvaluation/3.3/Converters/DoubleConverter.cs

    r3881 r4722  
    2222using System;
    2323using System.Linq;
     24using HeuristicLab.Common;
    2425using HeuristicLab.Core;
    2526using HeuristicLab.Data;
     
    3233    private static readonly Type[] itemTypes = new Type[] { typeof(ValueTypeValue<double>), typeof(ValueTypeArray<double>), typeof(ValueTypeMatrix<double>) };
    3334
     35    [StorableConstructor]
     36    protected DoubleConverter(bool deserializing) : base(deserializing) { }
     37    protected DoubleConverter(DoubleConverter original, Cloner cloner) : base(original, cloner) { }
     38    public override IDeepCloneable Clone(Cloner cloner) {
     39      return new DoubleConverter(this, cloner);
     40    }
     41    public DoubleConverter() : base() { }
     42
    3443    #region IItemToSolutionMessageConverter Members
    35    
     44
    3645    public Type[] ItemTypes {
    3746      get { return itemTypes; }
  • trunk/sources/HeuristicLab.Problems.ExternalEvaluation/3.3/Converters/IntegerConverter.cs

    r3881 r4722  
    2222using System;
    2323using System.Linq;
     24using HeuristicLab.Common;
    2425using HeuristicLab.Core;
    2526using HeuristicLab.Data;
     
    3233    private static readonly Type[] itemTypes = new Type[] { typeof(ValueTypeValue<int>), typeof(ValueTypeArray<int>), typeof(ValueTypeMatrix<int>) };
    3334
     35    [StorableConstructor]
     36    protected IntegerConverter(bool deserializing) : base(deserializing) { }
     37    protected IntegerConverter(IntegerConverter original, Cloner cloner) : base(original, cloner) { }
     38    public override IDeepCloneable Clone(Cloner cloner) {
     39      return new IntegerConverter(this, cloner);
     40    }
     41    public IntegerConverter() : base() { }
     42
    3443    #region IItemToSolutionMessageConverter Members
    35    
     44
    3645    public Type[] ItemTypes {
    3746      get { return itemTypes; }
  • trunk/sources/HeuristicLab.Problems.ExternalEvaluation/3.3/Converters/StringConverter.cs

    r4068 r4722  
    2121
    2222using System;
     23using HeuristicLab.Common;
    2324using HeuristicLab.Core;
    2425using HeuristicLab.Data;
     
    3031  public class StringConverter : Item, IItemToSolutionMessageConverter {
    3132    private static readonly Type[] itemTypes = new Type[] { typeof(StringValue), typeof(StringArray), typeof(StringMatrix), typeof(IStringConvertibleValue), typeof(IStringConvertibleArray), typeof(IStringConvertibleMatrix) };
     33
     34    [StorableConstructor]
     35    protected StringConverter(bool deserializing) : base(deserializing) { }
     36    protected StringConverter(StringConverter original, Cloner cloner) : base(original, cloner) { }
     37    public override IDeepCloneable Clone(Cloner cloner) {
     38      return new StringConverter(this, cloner);
     39    }
     40    public StringConverter() : base() { }
    3241
    3342    #region IItemToSolutionMessageConverter Members
  • trunk/sources/HeuristicLab.Problems.ExternalEvaluation/3.3/Converters/TimeSpanValueConverter.cs

    r4068 r4722  
    2121
    2222using System;
     23using HeuristicLab.Common;
    2324using HeuristicLab.Core;
    2425using HeuristicLab.Data;
     
    3031  public class TimeSpanValueConverter : Item, IItemToSolutionMessageConverter {
    3132    private static readonly Type[] itemTypes = new Type[] { typeof(TimeSpanValue) };
     33
     34    [StorableConstructor]
     35    protected TimeSpanValueConverter(bool deserializing) : base(deserializing) { }
     36    protected TimeSpanValueConverter(TimeSpanValueConverter original, Cloner cloner) : base(original, cloner) { }
     37    public override IDeepCloneable Clone(Cloner cloner) {
     38      return new TimeSpanValueConverter(this, cloner);
     39    }
     40    public TimeSpanValueConverter() : base() { }
    3241
    3342    #region IItemToSolutionMessageConverter Members
Note: See TracChangeset for help on using the changeset viewer.