Table of Contents

Class MicexMessageAdapter

Namespace
StockSharp.Micex
Assembly
StockSharp.Micex.dll

Адаптер сообщений для Micex Bridge.

[OrderCondition(typeof(MicexOrderCondition))]
[MediaIcon("moex_logo.svg")]
[Display(ResourceType = typeof(LocalizedStrings), Name = "MicexTeap", Description = "StockConnector", GroupName = "Russia")]
[MessageAdapterCategory(MessageAdapterCategories.Russia|MessageAdapterCategories.Stock|MessageAdapterCategories.FX|MessageAdapterCategories.RealTime|MessageAdapterCategories.Paid|MessageAdapterCategories.Ticks|MessageAdapterCategories.MarketDepth|MessageAdapterCategories.Level1|MessageAdapterCategories.Transactions)]
public class MicexMessageAdapter : MessageAdapter, IMessageAdapter, IMessageChannel, ICloneable<IMessageChannel>, ICloneable, IPersistable, ILogReceiver, ILogSource, IDisposable, INotifyPropertyChanged, ILoginPasswordAdapter, IAddressAdapter<EndPoint>
Inheritance
MicexMessageAdapter
Implements
ICloneable<IMessageChannel>
IPersistable
Inherited Members
Extension Methods

Constructors

MicexMessageAdapter(IdGenerator)

Создать MicexMessageAdapter.

public MicexMessageAdapter(IdGenerator transactionIdGenerator)

Parameters

transactionIdGenerator IdGenerator

Генератор идентификаторов транзакций.

Fields

DefaultHeartbeatInterval

Значение по умолчанию для HeartbeatInterval.

public static readonly TimeSpan DefaultHeartbeatInterval

Field Value

TimeSpan

Properties

Addresses

Список адресов и портов серверов доступа.

[Display(ResourceType = typeof(LocalizedStrings), Name = "Addresses", Description = "Addresses", GroupName = "Connection", Order = 2)]
public IEnumerable<EndPoint> Addresses { get; set; }

Property Value

IEnumerable<EndPoint>

Boards

Список площадок, с которыми будет вестись работа.

[Browsable(false)]
public IEnumerable<string> Boards { get; set; }

Property Value

IEnumerable<string>

CancelOnDisconnectHeartbeatInterval

Интервал оповещения сервера об активности. Используется в режиме Cancel On Disconnect.

[Display(ResourceType = typeof(LocalizedStrings), Name = "CancelOnDisconnect", Description = "CancelOnDisconnectDesc", GroupName = "General", Order = 17)]
public TimeSpan CancelOnDisconnectHeartbeatInterval { get; set; }

Property Value

TimeSpan

ClientCode

Код клиента, присвоенный брокером.

[Display(ResourceType = typeof(LocalizedStrings), Name = "ClientCode", Description = "ClientCodeDesc", GroupName = "General", Order = 9)]
public string ClientCode { get; set; }

Property Value

string

CommentField

Поле, в которое нужно записывать пользовательский комментарий транзакции. По-умолчанию равно BrokerRef.

[Display(ResourceType = typeof(LocalizedStrings), Name = "Comment", Description = "MicexComment", GroupName = "General", Order = 12)]
public MicexCommentFields CommentField { get; set; }

Property Value

MicexCommentFields

CompressionLevel

Параметр компрессии данных. По-умолчанию равен BZip.

[Display(ResourceType = typeof(LocalizedStrings), Name = "Compression", Description = "MicexCompression", GroupName = "General", Order = 8)]
public CompressionLevels CompressionLevel { get; set; }

Property Value

CompressionLevels

ConnectionType

Тип подключения.

[Display(ResourceType = typeof(LocalizedStrings), Name = "ConnectionType", Description = "ConnectionTypeDot", GroupName = "Connection", Order = 1)]
public ConnectionTypes ConnectionType { get; set; }

Property Value

ConnectionTypes

DllPath

Путь к файлу mtesrl.dll.

[Display(ResourceType = typeof(LocalizedStrings), Name = "PathDll", Description = "PathDllDesc", GroupName = "General", Order = 3)]
public string DllPath { get; set; }

Property Value

string

ExtraSettings

Дополнительные настройки.

[Display(ResourceType = typeof(LocalizedStrings), Name = "Additional", Description = "AdditionalDot", GroupName = "General", Order = 16)]
public string ExtraSettings { get; set; }

