Class BaseIndicatorValue
- Namespace
- StockSharp.Algo.Indicators
- Assembly
- StockSharp.BusinessEntities.dll
The base class for the indicator value.
public abstract class BaseIndicatorValue : IIndicatorValue, IComparable<IIndicatorValue>, IComparable
- Inheritance
-
BaseIndicatorValue
- Implements
- Derived
- Inherited Members
- Extension Methods
Constructors
BaseIndicatorValue(IIndicator, DateTimeOffset)
Initialize BaseIndicatorValue.
protected BaseIndicatorValue(IIndicator indicator, DateTimeOffset time)
Parameters
indicator
IIndicatorIndicator.
time
DateTimeOffset
Properties
Indicator
Indicator.
public IIndicator Indicator { get; }
Property Value
IsEmpty
No indicator value.
public abstract bool IsEmpty { get; set; }
Property Value
IsFinal
Is the value final (indicator finalizes its value and will not be changed anymore in the given point of time).
public abstract bool IsFinal { get; set; }
Property Value
IsFormed
Whether the indicator is set.
public bool IsFormed { get; set; }
Property Value
Time
Value time.
public DateTimeOffset Time { get; }
Property Value
Methods
CompareTo(IIndicatorValue)
public abstract int CompareTo(IIndicatorValue other)
Parameters
other
IIndicatorValue
Returns
FromValues(object[])
Convert to indicator value.
public abstract void FromValues(object[] values)
Parameters
values
object[]
GetValue<T>(Level1Fields?)
To get the value by the data type.
public abstract T GetValue<T>(Level1Fields? field)
Parameters
field
Level1Fields?Field specified value source.
Returns
- T
Value.
Type Parameters
T
The data type, operated by indicator.
IsSupport(Type)
Does value support data type, required for the indicator.
public abstract bool IsSupport(Type valueType)
Parameters
valueType
TypeThe data type, operated by indicator.
Returns
SetValue<T>(IIndicator, T)
To replace the indicator input value by new one (for example it is received from another indicator).
public abstract IIndicatorValue SetValue<T>(IIndicator indicator, T value)
Parameters
indicator
IIndicatorIndicator.
value
TValue.
Returns
- IIndicatorValue
New object, containing input value.
Type Parameters
T
The data type, operated by indicator.
ToValues()
Convert to primitive values.
public abstract IEnumerable<object> ToValues()
Returns
- IEnumerable<object>
Primitive values.