예제 #1
0
        protected override void ApplySettings(HydraTaskSettings settings)
        {
            _settings = new OandaSettings(settings);

            if (settings.IsDefault)
            {
                _settings.Server = OandaServers.Real;
                _settings.Token  = new SecureString();
            }
        }
예제 #2
0
        protected override MarketDataConnector <OandaTrader> CreateConnector(HydraTaskSettings settings)
        {
            _settings = new OandaSettings(settings);

            if (settings.IsDefault)
            {
                _settings.Server = OandaServers.Real;
                _settings.Token  = new SecureString();
            }

            return(new MarketDataConnector <OandaTrader>(EntityRegistry.Securities, this, () => new OandaTrader
            {
                Server = _settings.Server,
                Token = _settings.Token,
            }));
        }