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
SecurityIdSecurity ID.
arg
objectThe additional argument, associated with data. For example, candle arg.
getData
Func<DateTimeOffset, IEnumerable<Message>>Handler for retrieving in-memory data.
dataType
TypeData 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
SecurityIdSecurity ID.
arg
objectThe additional argument, associated with data. For example, candle arg.
getData
Func<DateTimeOffset, IEnumerable<T>>Handler for retrieving in-memory data.
dataType
TypeData type.
Methods
Load(DateTime)
To load data.
public IEnumerable<T> Load(DateTime date)
Parameters
date
DateTimeDate, for which data shall be loaded.
Returns
- IEnumerable<T>
Data. If there is no data, the empty set will be returned.