Configure a LoggerWrapper to the values of a DOM node. It MUST have an attribute named "name", storing the LoggerWrapper's name. It may have subnodes named "configurator", keeping the properties for

@param configNode
426727
private static void configureLoggerWrapper (Node configNode) {
		Node lwNameNode = configNode.getAttributes ().getNamedItem ("name");
		String lwName;
		if (lwNameNode != null) {
			lwName = lwNameNode.getTextContent ();
		} else {
			lwName = "LoggerWrapper_" + String.valueOf ((new Date ()).getTime ());
		}

		LoggerWrapper loggerWrapper = LogHelper.getLoggerWrapper (lwName);

		NodeList lwSubnodes = configNode.getChildNodes ();
		for (int subnodeIndex = 0; subnodeIndex < lwSubnodes.getLength (); subnodeIndex++) {
			Node subnode = lwSubnodes.item (subnodeIndex);
			String subnodeName = subnode.getNodeName ().trim ().toLowerCase ();

			if (subnodeName.equals ("configurator")) {
				configureLoggerWrapperByConfigurator (loggerWrapper, subnode);
			}
		}
	}
1314074
@Override
	public void configure(final LoggerContext loggerContext) {
		addInfo("Setting up custom configuration.");
		final LoggerContext context = (LoggerContext) StaticLoggerBinder.getSingleton().getLoggerFactory();
		final JoranConfigurator jc = new JoranConfigurator();
		jc.setContext(context);
		context.reset();
		context.putProperty("application-name", appName);
		openStream(jc);
	}
675255
@Override
	public void configure(ConfigParams config) throws ConfigException {
		ConfigParams dependencies = config.getSection("dependencies");
		for (String name : dependencies.keySet()) {
			String locator = dependencies.get(name);
			if (locator == null)
				continue;

			try {
				Descriptor descriptor = Descriptor.fromString(locator);
				if (descriptor != null)
					_dependencies.put(name, descriptor);
				else
					_dependencies.put(name, locator);
			} catch (Exception ex) {
				_dependencies.put(name, locator);
			}
		}
	}
394847
public void setConfig(CompilerConfiguration config) {
        if (config == null) throw new NullPointerException("configuration cannot be null");
        this.config = config;
        this.groovyLoader = initGroovyLoader();
    }
1289813
public void setLogger(Logger logger) {

		System.out.println("LOGGER set");
//		if(logger instanceof SimpleFileLogger) {
			this.logger = logger;
			System.out.println("appender added");
			this.logger.addAppender(this);
//		}
	}
1309645
private void parseInputConfig(final Node node, final ConfigSettings config)
	{

		String name, value;
		Node nnode;
		NodeList list = node.getChildNodes();

		int length = list.getLength();
		for (int i = 0; i < length; i++) {
			nnode = list.item(i);

			name = nnode.getNodeName().toUpperCase();
			if (name.equals(KEY_WIKIPEDIA_ENCODING)) {

				value = nnode.getChildNodes().item(0).getNodeValue();
				config.setConfigParameter(ConfigurationKeys.WIKIPEDIA_ENCODING,
						value);

			}
			else if (name.equals(KEY_MODE_SURROGATES)) {

				SurrogateModes oValue = SurrogateModes.parse(nnode
						.getChildNodes().item(0).getNodeValue());
				config.setConfigParameter(ConfigurationKeys.MODE_SURROGATES,
						oValue);

			}
			else if (name.equals(SUBSECTION_ARCHIVE)) {

				parseInputArchive(nnode, config);

			}
		}
	}
171043
def configure_logging(conf):
    """"""
    logging.config.dictConfig({
        'version': 1,
        'disable_existing_loggers': False,
        'formatters': {
            'standard': {
                'format': '%(asctime)s [%(name)s] %(levelname)s '
                          '%(processName)s: %(message)s'
            }
        },
        'handlers': {
            'file': {
                'level': conf.LOG_FILE_LEVEL,
                'filename': conf.LOG_FILE,
                'class': 'logging.FileHandler',
                'formatter': 'standard',
            },
            'stdout': {
                'level': conf.LOG_STDOUT_LEVEL,
                'class': 'pyphi.log.TqdmHandler',
                'formatter': 'standard',
            }
        },
        'root': {
            'level': 'DEBUG',
            'handlers': (['file'] if conf.LOG_FILE_LEVEL else []) +
                        (['stdout'] if conf.LOG_STDOUT_LEVEL else [])
        }
    })
980238
static void validateConfigurations(Configuration conf) throws ValidationException {
        if (null == conf.getHandlers()) {
            Log.error(
                    "Handler should not be null, One or more handler implementation shuld be configured in the configuration",
                    ErrorGuide.getGuide(ErrorGuide.EMPTY_HANDLERS));
            throw new ValidationException("Configuration error", ValidationException.VALIDATION_LEVEL_INVALID);
        }
        if (null == conf.getLayout()) {
            Log.error("Layout should not be null, A layout implementation shuld be configured in the configuration",
                    ErrorGuide.getGuide(ErrorGuide.EMPTY_LAYOUT));
            throw new ValidationException("Configuration error", ValidationException.VALIDATION_LEVEL_INVALID);
        }

    }
