Package org.exoplatform.groovyscript

Examples of org.exoplatform.groovyscript.GroovyTemplate.render()


      long startTime = System.currentTimeMillis();

      GroovyTemplate template = getTemplate(name, context.getResourceResolver());
      context.put("_ctx", context);
      context.setGroovyTemplateService(this);
      template.render(context.getWriter(), context);

      long endTime = System.currentTimeMillis();

      TemplateStatistic templateStatistic = statisticService.getTemplateStatistic(name);
      templateStatistic.setTime(endTime - startTime);
View Full Code Here


   {
      if (context == null)
         throw new Exception("Binding cannot be null");
      context.put("_ctx", context);
      GroovyTemplate template = getTemplate(name, context.getResourceResolver());
      template.render(context.getWriter(), context);
   }

   final public GroovyTemplate getTemplate(String name, ResourceResolver resolver) throws Exception
   {
      return getTemplate(name, resolver, cacheTemplate_);
View Full Code Here

        long startTime = System.currentTimeMillis();

        GroovyTemplate template = getTemplate(name, context.getResourceResolver());
        context.put("_ctx", context);
        context.setGroovyTemplateService(this);
        template.render(context.getWriter(), context, (Locale) context.get("locale"));
        long endTime = System.currentTimeMillis();

        TemplateStatistic templateStatistic = statisticService.getTemplateStatistic(name);
        templateStatistic.setTime(endTime - startTime);
        templateStatistic.setResolver(context.getResourceResolver());
View Full Code Here

    public void include(String name, BindingContext context) throws Exception {
        if (context == null)
            throw new Exception("Binding cannot be null");
        context.put("_ctx", context);
        GroovyTemplate template = getTemplate(name, context.getResourceResolver());
        template.render(context.getWriter(), context, (Locale) context.get("locale"));
    }

    public final GroovyTemplate getTemplate(String name, ResourceResolver resolver) throws Exception {
        return getTemplate(name, resolver, cacheTemplate_);
    }
View Full Code Here

      long startTime = System.currentTimeMillis();

      GroovyTemplate template = getTemplate(name, context.getResourceResolver());
      context.put("_ctx", context);
      context.setGroovyTemplateService(this);
      template.render(context.getWriter(), context);

      long endTime = System.currentTimeMillis();

      TemplateStatistic templateStatistic = statisticService.getTemplateStatistic(name);
      templateStatistic.setTime(endTime - startTime);
View Full Code Here

   {
      if (context == null)
         throw new Exception("Binding cannot be null");
      context.put("_ctx", context);
      GroovyTemplate template = getTemplate(name, context.getResourceResolver());
      template.render(context.getWriter(), context);
   }

   final public GroovyTemplate getTemplate(String name, ResourceResolver resolver) throws Exception
   {
      return getTemplate(name, resolver, cacheTemplate_);
View Full Code Here

        long startTime = System.currentTimeMillis();

        GroovyTemplate template = getTemplate(name, context.getResourceResolver());
        context.put("_ctx", context);
        context.setGroovyTemplateService(this);
        template.render(context.getWriter(), context, (Locale) context.get("locale"));
        long endTime = System.currentTimeMillis();

        TemplateStatistic templateStatistic = statisticService.getTemplateStatistic(name);
        templateStatistic.setTime(endTime - startTime);
        templateStatistic.setResolver(context.getResourceResolver());
View Full Code Here

    public void include(String name, BindingContext context) throws Exception {
        if (context == null)
            throw new Exception("Binding cannot be null");
        context.put("_ctx", context);
        GroovyTemplate template = getTemplate(name, context.getResourceResolver());
        template.render(context.getWriter(), context, (Locale) context.get("locale"));
    }

    public final GroovyTemplate getTemplate(String name, ResourceResolver resolver) throws Exception {
        return getTemplate(name, resolver, cacheTemplate_);
    }
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.