Package org.apache.velocity.runtime.log

Examples of org.apache.velocity.runtime.log.CommonsLogLogChute


    this.config = config;
    this.engine = new VelocityEngine();
    // we have to keep this in sync with our logging system
    // http://velocity.apache.org/engine/releases/velocity-1.5/developer-guide.html#simpleexampleofacustomlogger
    engine.setProperty(RuntimeConstants.RUNTIME_LOG_LOGSYSTEM,
        new CommonsLogLogChute());
    if(config.getTemplateFolder() == null){
      engine.setProperty(RuntimeConstants.RESOURCE_LOADER, "classpath");
      engine.setProperty("classpath." + RuntimeConstants.RESOURCE_LOADER + ".class", ClasspathResourceLoader.class.getName());
      config.setTemplateFolder("templates");
    }else{
View Full Code Here


    this.config = config;
    this.engine = new VelocityEngine();
    // we have to keep this in sync with our logging system
    // http://velocity.apache.org/engine/releases/velocity-1.5/developer-guide.html#simpleexampleofacustomlogger
    engine.setProperty(RuntimeConstants.RUNTIME_LOG_LOGSYSTEM,
        new CommonsLogLogChute());
    if(config.getTemplateFolder() == null){
      engine.setProperty(RuntimeConstants.RESOURCE_LOADER, "classpath");
      engine.setProperty("classpath." + RuntimeConstants.RESOURCE_LOADER + ".class", ClasspathResourceLoader.class.getName());
      config.setTemplateFolder("templates");
    }else{
View Full Code Here

    this.config = config;
    this.engine = new VelocityEngine();
    // we have to keep this in sync with our logging system
    // http://velocity.apache.org/engine/releases/velocity-1.5/developer-guide.html#simpleexampleofacustomlogger
    engine.setProperty(RuntimeConstants.RUNTIME_LOG_LOGSYSTEM,
        new CommonsLogLogChute());
    if(config.getTemplateFolder() == null){
      engine.setProperty(RuntimeConstants.RESOURCE_LOADER, "classpath");
      engine.setProperty("classpath." + VelocityEngine.RESOURCE_LOADER + ".class", ClasspathResourceLoader.class.getName());
      config.setTemplateFolder("templates");
    }else{
View Full Code Here

      initVelocityResourceLoader(velocityEngine, this.resourceLoaderPath);
    }

    // Log via Commons Logging?
    if (this.overrideLogging) {
      velocityEngine.setProperty(RuntimeConstants.RUNTIME_LOG_LOGSYSTEM, new CommonsLogLogChute());
    }

    // Apply properties to VelocityEngine.
    for (Map.Entry<String, Object> entry : props.entrySet()) {
      velocityEngine.setProperty(entry.getKey(), entry.getValue());
View Full Code Here

TOP

Related Classes of org.apache.velocity.runtime.log.CommonsLogLogChute

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.