public void autoConfig ( ) throws JoranException { StatusListenerConfigHelper . installIfAsked ( loggerContext ) ; new AndroidContextUtil ( ) . setupProperties ( loggerContext ) ; boolean verbose = true ; boolean configured = false ; JoranConfigurator configurator = new JoranConfigurator ( ) ; configurator . setContext ( loggerContext ) ; // search system property if ( ! configured ) { URL url = findConfigFileFromSystemProperties ( verbose ) ; if ( url != null ) { configurator . doConfigure ( url ) ; configured = true ; } } // search assets if ( ! configured ) { URL assetsConfigUrl = findConfigFileURLFromAssets ( verbose ) ; if ( assetsConfigUrl != null ) { configurator . doConfigure ( assetsConfigUrl ) ; configured = true ; } } }
Configures logback with the first configuration found in the following search path . If no configuration found nothing is done and logging is disabled .