Table of Contents

Class CandleCsvSerializer<TCandleMessage>

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

The candle serializer in the CSV format.

public class CandleCsvSerializer<TCandleMessage> : CsvMarketDataSerializer<TCandleMessage>, IMarketDataSerializer<TCandleMessage>, IMarketDataSerializer where TCandleMessage : CandleMessage, new()

Type Parameters

TCandleMessage

CandleMessage derived type.

Inheritance
CsvMarketDataSerializer<TCandleMessage>
CandleCsvSerializer<TCandleMessage>
Implements
IMarketDataSerializer<TCandleMessage>
Inherited Members
Extension Methods

Constructors

CandleCsvSerializer(SecurityId, DataType, Encoding)

Initializes a new instance of the CandleCsvSerializer<TCandleMessage>.

public CandleCsvSerializer(SecurityId securityId, DataType dataType, Encoding encoding = null)

Parameters

securityId SecurityId

Security ID.

dataType DataType

DataType.

encoding Encoding

Encoding.

Methods

CreateMetaInfo(DateTime)

To create empty meta-information.

public override IMarketDataMetaInfo CreateMetaInfo(DateTime date)

Parameters

date DateTime

Date.

Returns

IMarketDataMetaInfo

Meta-information on data for one day.

Read(FastCsvReader, IMarketDataMetaInfo)

Read data from the specified reader.

protected override TCandleMessage Read(FastCsvReader reader, IMarketDataMetaInfo metaInfo)

Parameters

reader FastCsvReader

CSV reader.

metaInfo IMarketDataMetaInfo

Meta-information on data for one day.

Returns

TCandleMessage

Data.

Serialize(Stream, IEnumerable<TCandleMessage>, IMarketDataMetaInfo)

Save data into stream.

public override void Serialize(Stream stream, IEnumerable<TCandleMessage> data, IMarketDataMetaInfo metaInfo)

Parameters

stream Stream

Data stream.

data IEnumerable<TCandleMessage>

Data.

metaInfo IMarketDataMetaInfo

Meta-information on data for one day.

Write(CsvFileWriter, TCandleMessage, IMarketDataMetaInfo)

Write data to the specified writer.

protected override void Write(CsvFileWriter writer, TCandleMessage data, IMarketDataMetaInfo metaInfo)

Parameters

writer CsvFileWriter

CSV writer.

data TCandleMessage

Data.

metaInfo IMarketDataMetaInfo

Meta-information on data for one day.