Property Value

string

FeatureName

Feature name.

public override string FeatureName { get; }

Property Value

string

IgnoreCurrencies

Игнорируемые валюты.

[Browsable(false)]
public ICollection<string> IgnoreCurrencies { get; }

Property Value

ICollection<string>

Interface

Идентификатор интерфейса торговой системы ММВБ.

[Display(ResourceType = typeof(LocalizedStrings), Name = "Interface", Description = "InterfaceDesc", GroupName = "Connection", Order = 4)]
public MicexInterfaces Interface { get; set; }

Property Value

MicexInterfaces

Language

Язык для сообщений об ошибках. Допустимые значения: “English”, “Russian”, “Ukrainian”.

[Display(ResourceType = typeof(LocalizedStrings), Name = "Language", Description = "MicexLanguage", GroupName = "General", Order = 10)]
public string Language { get; set; }

Property Value

string

Login

Login.

[Display(ResourceType = typeof(LocalizedStrings), Name = "Login", Description = "LoginDot", GroupName = "Connection", Order = 5)]
public string Login { get; set; }

Property Value

string

MicexLogLevel

Строка в формате “N,M”, где первое число N – уровень логирования вызовов API MTESRL. Второе число M – уровень сбора статистики по соединению. Максимальный уровень логирования равен "5,2". Минимальный (выключен) "0,0". По-умолчанию значение равно null.

[Display(ResourceType = typeof(LocalizedStrings), Name = "Logging", Description = "MicexLogging", GroupName = "General", Order = 7)]
public string MicexLogLevel { get; set; }

Property Value

string

OrderBookDepth

Запрашиваемое количество лучших котировок на покупку/продажу по инструменту. Для получения всех котировок значение не указывается.

[Display(ResourceType = typeof(LocalizedStrings), Name = "DepthOfBook", Description = "DepthOfBookDot", GroupName = "General", Order = 13)]
public int? OrderBookDepth { get; set; }

Property Value

int?

OverrideDll

Перезаписать файл библиотеки из ресурсов. По-умолчанию файл будет перезаписан.

[Obsolete]
[Browsable(false)]
public bool OverrideDll { get; set; }

Property Value

bool

Password

Password.

[Display(ResourceType = typeof(LocalizedStrings), Name = "Password", Description = "PasswordDot", GroupName = "Connection", Order = 6)]
public SecureString Password { get; set; }

Property Value

SecureString

PreferredAddress

Адрес предпочитаемого сервера доступа.

[Display(ResourceType = typeof(LocalizedStrings), Name = "PreferredAddress", Description = "PreferredAddressDesc", GroupName = "Connection", Order = 11)]
public EndPoint PreferredAddress { get; set; }

Property Value

EndPoint

RequestAllDepths

Запрашиваемое стаканы по всем инструментам.

[Display(ResourceType = typeof(LocalizedStrings), Name = "AllDepths", Description = "RequestAllDepths", GroupName = "General", Order = 14)]
public bool RequestAllDepths { get; set; }

Property Value

bool

Server

Идентификатор сервера доступа, например, “EQ_TEST”.

[Display(ResourceType = typeof(LocalizedStrings), Name = "Server", Description = "Server", GroupName = "Connection", Order = 3)]
public string Server { get; set; }

Property Value

string

Service

Имя сервиса торговой системы.

[Display(ResourceType = typeof(LocalizedStrings), Name = "Service", Description = "MicexService", GroupName = "Connection", Order = 9)]
public string Service { get; set; }

Property Value

string

Methods

IsAllDownloadingSupported(DataType)

Is for the specified dataType all securities downloading enabled.

public override bool IsAllDownloadingSupported(DataType dataType)

Parameters

dataType DataType

Data type info.

Returns

bool

Check result.

Load(SettingsStorage)

Load settings.

public override void Load(SettingsStorage storage)

Parameters

storage SettingsStorage

Settings storage.

OnSendInMessage(Message)

Send message.

protected override bool OnSendInMessage(Message message)

Parameters

message Message

Message.

Returns

bool

true if the specified message was processed successfully, otherwise, false.

Save(SettingsStorage)

Save settings.

public override void Save(SettingsStorage storage)

Parameters

storage SettingsStorage

Settings storage.

ToString()

public override string ToString()

Returns

string