Fork me on GitHub

ServletLoader

In package com.mitchellbosecke.pebble.loader

public class ServletLoader extends Object implements Loader

Loader that uses a servlet context to find templates.

Constructors

public ServletLoader(ServletContext context)
Parameters:
  • ServletContext context

Methods

public Reader getReader(String templateName)
Parameters:
  • String templateName
public String getSuffix()
Parameters:
  • No parameters
public void setSuffix(String suffix)
Parameters:
  • String suffix
public String getPrefix()
Parameters:
  • No parameters
public void setPrefix(String prefix)
Parameters:
  • String prefix
public String getCharset()
Parameters:
  • No parameters
public void setCharset(String charset)
Parameters:
  • String charset
public String resolveRelativePath(String relativePath, String anchorPath)
Parameters:
  • String relativePath
  • String anchorPath
public String createCacheKey(String templateName)
Parameters:
  • String templateName