|
Carrot2 v3.5.2
API Documentation |
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.carrot2.util.xsltfilter.XSLTFilter
public final class XSLTFilter
A servlet filter applying XSLT stylesheets to the result of a request. The filter is
activated when the content has a MIME type equal to text/xml AND:
ext-stylesheet directive (custom extension) OR,xml-stylesheet directive,XSLTFilterConstants.NO_XSLT_PROCESSING in the request context.web.xml).
Example configuration using ext-stylesheet:
<?ext-stylesheet resource="WEB-INF/stylesheets/stylesheet.xsl" ?>
Example configuration using xml-stylesheet (note the URL here is servlet-container
relative, not application-context relative):
<?xml-stylesheet type="text/xsl" href="/stylesheets/stylesheet.xsl" ?>
| Constructor Summary | |
|---|---|
XSLTFilter()
|
|
| Method Summary | |
|---|---|
void |
destroy()
Take this filter out of service. |
void |
doFilter(javax.servlet.ServletRequest request,
javax.servlet.ServletResponse response,
javax.servlet.FilterChain chain)
Apply the XSLT stylesheet to the response and pass the result to the next filter. |
void |
init(javax.servlet.FilterConfig filterConfig)
Place this filter into service. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public XSLTFilter()
| Method Detail |
|---|
public void init(javax.servlet.FilterConfig filterConfig)
throws javax.servlet.ServletException
init in interface javax.servlet.FilterfilterConfig - The filter configuration object
javax.servlet.ServletExceptionpublic void destroy()
destroy in interface javax.servlet.Filter
public void doFilter(javax.servlet.ServletRequest request,
javax.servlet.ServletResponse response,
javax.servlet.FilterChain chain)
throws IOException,
javax.servlet.ServletException
doFilter in interface javax.servlet.FilterIOException
javax.servlet.ServletException
|
Please refer to project documentation at
http://project.carrot2.org |
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||