/// <summary> /// Creates a new object that is a copy of the current instance. /// </summary> /// /// <returns> /// A new object that is a copy of this instance. /// </returns> /// public object Clone() { Histogram clone = new Histogram(); clone.initialize(this.values.Length); for (int i = 0; i < clone.ranges.Length; i++) { clone.ranges[i] = this.ranges[i]; } for (int i = 0; i < clone.values.Length; i++) { clone.values[i] = this.values[i]; } clone.cumulative = this.cumulative; clone.inclusiveUpperBound = this.inclusiveUpperBound; clone.rule = this.rule; return(clone); }
/// <summary> /// Creates a new object that is a copy of the current instance. /// </summary> /// /// <returns> /// A new object that is a copy of this instance. /// </returns> /// public object Clone() { Histogram clone = new Histogram(); clone.initialize(this.values.Length); for (int i = 0; i < clone.ranges.Length; i++) clone.ranges[i] = this.ranges[i]; for (int i = 0; i < clone.values.Length; i++) clone.values[i] = this.values[i]; clone.cumulative = this.cumulative; clone.inclusiveUpperBound = this.inclusiveUpperBound; clone.rule = this.rule; return clone; }