Class CmsTemplateLoader
java.lang.Object
ch.tocco.nice2.optional.cms.impl.publish.output.freemarker.loader.CmsTemplateLoader
- All Implemented Interfaces:
- CachingTemplateLoader,- freemarker.cache.TemplateLoader
This template loader uses 
CmsTemplateService to find
 the requested template.
 Once loaded a template, it will be cached within this loader. If the template has changed, the cache of
 this loader has to be invalidated by calling invalidate(String) or invalidateAll().- 
Constructor SummaryConstructorsConstructorDescriptionCmsTemplateLoader(CmsTemplateService cmsTemplateService, SecurityManager securityManager, org.slf4j.Logger log) 
- 
Method SummaryModifier and TypeMethodDescriptionvoidcloseTemplateSource(Object templateSource) findTemplateSource(String name) longgetLastModified(Object templateSource) voidinvalidate(String templateName) Invalidate the template with a specific name.voidInvalidate all templates in the cache.
- 
Constructor Details- 
CmsTemplateLoaderpublic CmsTemplateLoader(CmsTemplateService cmsTemplateService, SecurityManager securityManager, org.slf4j.Logger log) 
 
- 
- 
Method Details- 
invalidateAllpublic void invalidateAll()Description copied from interface:CachingTemplateLoaderInvalidate all templates in the cache.- Specified by:
- invalidateAllin interface- CachingTemplateLoader
 
- 
invalidateDescription copied from interface:CachingTemplateLoaderInvalidate the template with a specific name.- Specified by:
- invalidatein interface- CachingTemplateLoader
- Parameters:
- templateName- The name of the template to invalidate.
 
- 
findTemplateSource- Specified by:
- findTemplateSourcein interface- freemarker.cache.TemplateLoader
- Throws:
- IOException
 
- 
getLastModified- Specified by:
- getLastModifiedin interface- freemarker.cache.TemplateLoader
 
- 
getReader- Specified by:
- getReaderin interface- freemarker.cache.TemplateLoader
- Throws:
- IOException
 
- 
closeTemplateSource- Specified by:
- closeTemplateSourcein interface- freemarker.cache.TemplateLoader
- Throws:
- IOException
 
 
-