Table of Contents

Class FastMessageAdapter

Namespace
StockSharp.Fix
Assembly
StockSharp.FAST.dll

FAST message adapter.

[MediaIcon("Fix_logo.svg")]
[Display(ResourceType = typeof(LocalizedStrings), Name = "Fast", Description = "FixConnector")]
[MessageAdapterCategory(MessageAdapterCategories.Stock|MessageAdapterCategories.FX|MessageAdapterCategories.RealTime|MessageAdapterCategories.Paid|MessageAdapterCategories.Ticks|MessageAdapterCategories.Candles|MessageAdapterCategories.Level1|MessageAdapterCategories.OrderLog|MessageAdapterCategories.Transactions|MessageAdapterCategories.Futures|MessageAdapterCategories.Options)]
public class FastMessageAdapter : MessageAdapter, IMessageAdapter, IMessageChannel, ICloneable<IMessageChannel>, ICloneable, IPersistable, ILogReceiver, ILogSource, IDisposable, INotifyPropertyChanged
Inheritance
FastMessageAdapter
Implements
ICloneable<IMessageChannel>
IPersistable
Inherited Members
Extension Methods

Constructors

FastMessageAdapter(IdGenerator)

Initializes a new instance of the FastMessageAdapter.

public FastMessageAdapter(IdGenerator transactionIdGenerator)

Parameters

transactionIdGenerator IdGenerator

Transaction id generator.

Properties

AssociatedBoards

The adapter can process subscription only with instruments associated with the specified board.

public override string[] AssociatedBoards { get; }

Property Value

string[]

CandlesBuildFrom

Possible options for candles building.

public override IEnumerable<Level1Fields> CandlesBuildFrom { get; }

Property Value

IEnumerable<Level1Fields>

Categories

Message adapter categories.

public override MessageAdapterCategories Categories { get; }

Property Value

MessageAdapterCategories

CheckTimeFrameByRequest

Check possible time-frame by request.

public override bool CheckTimeFrameByRequest { get; }

Property Value

bool

Dialect

The FAST dialect. The default is SpectraFastDialect.

[Display(ResourceType = typeof(LocalizedStrings), Name = "Dialect", Description = "FixDialectProtocol", GroupName = "Session", Order = 0)]
public Type Dialect { get; set; }

Property Value

Type

DialectSettings

FAST settings.

[Display(ResourceType = typeof(LocalizedStrings), Name = "Settings", Description = "DialectSettings", GroupName = "Session", Order = 1)]
[TypeConverter(typeof(ExpandableObjectConverter))]
public IFastDialect DialectSettings { get; }

Property Value

IFastDialect

EnqueueSubscriptions

Enqueue subscriptions.

public override bool EnqueueSubscriptions { get; set; }

Property Value

bool

Remarks

Do not send new request before received confirmation for previous.

FeatureName

Feature name.

public override string FeatureName { get; }

Property Value

string

GenerateOrderBookFromLevel1

public override bool GenerateOrderBookFromLevel1 { get; set; }

Property Value

bool

Icon

Icon.

public override Uri Icon { get; }

Property Value

Uri

IsAutoReplyOnTransactonalUnsubscription

Send auto response for OrderStatusMessage and PortfolioLookupMessage unsubscribes.

public override bool IsAutoReplyOnTransactonalUnsubscription { get; }

Property Value

bool

IsFullCandlesOnly

Translates CandleMessage as only fully filled.

public override bool IsFullCandlesOnly { get; }

Property Value

bool

IsNativeIdentifiers

Identify security in messages by native identifier Native.

public override bool IsNativeIdentifiers { get; }

Property Value

bool

IsNativeIdentifiersPersistable

Native identifier can be stored.

public override bool IsNativeIdentifiersPersistable { get; }

Property Value

bool

IsPositionsEmulationRequired

Adapter required emulation PositionChangeMessage.

public override bool? IsPositionsEmulationRequired { get; }

Property Value

bool?

Remarks

null means no emulatior, true by order balance, false by trades.

IsReplaceCommandEditCurrent

Is the OrderReplaceMessage command edit a current order.

public override bool IsReplaceCommandEditCurrent { get; }

Property Value

bool

IsSecurityNewsOnly

Adapter provides news related with specified security.

public override bool IsSecurityNewsOnly { get; }

Property Value

bool

IsSupportExecutionsPnL

Adapter fills PnL.

public override bool IsSupportExecutionsPnL { get; }

Property Value

bool

IsSupportOrderBookIncrements

Adapter translates incremental order books.

public override bool IsSupportOrderBookIncrements { get; }

Property Value

bool

IsSupportPartialDownloading

Support partial downloading.

public override bool IsSupportPartialDownloading { get; }

