CsvImporter

StockSharp.Algo.Import

Messages importer from text file in CSV format into storage.

Inherits: CsvParser

Constructors

CsvImporter(DataType, IEnumerable<FieldMapping>, ISecurityStorage, IExchangeInfoProvider, Func<SecurityId, IMarketDataStorage>)

Messages importer from text file in CSV format into storage.

dataType
Data type info.
fields
Importing fields.
securityStorage
Securities meta info storage.
exchangeInfoProvider
Exchanges and trading boards provider.
getStorage
Function to get IMarketDataStorage by SecurityId.

Properties

UpdateDuplicateSecurities : bool

Update duplicate securities if they already exists.

Methods

Import(Stream, Action<int>, CancellationToken) : ValueTask<ValueTuple<int, DateTime?>>

Import from CSV file.

stream
The file stream.
updateProgress
Progress notification.
cancellationToken
CancellationToken

Returns: Count and last time.

Events

SecurityUpdated : Action<Security, bool>

Security updated event.