Table of Contents

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 IIndicator

Indicator.

time DateTimeOffset

Time

Properties

Indicator

Indicator.

public IIndicator Indicator { get; }

Property Value

IIndicator

IsEmpty

No indicator value.

public abstract bool IsEmpty { get; set; }

Property Value

bool

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

bool

IsFormed

Whether the indicator is set.

public bool IsFormed { get; set; }

Property Value

bool

Time

Value time.

public DateTimeOffset Time { get; }

Property Value

DateTimeOffset

Methods

CompareTo(IIndicatorValue)

public abstract int CompareTo(IIndicatorValue other)

Parameters

other IIndicatorValue

Returns

int

FromValues(object[])

Convert to indicator value.

public abstract void FromValues(object[] values)

Parameters

values object[]

ToValues()

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 Type

The data type, operated by indicator.

Returns

bool

true, if data type is supported, otherwise, false.

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 IIndicator

Indicator.

value T

Value.

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.