コード例 #1
0
        public LoggerFactory(string strategyMode)
        {
            var configPath = Path.Combine(getConfigPath(), _logConfigFile);

            this._logConfig = JsonConvert.DeserializeObject <LogConfiguration>(readConfig(configPath));
            this._logPath   = getLogPath(strategyMode, this._logConfig);
        }
コード例 #2
0
        private string getLogPath(string strategyMode, LogConfiguration logConfig)
        {
            var logFile = strategyMode.ToUpper() == "LIVE" ? this._logConfig.LiveTradingLogFile : this._logConfig.BacktestLogFile;

            return(Path.Combine(this._logConfig.Path, logFile));
        }
コード例 #3
0
 public LoggerFactory(string strategyMode, LogConfiguration logConfig)
 {
     this._logConfig = logConfig;
     this._logPath   = getLogPath(strategyMode, logConfig);
 }