Class CSVMessageAdapter
- Namespace
- StockSharp.CSV
- Assembly
- StockSharp.CSV.dll
The message adapter for StockSharp.CSV.
[MediaIcon("csv_logo.svg")]
[Doc("topics/api/connectors/common/csv.html")]
[Display(ResourceType = typeof(LocalizedStrings), Name = "CSV", Description = "MarketDataConnector", GroupName = "MarketData")]
[MessageAdapterCategory(MessageAdapterCategories.Stock|MessageAdapterCategories.History|MessageAdapterCategories.Free|MessageAdapterCategories.Ticks|MessageAdapterCategories.Candles|MessageAdapterCategories.MarketDepth|MessageAdapterCategories.Level1|MessageAdapterCategories.Futures|MessageAdapterCategories.Options)]
public class CSVMessageAdapter : MessageAdapter, IMessageAdapter, IMessageChannel, ICloneable<IMessageChannel>, ICloneable, IPersistable, ILogReceiver, ILogSource, IDisposable, INotifyPropertyChanged
- Inheritance
-
CSVMessageAdapter
- Implements
- Inherited Members
- Extension Methods
Constructors
CSVMessageAdapter(IdGenerator)
Initializes a new instance of the CSVMessageAdapter.
public CSVMessageAdapter(IdGenerator transactionIdGenerator)
Parameters
transactionIdGeneratorIdGeneratorTransaction id generator.
Properties
Settings
Settings of import.
[Display(ResourceType = typeof(LocalizedStrings), Name = "Settings", Description = "ImportSettings", GroupName = "Connection", Order = 0)]
[BasicSetting]
public IEnumerable<ImportSettings> Settings { get; set; }
Property Value
Methods
GetHistoryStepSize(SecurityId, DataType, out TimeSpan)
Get maximum size step allowed for historical download.
public override TimeSpan GetHistoryStepSize(SecurityId securityId, DataType dataType, out TimeSpan iterationInterval)
Parameters
securityIdSecurityIddataTypeDataTypeData type info.
iterationIntervalTimeSpanInterval between iterations.
Returns
- TimeSpan
Step.
GetSupportedMarketDataTypes(SecurityId, DateTimeOffset?, DateTimeOffset?)
Get supported by adapter message types.
public override IEnumerable<DataType> GetSupportedMarketDataTypes(SecurityId securityId, DateTimeOffset? from, DateTimeOffset? to)
Parameters
securityIdSecurityIdfromDateTimeOffset?Start date for request. If null, then all available messages will be returned.
toDateTimeOffset?End date for request. If null, then all available messages will be returned.
Returns
- IEnumerable<DataType>
Supported by adapter market data types.
IsAllDownloadingSupported(DataType)
Is for the specified dataType all securities downloading enabled.
public override bool IsAllDownloadingSupported(DataType dataType)
Parameters
dataTypeDataTypeData type info.
Returns
- bool
Check result.
Load(SettingsStorage)
Load settings.
public override void Load(SettingsStorage storage)
Parameters
storageSettingsStorageSettings storage.
OnSendInMessage(Message)
Send message.
protected override bool OnSendInMessage(Message message)
Parameters
messageMessageMessage.
Returns
Save(SettingsStorage)
Save settings.
public override void Save(SettingsStorage storage)
Parameters
storageSettingsStorageSettings storage.