protected override void ApplySettings(HydraTaskSettings settings) { _settings = new IBSettings(settings); if (!settings.IsDefault) { return; } _settings.Address = InteractiveBrokersMessageAdapter.DefaultAddress; _settings.IsDownloadNews = true; _settings.ClientId = 0; _settings.ServerLogLevel = ServerLogLevels.System; _settings.SupportedLevel1Fields = Enumerator.GetValues <Level1Fields>(); }
protected override MarketDataConnector <IBTrader> CreateConnector(HydraTaskSettings settings) { _settings = new IBSettings(settings); if (settings.IsDefault) { _settings.Address = InteractiveBrokersMessageAdapter.DefaultAddress; _settings.IsDownloadNews = true; _settings.ClientId = 0; _settings.ServerLogLevel = ServerLogLevels.System; _settings.SupportedLevel1Fields = Enumerator.GetValues <Level1Fields>(); } return(new MarketDataConnector <IBTrader>(EntityRegistry.Securities, this, () => new IBTrader { Address = _settings.Address, ClientId = _settings.ClientId, ServerLogLevel = _settings.ServerLogLevel })); }