Changeset 14330 for branches/symbreg-factors-2650/HeuristicLab.Problems.DataAnalysis/3.4/OnlineCalculators/OnlineMeanErrorCalculator.cs
- Timestamp:
- 10/13/16 19:47:41 (8 years ago)
- Location:
- branches/symbreg-factors-2650
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/symbreg-factors-2650
- Property svn:mergeinfo changed
/trunk/sources merged: 14282,14284-14300,14307,14314-14316,14319,14322
- Property svn:mergeinfo changed
-
branches/symbreg-factors-2650/HeuristicLab.Problems.DataAnalysis
- Property svn:mergeinfo changed
/trunk/sources/HeuristicLab.Problems.DataAnalysis merged: 14289-14290,14292-14295
- Property svn:mergeinfo changed
-
branches/symbreg-factors-2650/HeuristicLab.Problems.DataAnalysis/3.4/OnlineCalculators/OnlineMeanErrorCalculator.cs
r14185 r14330 22 22 using System; 23 23 using System.Collections.Generic; 24 using HeuristicLab.Common; 24 25 25 26 namespace HeuristicLab.Problems.DataAnalysis { 26 public class OnlineMeanErrorCalculator : IOnlineCalculator {27 public class OnlineMeanErrorCalculator : IOnlineCalculator, IDeepCloneable { 27 28 28 29 private readonly OnlineMeanAndVarianceCalculator meanAndVarianceCalculator; … … 34 35 meanAndVarianceCalculator = new OnlineMeanAndVarianceCalculator(); 35 36 Reset(); 37 } 38 39 protected OnlineMeanErrorCalculator(OnlineMeanErrorCalculator other, Cloner cloner) { 40 meanAndVarianceCalculator = (OnlineMeanAndVarianceCalculator)other.meanAndVarianceCalculator.Clone(cloner); 36 41 } 37 42 … … 74 79 } 75 80 } 81 82 // IDeepCloneable members 83 public object Clone() { 84 var cloner = new Cloner(); 85 return new OnlineMeanErrorCalculator(this, cloner); 86 } 87 88 public IDeepCloneable Clone(Cloner cloner) { 89 var clone = cloner.GetClone(this); 90 if (clone == null) { 91 clone = new OnlineMeanErrorCalculator(this, cloner); 92 cloner.RegisterClonedObject(this, clone); 93 } 94 return clone; 95 } 76 96 } 77 97 }
Note: See TracChangeset
for help on using the changeset viewer.