Class AbstractTemplateProcessor

All Implemented Interfaces:
EventListener, org.springframework.beans.factory.Aware, org.springframework.context.ApplicationContextAware, org.springframework.context.ApplicationListener, Processor, TemplateProcessor
Direct Known Subclasses:
FTLTemplateProcessor

public abstract class AbstractTemplateProcessor extends BaseRegisterableTemplateProcessor implements org.springframework.context.ApplicationContextAware, TemplateProcessor
Abstract class for use in helping developers to build template processors that take advantage of the web script framework's inherent support for search paths.
Author:
muzquiano
  • Constructor Details

    • AbstractTemplateProcessor

      public AbstractTemplateProcessor()
  • Method Details

    • setApplicationContext

      public void setApplicationContext(org.springframework.context.ApplicationContext applicationContext)
      Sets the application context.
      Specified by:
      setApplicationContext in interface org.springframework.context.ApplicationContextAware
      Overrides:
      setApplicationContext in class BaseRegisterableTemplateProcessor
      Parameters:
      applicationContext - the new application context
    • setSearchPath

      public void setSearchPath(SearchPath searchPath)
      Parameters:
      searchPath - SearchPath
    • getTemplateLoader

      protected freemarker.cache.TemplateLoader getTemplateLoader()
      Gets the loader.
      Returns:
      the loader
    • getSearchPath

      protected SearchPath getSearchPath()
      Gets the search path.
      Returns:
      the search path
    • initLoaders

      protected void initLoaders()
      Initializes the template loaders
    • addProcessorModelExtensions

      protected void addProcessorModelExtensions(Object model)
      Add any configured processor model extensions to the model.
      Parameters:
      model - Object
    • onApplicationEvent

      public void onApplicationEvent(org.springframework.context.ApplicationEvent event)
      Specified by:
      onApplicationEvent in interface org.springframework.context.ApplicationListener
      Overrides:
      onApplicationEvent in class BaseRegisterableTemplateProcessor
    • init

      public void init()
      Description copied from class: BaseRegisterableTemplateProcessor
      Inits the processor
      Specified by:
      init in class BaseRegisterableTemplateProcessor
    • register

      public void register()
      Description copied from class: BaseRegisterableTemplateProcessor
      Registers this processor with the parent processor
      Specified by:
      register in class BaseRegisterableTemplateProcessor