Table of Contents

Class InMemoryMarketDataStorage<T>

Namespace
StockSharp.Algo.Storages
Assembly
StockSharp.Algo.dll

The storage, generating data in the process of operation.

public sealed class InMemoryMarketDataStorage<T> : IMarketDataStorage<T>, IMarketDataStorage where T : Message

Type Parameters

T

Data type.

Inheritance
InMemoryMarketDataStorage<T>
Implements
Inherited Members
Extension Methods

Constructors

InMemoryMarketDataStorage(SecurityId, object, Func<DateTimeOffset, IEnumerable<Message>>, Type)

Initializes a new instance of the InMemoryMarketDataStorage<T>.

public InMemoryMarketDataStorage(SecurityId securityId, object arg, Func<DateTimeOffset, IEnumerable<Message>> getData, Type dataType = null)

Parameters

securityId SecurityId

Security ID.

arg object

The additional argument, associated with data. For example, candle arg.

getData Func<DateTimeOffset, IEnumerable<Message>>

Handler for retrieving in-memory data.

dataType Type

Data type.

InMemoryMarketDataStorage(SecurityId, object, Func<DateTimeOffset, IEnumerable<T>>, Type)

Initializes a new instance of the InMemoryMarketDataStorage<T>.

public InMemoryMarketDataStorage(SecurityId securityId, object arg, Func<DateTimeOffset, IEnumerable<T>> getData, Type dataType = null)

Parameters

securityId SecurityId

Security ID.

arg object

The additional argument, associated with data. For example, candle arg.

getData Func<DateTimeOffset, IEnumerable<T>>

Handler for retrieving in-memory data.

dataType Type

Data type.

Methods

Load(DateTime)

To load data.

public IEnumerable<T> Load(DateTime date)

Parameters

date DateTime

Date, for which data shall be loaded.

Returns

IEnumerable<T>

Data. If there is no data, the empty set will be returned.