Free cookie consent management tool by TermsFeed Policy Generator

Ignore:
Timestamp:
09/20/16 17:14:41 (8 years ago)
Author:
bburlacu
Message:

#2672: Add cloning constructors.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/sources/HeuristicLab.Problems.DataAnalysis/3.4/OnlineCalculators/OnlineMaxAbsoluteErrorCalculator.cs

    r14293 r14294  
    3939    }
    4040
    41     // private constructor used internally by the Clone() method
    42     private OnlineMaxAbsoluteErrorCalculator(OnlineMaxAbsoluteErrorCalculator other) {
     41    protected OnlineMaxAbsoluteErrorCalculator(OnlineMaxAbsoluteErrorCalculator other, Cloner cloner = null) {
    4342      mae = other.mae;
    4443      n = other.n;
     
    105104      var clone = cloner.GetClone(this);
    106105      if (clone == null) {
    107         clone = (IDeepCloneable)this.Clone();
     106        clone = new OnlineMaxAbsoluteErrorCalculator(this);
    108107        cloner.RegisterClonedObject(this, clone);
    109108      }
Note: See TracChangeset for help on using the changeset viewer.