648217
private void parseModeConfig(final Node node, final ConfigSettings config)
	{

		String name;
		Integer value;
		Node nnode;
		NodeList list = node.getChildNodes();

		int length = list.getLength();
		for (int i = 0; i < length; i++) {
			nnode = list.item(i);

			name = nnode.getNodeName().toUpperCase();
			if (name.equals(KEY_VALUE_MINIMUM_LONGEST_COMMON_SUBSTRING)) {

				value = Integer.parseInt(nnode.getChildNodes().item(0)
						.getNodeValue());
				config.setConfigParameter(
						ConfigurationKeys.VALUE_MINIMUM_LONGEST_COMMON_SUBSTRING,
						value);

			}
			else if (name.equals(KEY_COUNTER_FULL_REVISION)) {

				value = Integer.parseInt(nnode.getChildNodes().item(0)
						.getNodeValue());
				config.setConfigParameter(
						ConfigurationKeys.COUNTER_FULL_REVISION, value);

			}
		}
	}
1068146
private void configureLog4j(Properties props) throws ConfigurationException, FileNotFoundException {
        if (blitz4jConfig.shouldUseLockFree() && (props.getProperty(LOG4J_LOGGER_FACTORY) == null)) {
            props.setProperty(LOG4J_LOGGER_FACTORY, LOG4J_FACTORY_IMPL);
        }
        convertConfiguredAppendersToAsync(props);
        clearAsyncAppenderList();
        logger.info("Configuring log4j with properties :" + props);
        PropertyConfigurator.configure(props);
    }
80652
static void configureLog4j() {
    org.apache.log4j.LogManager.resetConfiguration();
    org.apache.log4j.Logger.getRootLogger().addAppender(new org.apache.log4j.Appender() {
      private String name;

      @Override
      public void setName(String name) {
        this.name = name;
      }

      @Override
      public void setLayout(org.apache.log4j.Layout layout) {
      }

      @Override
      public void setErrorHandler(org.apache.log4j.spi.ErrorHandler errorHandler) {
      }

      @Override
      public boolean requiresLayout() {
        return false;
      }

      @Override
      public String getName() {
        return name;
      }

      @Override
      public org.apache.log4j.Layout getLayout() {
        return null;
      }

      @Override
      public org.apache.log4j.spi.Filter getFilter() {
        return null;
      }

      @Override
      public org.apache.log4j.spi.ErrorHandler getErrorHandler() {
        return null;
      }

      @Override
      public void doAppend(org.apache.log4j.spi.LoggingEvent event) {
        Logger logger = Logging.getLogger(event.getLoggerName());
        logger.genericLog(event.getMessage() + "", event.getThrowableInformation() == null ? null : event.getThrowableInformation().getThrowable(), convertPriority(event.getLevel()));
      }

      private Priority convertPriority(org.apache.log4j.Level level) {
        switch (level.toInt()) {
          case org.apache.log4j.Level.ALL_INT:
            return Priority.ALL;
          case org.apache.log4j.Level.TRACE_INT:
            return Priority.VERBOSE;
          case org.apache.log4j.Level.DEBUG_INT:
            return Priority.DEBUG;
          case org.apache.log4j.Level.WARN_INT:
            return Priority.WARN;
          case org.apache.log4j.Level.INFO_INT:
            return Priority.INFO;
          case org.apache.log4j.Level.ERROR_INT:
            return Priority.ERROR;
          case org.apache.log4j.Level.FATAL_INT:
            return Priority.FATAL;
        }
        return Priority.OFF;
      }

      @Override
      public void close() {
      }

      @Override
      public void clearFilters() {
      }

      @Override
      public void addFilter(org.apache.log4j.spi.Filter newFilter) {
      }
    });
  }
247301
public static void configureLogging() {
		// Create the appender that will write log messages to the console.
		ConsoleAppender consoleAppender = new ConsoleAppender();
		// Define the pattern of log messages.
		// Insert the string "%c{1}:%L" to also show class name and line.
		String pattern = "%d{yyyy-MM-dd HH:mm:ss} %-5p - %m%n";
		consoleAppender.setLayout(new PatternLayout(pattern));
		// Change to Level.ERROR for fewer messages:
		consoleAppender.setThreshold(Level.INFO);

		consoleAppender.activateOptions();
		Logger.getRootLogger().addAppender(consoleAppender);
	}
1135326
public void configure(ConfigParams config) throws ConfigException {
		_dependencyResolver.configure(config);
        _logger.configure(config);	
	}
593319
final void put(final String name, final LoggerConfig value) {
		LoggerConfig config = categories.get(name);
		if (config != null) {
			config.merge(value);
		} else {
			categories.put(name, value);
		}
	}
707118
def set_logger(self, logger_name, level, handler=None):
        
        if 'loggers' not in self.config:
            self.config['loggers'] = {}
        real_level = self.real_level(level)
        self.config['loggers'][logger_name] = {'level': real_level}
        if handler:
            self.config['loggers'][logger_name]['handlers'] = [handler]
1348700
def configure(**kwargs):
        """"""
        for key in kwargs:
            if key == 'is_logging_enabled':
                Event.is_logging_enabled = kwargs[key]
            elif key == 'collector_queue':
                Event.collector_queue = kwargs[key]
            else:
                Logger.get_logger(__name__).error("Unknown key %s in configure or bad type %s",
                                                  key, type(kwargs[key]))
56503
function(name) {
			if (this.has(name)) {
				var value = this.get(name);
				if (name.startsWith(gui.ConfigPlugin.PREFIX)) {
					this.spirit.config.configureone(name, value);
				} else {
					this.$onatt(name, value);
				}
			}
		}