Show / Hide Table of Contents

Class CsvImporter

Импортер сообщений из текстового файла с CSV форматом в хранилище.

Inheritance
Object
BaseLogSource
BaseLogReceiver
CsvParser
CsvImporter
Implements
Ecng.Serialization.IPersistable
ILogReceiver
ILogSource
IDisposable
Inherited Members
CsvParser.Parse(String, Func<Boolean>)
CsvParser.DataType
CsvParser.Fields
CsvParser.ExtendedInfoStorageItem
CsvParser.IgnoreNonIdSecurities
CsvParser.ColumnSeparator
CsvParser.SkipFromHeader
CsvParser.TimeZone
BaseLogReceiver.ILogReceiver.AddLog(LogMessage)
BaseLogSource.RaiseLog(LogMessage)
BaseLogSource.ToString()
BaseLogSource.Load(SettingsStorage)
BaseLogSource.Save(SettingsStorage)
BaseLogSource.Id
BaseLogSource.Name
BaseLogSource.Parent
BaseLogSource.LogLevel
BaseLogSource.CurrentTime
BaseLogSource.IsRoot
BaseLogSource.ParentRemoved
BaseLogSource.Log
Namespace: StockSharp.Algo.Import
Assembly: StockSharp.Algo.dll
Syntax
public class CsvImporter : CsvParser, IPersistable, ILogReceiver, ILogSource, IDisposable

Constructors

CsvImporter(DataType, IEnumerable<FieldMapping>, ISecurityStorage, IExchangeInfoProvider, IMarketDataDrive, StorageFormats)

Создать CsvImporter.

Declaration
public CsvImporter(DataType dataType, IEnumerable<FieldMapping> fields, ISecurityStorage securityStorage, IExchangeInfoProvider exchangeInfoProvider, IMarketDataDrive drive, StorageFormats storageFormat)
Parameters
Type Name Description
DataType dataType

Тип данных.

IEnumerable<FieldMapping> fields

Импортируемые поля.

ISecurityStorage securityStorage

Хранилище информации об инструментах.

IExchangeInfoProvider exchangeInfoProvider

Провайдер бирж и торговых площадок.

IMarketDataDrive drive

Хранилище. Если значение равно null, то будет использоваться DefaultDrive.

StorageFormats storageFormat

Тип формата. По умолчанию передается Binary.

Properties

UpdateDuplicateSecurities

Update duplicate securities if they already exists.

Declaration
public bool UpdateDuplicateSecurities { get; set; }
Property Value
Type Description
Boolean

Methods

Import(String, Action<Int32>, Func<Boolean>)

Импортировать из CSV файла.

Declaration
public (int, Nullable<DateTimeOffset>) Import(string fileName, Action<int> updateProgress, Func<bool> isCancelled)
Parameters
Type Name Description
String fileName

File name.

Action<Int32> updateProgress

Оповещение о прогрессе.

Func<Boolean> isCancelled

Обработчик, возвращающий признак прерывания процесса.

Returns
Type Description
(, )<Int32, Nullable<DateTimeOffset>>

Count and last time.

Events

SecurityUpdated

Событие обновления инструмента.

Declaration
public event Action<Security, bool> SecurityUpdated
Event Type
Type Description
Action<Security, Boolean>

Implements

Ecng.Serialization.IPersistable
ILogReceiver
ILogSource
System.IDisposable

Extension Methods

Paths.Serialize<T>(T, String)
Paths.Serialize<T>(T)
EditorExtensions.ToItemsSource(Object, Type, Nullable<Boolean>, Nullable<ListSortDirection>, Func<IItemsSourceItem, Boolean>, Func<Object, String>, Func<Object, String>)
XamlHelper.WpfCast<T>(Object)
XamlHelper.CopyToClipboard<T>(T)
XamlHelper.EnsureUIThread(Object)
☀
☾
In This Article
Back to top
Copyright © StockSharp.
☀
☾