IRange

StockSharp.Xaml.Charting

Defines the generic interface to a Range (Min, Max), used throughout Ultrachart for visible, data and index range calculations

Implements: IRange, ICloneable, INotifyPropertyChanged

Properties

Diff
public T Diff { get; }
value = iRange.Diff

Gets the Diff (Max - Min) of this range

Max
public T Max { get; set; }
value = iRange.Max
iRange.Max = value

Gets or sets the Max value of this range

Min
public T Min { get; set; }
value = iRange.Min
iRange.Min = value

Gets or sets the Min value of this range

Methods

GrowBy
public IRange<T> GrowBy(double minFraction, double maxFraction)
result = iRange.GrowBy(minFraction, maxFraction)

Grows the current IRange by the min and max fraction, returning this instance after modification

minFraction
The Min fraction to grow by. For example, Min = -10 and minFraction = 0.1 will result in the new Min = -11
maxFraction
The Max fraction to grow by. For example, Max = 10 and maxFraction = 0.2 will result in the new Max = 12

Returns: This instance, after the operation

SetMinMax
public IRange<T> SetMinMax(double min, double max)
result = iRange.SetMinMax(min, max)

Sets the Min, Max values on the IRange, returning this instance after modification

min
The new Min value.
max
The new Max value.

Returns: This instance, after the operation

Union
public IRange<T> Union(IRange<T> range)
result = iRange.Union(range)

Performs the Union of two IRange instances, returning a new IRange

range