Class InteractiveBrokersMessageAdapter
- Namespace
- StockSharp.InteractiveBrokers
- Assembly
- StockSharp.InteractiveBrokers.dll
The messages adapter for InteractiveBrokers.
[OrderCondition(typeof(InteractiveBrokersOrderCondition))]
[MediaIcon("InteractiveBrokers_logo.svg")]
[Display(ResourceType = typeof(LocalizedStrings), Name = "InteractiveBrokers", Description = "StockConnector", GroupName = "America")]
[MessageAdapterCategory(MessageAdapterCategories.US|MessageAdapterCategories.Stock|MessageAdapterCategories.FX|MessageAdapterCategories.RealTime|MessageAdapterCategories.Free|MessageAdapterCategories.Ticks|MessageAdapterCategories.Candles|MessageAdapterCategories.Level1|MessageAdapterCategories.Transactions|MessageAdapterCategories.Futures|MessageAdapterCategories.Options)]
public class InteractiveBrokersMessageAdapter : MessageAdapter, IMessageAdapter, IMessageChannel, ICloneable<IMessageChannel>, ICloneable, IPersistable, ILogReceiver, ILogSource, IDisposable, INotifyPropertyChanged, IAddressAdapter<EndPoint>
- Inheritance
-
InteractiveBrokersMessageAdapter
- Implements
-
ICloneable<IMessageChannel>IPersistable
- Inherited Members
- Extension Methods
Constructors
InteractiveBrokersMessageAdapter(IdGenerator)
Initializes a new instance of the InteractiveBrokersMessageAdapter.
public InteractiveBrokersMessageAdapter(IdGenerator transactionIdGenerator)
Parameters
transactionIdGenerator
IdGeneratorTransaction id generator.
Fields
DefaultAddress
Address by default.
public static readonly EndPoint DefaultAddress
Field Value
DefaultGatewayAddress
Address by default.
public static readonly EndPoint DefaultGatewayAddress
Field Value
Properties
Address
Address.
[Display(ResourceType = typeof(LocalizedStrings), Name = "Address", Description = "AddressDot", GroupName = "Connection", Order = 0)]
public EndPoint Address { get; set; }
Property Value
AllTimeFrames
Possible time-frames.
public static IEnumerable<TimeSpan> AllTimeFrames { get; }
Property Value
CandlesBuildFrom
Possible options for candles building.
public override IEnumerable<Level1Fields> CandlesBuildFrom { get; }
Property Value
CheckCertificateRevocation
Check certificate revocation.
[Display(ResourceType = typeof(LocalizedStrings), Name = "CheckCertificateRevocation", Description = "CheckCertificateRevocationDesc", GroupName = "Ssl", Order = 204)]
public bool CheckCertificateRevocation { get; set; }
Property Value
ClientId
Unique ID. Used when several clients are connected to one terminal or gateway.
[Display(ResourceType = typeof(LocalizedStrings), Name = "Identifier", Description = "IBClientId", GroupName = "Connection", Order = 1)]
public int ClientId { get; set; }
Property Value
ConnectedTime
The connection time.
[Browsable(false)]
public DateTimeOffset? ConnectedTime { get; }
Property Value
ExtraAuth
Extra authentication.
[Browsable(false)]
public bool ExtraAuth { get; set; }
Property Value
ExtraSetup
The adapter requires extra setup.
public override bool ExtraSetup { get; }
Property Value
FeatureName
Feature name.
public override string FeatureName { get; }
Property Value
MarketDataType
[Display(ResourceType = typeof(LocalizedStrings), Name = "RealTime", Description = "IBRealTime", GroupName = "Connection", Order = 2)]
public InteractiveBrokersMarketDataTypes MarketDataType { get; set; }
Property Value
MaxVersion
Max support version.
[Display(ResourceType = typeof(LocalizedStrings), Name = "Version", Description = "MaxSupportVersion", GroupName = "Connection", Order = 10)]
public ServerVersions MaxVersion { get; set; }
Property Value
OptionalCapabilities
Optional capabilities.
[Browsable(false)]
public string OptionalCapabilities { get; set; }
Property Value
ServerLogLevel
The server messages logging level. The default is Information.
[Display(ResourceType = typeof(LocalizedStrings), Name = "LogLevel", Description = "ServerLogLevel", GroupName = "Connection", Order = 3)]
public ServerLogLevels ServerLogLevel { get; set; }
Property Value
SslCertificate
SSL certificate.
[Display(ResourceType = typeof(LocalizedStrings), Name = "Certificate", Description = "SslCertificate", GroupName = "Ssl", Order = 202)]
public string SslCertificate { get; set; }
Property Value
SslCertificatePassword
SSL certificate password.
[Display(ResourceType = typeof(LocalizedStrings), Name = "Password", Description = "SslCertificatePassword", GroupName = "Ssl", Order = 203)]
public SecureString SslCertificatePassword { get; set; }
Property Value
SslProtocol
SSL protocol to establish connect.
[Display(ResourceType = typeof(LocalizedStrings), Name = "Protocol", Description = "SslProtocol", GroupName = "Ssl", Order = 201)]
public SslProtocols SslProtocol { get; set; }
Property Value
SupportedOrderBookDepths
Available options for MaxDepth.
public override IEnumerable<int> SupportedOrderBookDepths { get; }
Property Value
TargetHost
The name of the server that shares SSL connection.
[Display(ResourceType = typeof(LocalizedStrings), Name = "TargetHost", Description = "TargetHostDesc", GroupName = "Ssl", Order = 206)]
public string TargetHost { get; set; }
Property Value
TimeFrames
Get possible time-frames for the specified instrument.
protected override IEnumerable<TimeSpan> TimeFrames { get; }
Property Value
UseV100Plus
Use V100 plus version at the connect time.
[Browsable(false)]
public bool UseV100Plus { get; set; }
Property Value
ValidateRemoteCertificates
Validate remove certificates.
[Display(ResourceType = typeof(LocalizedStrings), Name = "ValidateRemoteCertificates", Description = "ValidateRemoteCertificatesDesc", GroupName = "Ssl", Order = 205)]
public bool ValidateRemoteCertificates { 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
securityId
SecurityIddataType
DataTypeData type info.
iterationInterval
TimeSpanInterval between iterations.
Returns
- TimeSpan
Step.
IsSupportCandlesUpdates(MarketDataMessage)
Support candles subscription and live updates.
public override bool IsSupportCandlesUpdates(MarketDataMessage subscription)
Parameters
subscription
MarketDataMessage
Returns
- bool
Check result.
Load(SettingsStorage)
Load settings.
public override void Load(SettingsStorage storage)
Parameters
storage
SettingsStorageSettings storage.
OnSendInMessage(Message)
Send message.
protected override bool OnSendInMessage(Message message)
Parameters
message
MessageMessage.
Returns
Save(SettingsStorage)
Save settings.
public override void Save(SettingsStorage storage)
Parameters
storage
SettingsStorageSettings storage.
ToString()
public override string ToString()