Class TemplateServiceImpl

  • All Implemented Interfaces:
    TemplateService

    public class TemplateServiceImpl
    extends java.lang.Object
    implements TemplateService
    Implementation of the TemplateService using Spring configured script engines.
    Author:
    Kevin Roast
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.util.Map<java.lang.String,​java.lang.Object> buildDefaultModel​(org.alfresco.service.cmr.repository.NodeRef person, org.alfresco.service.cmr.repository.NodeRef companyHome, org.alfresco.service.cmr.repository.NodeRef userHome, org.alfresco.service.cmr.repository.NodeRef template, TemplateImageResolver imageResolver)
      Helper method to build a default model
      TemplateProcessor getTemplateProcessor​(java.lang.String engine)
      Return a TemplateProcessor instance for the specified engine name.
      java.lang.String processTemplate​(java.lang.String template, java.lang.Object model)
      Process a template against the upplied data model and return the result as a string.
      void processTemplate​(java.lang.String template, java.lang.Object model, java.io.Writer out)
      Process a template against the supplied data model and write to the out.
      java.lang.String processTemplate​(java.lang.String engine, java.lang.String template, java.lang.Object model)
      Process a template against the supplied data model and write to the out.
      void processTemplate​(java.lang.String engine, java.lang.String template, java.lang.Object model, java.io.Writer out)
      Process a template against the supplied data model and write to the out.
      java.lang.String processTemplate​(java.lang.String engine, java.lang.String template, java.lang.Object model, java.util.Locale locale)
      Process a template using the supplied locale against the supplied data model and write to the out.
      java.lang.String processTemplateString​(java.lang.String engine, java.lang.String template, java.lang.Object model)
      Process a given template, provided as a string, against the supplied data model and return the result as a String
      void processTemplateString​(java.lang.String engine, java.lang.String template, java.lang.Object model, java.io.Writer out)
      Process a given template, provided as a string, against the supplied data model and report the result back in the provided writer.
      void registerTemplateProcessor​(TemplateProcessor templateProcessor)
      Registers a new template processor with the template service
      void setDefaultTemplateEngine​(java.lang.String defaultTemplateEngine)  
      void setNodeService​(org.alfresco.service.cmr.repository.NodeService nodeService)
      Set the node service
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait