/** * Autoconfiguration using the configuration file potentially found * in the <code>org.apache.velocity.tools</code> system property. * @param includeDefaults whether to include default tools */ public void autoConfigure(boolean includeDefaults) { // look for any specified via system property FactoryConfiguration sys = ConfigurationUtils.findFromSystemProperty(); if (sys != null) { configure(sys); } }
/** * Returns a new, standard {@link ToolboxFactory} configured * with the results of {@link #findFromSystemProperty()}. * @return new {@link ToolboxFactory} */ public static ToolboxFactory createFactory() { // include any config specified via system property FactoryConfiguration sys = findFromSystemProperty(); ToolboxFactory factory = new ToolboxFactory(); if (sys != null) { factory.configure(sys); } return factory; }