Пример #1
0
        public void TestLog()
        {
            ILogFactory factory = new Log4NetLogFactory();
            ILog        log     = factory.GetLog("unitTest");

            log.ErrorFormat("发生了错误:{0}", "我就开个玩笑");
        }
Пример #2
0
        private Logger()
        {
            Log4NetLogFactory facto = new Log4NetLogFactory();

            // Get the default logger
            logger = facto.GetLog("HL7Fuse");
        }
Пример #3
0
        public void TestLogSuccessConfig()
        {
            ILogFactory factory = new Log4NetLogFactory("log4netTest.config");
            ILog        log     = factory.GetLog("unitTest");

            log.ErrorFormat("发生了错误:{0}", "我就开个玩笑");
        }
Пример #4
0
        private Logger()
        {
            Log4NetLogFactory LogFactory = new Log4NetLogFactory();

            Infolog  = LogFactory.GetLog("Info");
            Debuglog = LogFactory.GetLog("Debug");
            Errorlog = LogFactory.GetLog("Error");
            Fatallog = LogFactory.GetLog("Fatal");
            Warnlog  = LogFactory.GetLog("Warn");
            Chatlog  = LogFactory.GetLog("Chat");
            Maillog  = LogFactory.GetLog("Mail");
        }