Exemple #1
0
        public void AppendLog(string i_msg, LOG_LEVEL i_level, bool i_logTime = false)
        {
            LOG_INFO logInfo = new LOG_INFO();

            logInfo.Id = GetNextLogInfoId();
            logInfo.SetMessage(i_msg);
            logInfo.Level      = i_level;
            logInfo.HasLogTime = i_logTime;
            if (i_logTime)
            {
                logInfo.LogTime = DateTime.Now;
            }

            AppendLog(logInfo);
        }
Exemple #2
0
        public void AppendInfo(string i_infoMessage, LOG_OPTIONS i_logOptions = LOG_OPTIONS.AddFooterAndHeader)
        {
            LOG_INFO logInfo = new LOG_INFO();

            if (i_logOptions.HasFlag(LOG_OPTIONS.AddLogTitle))
            {
                logInfo.SetMessage("INFO: " + i_infoMessage);
            }
            else
            {
                logInfo.SetMessage(i_infoMessage);
            }
            logInfo.Id         = GetNextLogInfoId();
            logInfo.Level      = LOG_LEVEL.Info;
            logInfo.LogOptions = i_logOptions;
            if (i_logOptions.HasFlag(LOG_OPTIONS.AddTime))
            {
                logInfo.HasLogTime = true;
                logInfo.LogTime    = DateTime.Now;
            }
            _logInfo.Add(logInfo);
            Display();
        }
Exemple #3
0
 public void AppendLog(LOG_INFO i_logInfo)
 {
     i_logInfo.Id = GetNextLogInfoId();
     _logInfo.Add(i_logInfo);
     Display();
 }