Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
10/29/10 15:59:12 (14 years ago)
Author:
abeham
Message:

#922

  • Refactored HeuristicLab.Data
  • Refactored HeuristicLab.Operators
File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/CloningRefactoring/HeuristicLab.Data/3.3/StringArray.cs

    r4068 r4662  
    7070    }
    7171
     72    [StorableConstructor]
     73    protected StringArray(bool deserializing) : base(deserializing) { }
     74    protected StringArray(StringArray original, Cloner cloner)
     75      : base(original, cloner) {
     76      this.array = (string[])original.array.Clone();
     77      this.readOnly = original.readOnly;
     78    }
    7279    public StringArray() {
    7380      array = new string[0];
     
    8996
    9097    public override IDeepCloneable Clone(Cloner cloner) {
    91       StringArray clone = new StringArray();
    92       cloner.RegisterClonedObject(this, clone);
    93       clone.array = (string[])array.Clone();
    94       clone.readOnly = readOnly;
    95       return clone;
     98      return new StringArray(this, cloner);
    9699    }
    97100
Note: See TracChangeset for help on using the changeset viewer.