45 lines
2.0 KiB
C#
45 lines
2.0 KiB
C#
// ********************************************************************************
|
|
// 文件名字: LoggerService
|
|
// 文件描述: LoggerService
|
|
// 开发人员: Michael
|
|
// 创建时间: 2019/11/8 0:08
|
|
//
|
|
// 更新历史:
|
|
// + 创建 LoggerService.cs 文件. by Michael @2019/11/8 0:08
|
|
// ********************************************************************************
|
|
using log4net;
|
|
using System;
|
|
|
|
|
|
[assembly: log4net.Config.XmlConfigurator(Watch = true)]
|
|
namespace Glorysoft.SECS.EQP.Utilities
|
|
{
|
|
public class LoggerService
|
|
{
|
|
public static ILog SECSLogger { get; private set; }
|
|
public static ILog SYSLogger { get; private set; }
|
|
public static ILog MQLogger { get; private set; }
|
|
|
|
public const string Receive = "Receive";
|
|
public const string Send = "Send";
|
|
|
|
static LoggerService()
|
|
{
|
|
//var sPath = string.Concat(AppDomain.CurrentDomain.BaseDirectory, @"\logs");
|
|
//LogManager.ConfigureLogger(nameof(SYSLogger), sPath, eLogFilter.DEBUG, eLogFilter.DEBUG | eLogFilter.INFO | eLogFilter.ERROR | eLogFilter.WARN, eFileFomart.Date, null);
|
|
//LogManager.ConfigureLogger(nameof(SECSLogger), sPath, eLogFilter.DEBUG, eLogFilter.DEBUG | eLogFilter.INFO | eLogFilter.ERROR | eLogFilter.WARN, eFileFomart.Date, null);
|
|
//LogManager.ConfigureLogger(nameof(MQLogger), sPath, eLogFilter.DEBUG, eLogFilter.DEBUG | eLogFilter.INFO | eLogFilter.ERROR | eLogFilter.WARN, eFileFomart.Date, null);
|
|
//SYSLogger = LogManager.GetConfigureLogger(nameof(SYSLogger));
|
|
//SECSLogger = LogManager.GetConfigureLogger(nameof(SECSLogger));
|
|
//MQLogger = LogManager.GetConfigureLogger(nameof(MQLogger));
|
|
SECSLogger = LogManager.GetLogger(nameof(SECSLogger));
|
|
SYSLogger = LogManager.GetLogger(nameof(SYSLogger));
|
|
MQLogger = LogManager.GetLogger(nameof(MQLogger));
|
|
}
|
|
|
|
public static void GuiLogWrite()
|
|
{
|
|
|
|
}
|
|
}
|
|
} |