Interface IConnectorSettings
- Namespace
- OFT.Core
- Assembly
- ATAS.DataFeedsCore.dll
The settings of one connection: what the connections list and the "Add connection" dialog show, the values the user edits and that are saved with the connection, and the factory of its connector. Derive from BaseConnectorSettings<T, TSelf> instead of implementing this interface directly.
public interface IConnectorSettings
- Extension Methods
Properties
AccountKind
Kind of the accounts of this connection, for telemetry (PLAT-4891). The connection-level default: a connector that tells its accounts apart (IB paper accounts, NinjaTrader Sim, CQG demo brokerages) overrides it per account through AccountKind.
Not in ATAS 8.0.15 yet: available from the next version.
AccountKind AccountKind { get; }
Property Value
ConnectionMode
Connection mode for telemetry when the connector offers a choice, e.g. connecting without market data. Null when the connector has a single mode.
Not in ATAS 8.0.15 yet: available from the next version.
string? ConnectionMode { get; }
Property Value
- string
ConnectorServer
Selected server/endpoint name for telemetry. Null when the connector has no server selection.
Added in ATAS 8.0.15.
string? ConnectorServer { get; }
Property Value
- string
Description
Description of the connector shown in the "Add connection" dialog and the settings window: the System.ComponentModel.DescriptionAttribute of the settings class, or an empty string without it.
string Description { get; }
Property Value
- string
DisplayName
User-facing connection name: Name when set, otherwise a connector-specific fallback (e.g. the login).
Not in ATAS 8.0.15 yet: available from the next version.
string DisplayName { get; set; }
Property Value
- string
Features
What the connection supports. A third-party connector returns MarketData: trading through third-party connectors is not supported.
ConnectorFeatures Features { get; }
Property Value
Id
Unique identifier of the connection. BaseConnectorSettings generates a new one in its constructor.
Guid Id { get; set; }
Property Value
- Guid
IsAutoConnectEnabled
Whether the platform connects this connection automatically when it starts.
bool IsAutoConnectEnabled { get; set; }
Property Value
- bool
IsDemo
Indicates that connector uses TestNet environment.
bool IsDemo { get; }
Property Value
- bool
IsFavorite
Whether the connection is a favorite: favorite connections are shown on the tab strip of the main window. The platform marks a connection the user adds as a favorite.
Not in ATAS 8.0.15 yet: available from the next version.
bool IsFavorite { get; set; }
Property Value
- bool
IsMarketDataEnabled
Whether the connector raises market data (trades, best bid/ask, order book): ApplySettings(IDataFeedConnector) copies it to MarketDataStreamEnabled.
bool IsMarketDataEnabled { get; set; }
Property Value
- bool
Logo
Resource URI of the connector logo, from the LogoAttribute of the settings class; null without it.
Uri Logo { get; }
Property Value
- Uri
MarketDataDelayPeriod
Delay of the market data of this connection; ApplySettings(IDataFeedConnector) copies it to MarketDataDelayPeriod. BaseConnectorSettings returns Realtime.
MarketDataDelayPeriods MarketDataDelayPeriod { get; }
Property Value
Name
Name the user gave the connection; null or empty until the user names it. Show DisplayName instead.
string Name { get; set; }
Property Value
- string
SettingsTypes
How the connection settings are edited. BaseConnectorSettings returns Properties.
ConnectorSettingsTypes SettingsTypes { get; }
Property Value
Type
Name of the connector type: the System.ComponentModel.DisplayNameAttribute of the settings class, or the class name without it. It identifies the connector, and the data folder of the connector is named after it.
string Type { get; }
Property Value
- string
Methods
ApplySettings(IDataFeedConnector)
Copies the settings to the connector. The platform calls it after the connector is created and after every change of the settings; changed settings whose application throws are not saved.
void ApplySettings(IDataFeedConnector connector)
Parameters
connectorIDataFeedConnectorThe connector of this connection.
CheckSupported(out string?)
Checks if connector is supported on this machine
bool CheckSupported(out string? errorMessage)
Parameters
errorMessagestringNull if supported otherwise contains error text
Returns
- bool
true if no problems detected, false if not supported
CreateConnector(string)
Creates the connector of this connection, sets its DataPath and applies the settings to it (ApplySettings(IDataFeedConnector)).
IDataFeedConnector CreateConnector(string dataPath)
Parameters
dataPathstringThe data folder of the connector, named after Type; the platform creates it if needed.
Returns
- IDataFeedConnector
The new connector.
HasSameCredentials(IConnectorSettings)
Checks if this connector has the same credentials as another connector. Also verifies that the connector types match.
Added in ATAS 8.0.15.
bool HasSameCredentials(IConnectorSettings other)
Parameters
otherIConnectorSettings
Returns
- bool