示例#1
0
        public LoggerSetter NewBootstrapDependentLoggerSetter(LogBootstrapper logBootstrapper)
        {
            IList <LoggerRecipient>            loggerRecipients = new List <LoggerRecipient>();
            BootstrapDependentLoggerSetterImpl loggerSetter     = new BootstrapDependentLoggerSetterImpl();

            loggerSetter.LogBootstrapper  = logBootstrapper;
            loggerSetter.LoggerRecipients = loggerRecipients;
            return(loggerSetter);
        }
示例#2
0
        public void TestNewBootstrapDependentLoggerSetter()
        {
            LoggerSetter loggerSetter = Log4netFactory.NewBootstrapDependentLoggerSetter(LogBootstrapper);

            Assert.IsNotNull(loggerSetter);
            Assert.IsTrue(loggerSetter is BootstrapDependentLoggerSetterImpl);
            BootstrapDependentLoggerSetterImpl loggerSetterImpl = (BootstrapDependentLoggerSetterImpl)loggerSetter;

            Assert.AreEqual(LogBootstrapper, loggerSetterImpl.LogBootstrapper);
            Assert.IsNotNull(loggerSetterImpl.LoggerRecipients);
            Assert.IsTrue(loggerSetterImpl.LoggerRecipients.Count == 0);
        }