|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface TemplateExecutor
An interface to template executors executing and evaluating templates in different markup languages applying configured template engines.
| Field Summary | |
|---|---|
static String |
PROPERTY_ENCODING
A template encoding for properties used as templates. |
static String |
PROPERTY_EXTENSION
An extension for properties used as templates. |
| Method Summary | |
|---|---|
CharSequence |
evaluate(CharSequence raw,
String template,
ServletRequest request,
ServletResponse response,
FilterChain chain)
Evaluates the named run-time content. |
CharSequence |
evaluate(String template,
ServletRequest request,
ServletResponse response,
FilterChain chain)
Evaluates the named template. |
CharSequence |
evaluate(String template,
String encoding,
ServletRequest request,
ServletResponse response,
FilterChain chain)
Evaluates the named template with the specified encoding. |
void |
execute(CharSequence raw,
String template,
ServletRequest request,
ServletResponse response,
FilterChain chain)
Executes the named run-time content. |
void |
execute(String template,
ServletRequest request,
ServletResponse response,
FilterChain chain)
Executes the named template. |
void |
execute(String template,
String encoding,
ServletRequest request,
ServletResponse response,
FilterChain chain)
Executes the named template with the specified encoding. |
String |
getErrorTemplate()
Gets the error template. |
TemplateEngine |
getTemplateEngine(String template)
Gets the referent of the template engine MBean to be applied to the specified template. |
boolean |
isLocalContext()
Gets local context flag. |
boolean |
isLocalizedTemplates()
Gets the localized templates flag. |
CharSequence |
resolve(String template,
ServletRequest request,
ServletResponse response,
FilterChain chain)
Resolves the named template content. |
CharSequence |
resolve(String template,
String encoding,
ServletRequest request,
ServletResponse response,
FilterChain chain)
Resolves the named template content with the specified encoding. |
String |
resolveTemplatePath(String template,
ServletRequest request,
ServletResponse response,
FilterChain chain)
Resolves a template path for the specified request and response. |
void |
setErrorTemplate(String template)
Sets the error template. |
void |
setLocalContext(boolean flag)
Sets the local context flag. |
void |
setLocalizedTemplates(boolean flag)
Sets the localized templates flag. |
boolean |
templateExists(String template,
ServletRequest request,
ServletResponse response,
FilterChain chain)
Checks whether the template exists. |
| Field Detail |
|---|
static final String PROPERTY_EXTENSION
static final String PROPERTY_ENCODING
| Method Detail |
|---|
boolean isLocalContext()
void setLocalContext(boolean flag)
flag - true for a local context, false othrwise.boolean isLocalizedTemplates()
void setLocalizedTemplates(boolean flag)
flag - the localized templates flag.String getErrorTemplate()
void setErrorTemplate(String template)
template - the name of the error template.TemplateEngine getTemplateEngine(String template)
template - the template.
IllegalStateException - if not available.
void execute(String template,
ServletRequest request,
ServletResponse response,
FilterChain chain)
throws TemplateException
template - the template.request - the request.response - the response.chain - the filter chain.
TemplateException - if processing fails.
void execute(String template,
String encoding,
ServletRequest request,
ServletResponse response,
FilterChain chain)
throws TemplateException
template - the template.encoding - the encoding.request - the request.response - the response.chain - the filter chain.
TemplateException - if processing fails.
void execute(CharSequence raw,
String template,
ServletRequest request,
ServletResponse response,
FilterChain chain)
throws TemplateException
raw - the content.template - a virtual template for identifying the content.request - the request.response - the response.chain - the filter chain.
TemplateException - if processing fails.
CharSequence evaluate(String template,
ServletRequest request,
ServletResponse response,
FilterChain chain)
throws TemplateException
template - the template.request - the request.response - the response.chain - the filter chain.
TemplateException - if processing fails.
CharSequence evaluate(String template,
String encoding,
ServletRequest request,
ServletResponse response,
FilterChain chain)
throws TemplateException
template - the template.encoding - the encoding.request - the request.response - the response.chain - the filter chain.
TemplateException - if processing fails.
CharSequence evaluate(CharSequence raw,
String template,
ServletRequest request,
ServletResponse response,
FilterChain chain)
throws TemplateException
raw - the content.template - a virtual template for identifying the content.request - the request.response - the response.chain - the filter chain.
TemplateException - if processing fails.
CharSequence resolve(String template,
ServletRequest request,
ServletResponse response,
FilterChain chain)
throws TemplateException
template - the template.request - the request.response - the response.chain - the filter chain.
TemplateException - if processing fails.
CharSequence resolve(String template,
String encoding,
ServletRequest request,
ServletResponse response,
FilterChain chain)
throws TemplateException
template - the template.encoding - the encoding.request - the request.response - the response.chain - the filter chain.
TemplateException - if processing fails.
boolean templateExists(String template,
ServletRequest request,
ServletResponse response,
FilterChain chain)
template - the template.request - the request.response - the response.chain - the filter chain.
String resolveTemplatePath(String template,
ServletRequest request,
ServletResponse response,
FilterChain chain)
template - the name of the template.request - the template request.response - the template response.chain - the filter chain.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||