Esempio n. 1
0
    /// <summary>
    /// Initialise the logger and constants
    /// </summary>
    /// <param name="args">The command line arguments</param>
    public void InitializeApp(string[] args)
    {
        TraceListeners.Log(TraceEventType.Information, 0,
                           "ClassifierMain::InitializeApp...", false, true);

        _modellingProfile = args[0];

        // Loggers
        if (args.Length == 2 &&
            args[1].ToLower() == "verbose")
        {
            _verbose = true;
            TraceListeners.Initialise(
                _verbose,
                Constants.GENERAL_LOG_PATH,
                Constants.DIAGNOSTIC_LOG_PATH);
        }
        else
        {
            TraceListeners.Initialise(_verbose,
                                      Constants.GENERAL_LOG_PATH,
                                      Constants.DIAGNOSTIC_LOG_PATH);
        }

        // Constants
        Constants.Initialise();
        ConstantsProfiles.Initialise();
        ConstantsModellings.Initialise();
    }