Property Value

bool

IsSupportSubscriptions

Support any subscriptions (ticks, order books etc.).

public override bool IsSupportSubscriptions { get; }

Property Value

bool

IsSupportTransactionLog

Adapter translates orders changes on reply of OrderStatusMessage.

public override bool IsSupportTransactionLog { get; }

Property Value

bool

IterationInterval

Interval between iterations.

public override TimeSpan IterationInterval { get; }

Property Value

TimeSpan

LookupTimeout

Lookup timeout.

public override TimeSpan? LookupTimeout { get; }

Property Value

TimeSpan?

OrderConditionType

Type of OrderCondition.

public override Type OrderConditionType { get; }

Property Value

Type

Remarks

If the connection does not support the order type Conditional, it will be returned null.

PossibleSupportedMessages

Possible supported by adapter message types.

public override IEnumerable<MessageTypeInfo> PossibleSupportedMessages { get; }

Property Value

IEnumerable<MessageTypeInfo>

SecurityExtendedFields

Names of extended security fields in SecurityMessage.

public override IEnumerable<Tuple<string, Type>> SecurityExtendedFields { get; }

Property Value

IEnumerable<Tuple<string, Type>>

SettingsFile

Settings file.

[Display(ResourceType = typeof(LocalizedStrings), Name = "SettingsFile", Description = "SettingsFile", GroupName = "Session", Order = 2)]
public string SettingsFile { get; set; }

Property Value

string

StorageName

The storage name, associated with the adapter.

public override string StorageName { get; }

Property Value

string

SupportedInMessages

Supported by adapter message types.

public override IEnumerable<MessageTypes> SupportedInMessages { get; set; }

Property Value

IEnumerable<MessageTypes>

SupportedMarketDataTypes

Supported by adapter market data types.

public override IEnumerable<DataType> SupportedMarketDataTypes { get; }

Property Value

IEnumerable<DataType>

SupportedOrderBookDepths

Available options for MaxDepth.

public override IEnumerable<int> SupportedOrderBookDepths { get; }

Property Value

IEnumerable<int>

SupportedResultMessages

Supported by adapter result message types.

public override IEnumerable<MessageTypes> SupportedResultMessages { get; }

Property Value

IEnumerable<MessageTypes>

UseChannels

Use channels for in and out messages.

public override bool UseChannels { get; }

Property Value

bool

Methods

CreateOrderLogMarketDepthBuilder(SecurityId)

Create market depth builder.

public override IOrderLogMarketDepthBuilder CreateOrderLogMarketDepthBuilder(SecurityId securityId)

Parameters

securityId SecurityId

Security ID.

Returns

IOrderLogMarketDepthBuilder

Order log to market depth builder.

GetCandleArgs(Type, SecurityId, DateTimeOffset?, DateTimeOffset?)

Get possible args for the specified candle type and instrument.

public override IEnumerable<object> GetCandleArgs(Type candleType, SecurityId securityId, DateTimeOffset? from, DateTimeOffset? to)

Parameters

candleType Type

The type of the message CandleMessage.

securityId SecurityId

Security ID.

from DateTimeOffset?

The initial date from which you need to get data.

to DateTimeOffset?

The final date by which you need to get data.

Returns

IEnumerable<object>

Possible args.

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

securityId SecurityId

SecurityId

dataType DataType

Data type info.

iterationInterval TimeSpan

Interval between iterations.

Returns

TimeSpan

Step.

GetMaxCount(DataType)

Get maximum possible items count per single subscription request.

public override int? GetMaxCount(DataType dataType)

Parameters

dataType DataType

Data type info.

Returns

int?

Max items count.

GetSupportedDataTypes(SecurityId)

Get supported data types for the specified SecurityId.

public override IEnumerable<DataType> GetSupportedDataTypes(SecurityId securityId)

Parameters

securityId SecurityId

SecurityId

Returns

IEnumerable<DataType>

Supported data types.

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.

IsSecurityRequired(DataType)

Support filtering subscriptions (subscribe/unsubscribe for specified security).

public override bool IsSecurityRequired(DataType dataType)

Parameters

dataType DataType

Data type info.

Returns

bool

Check result.

IsSupportCandlesPriceLevels(MarketDataMessage)

Support candles PriceLevels.

public override bool IsSupportCandlesPriceLevels(MarketDataMessage subscription)

Parameters

subscription MarketDataMessage

MarketDataMessage

Returns

bool

Check result.

IsSupportCandlesUpdates(MarketDataMessage)

Support candles subscription and live updates.

public override bool IsSupportCandlesUpdates(MarketDataMessage subscription)

Parameters

subscription MarketDataMessage

MarketDataMessage

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