Ejemplo n.º 1
0
        public static void MinimalSetup()
        {
            Properties props = new Properties();

            props.SetProperty("log.output", "stderr");
            RedwoodConfiguration.Apply(props);
        }
Ejemplo n.º 2
0
 /// <summary>
 /// Configures the Redwood logger using a reasonable set of defaults,
 /// which can be overruled by the supplied Properties file.
 /// </summary>
 /// <param name="props">The properties file to overrule or augment the default configuration</param>
 public static void Apply(Properties props)
 {
     //--Tweak Properties
     //(output to stderr)
     if (props.GetProperty("log.output") == null)
     {
         props.SetProperty("log.output", "stderr");
     }
     //(capture system streams)
     if (props.GetProperty("log.captureStderr") == null)
     {
         props.SetProperty("log.captureStderr", "true");
     }
     //(apply properties)
     RedwoodConfiguration.Apply(props);
     //--Strange Tweaks
     //(adapt legacy logging systems)
     JavaUtilLoggingAdaptor.Adapt();
 }