|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object javax.servlet.GenericServlet javax.servlet.http.HttpServlet org.zkoss.zuss.ZussServlet
public class ZussServlet
The ZUSS servlet used to load ZUSS file and convert it to CSS.
The initial parameter allowed (init-param):
/css/main.zuss?v=a_version_number
.
Constructor Summary | |
---|---|
ZussServlet()
|
Method Summary | |
---|---|
protected void |
doGet(javax.servlet.http.HttpServletRequest request,
javax.servlet.http.HttpServletResponse response)
|
protected java.io.InputStream |
getInputStream(java.lang.String path)
Returns the input stream of the given path. |
protected java.lang.String |
getPath(javax.servlet.http.HttpServletRequest request)
Retrieves the path of the ZUSS file from the request. |
protected Resolver |
getResolver(javax.servlet.http.HttpServletRequest request)
Returns a resolver used to provide the default variables and functions. |
void |
init()
|
protected boolean |
isIncluded(javax.servlet.http.HttpServletRequest request)
Returns if this request is caused by being included by another servlet. |
protected void |
setCacheControl(javax.servlet.http.HttpServletResponse response)
Sets the cache-control related headers. |
protected byte[] |
translate(javax.servlet.http.HttpServletRequest request,
java.lang.String path)
Translate ZUSS to CSS. |
Methods inherited from class javax.servlet.http.HttpServlet |
---|
doDelete, doHead, doOptions, doPost, doPut, doTrace, getLastModified, service, service |
Methods inherited from class javax.servlet.GenericServlet |
---|
destroy, getInitParameter, getInitParameterNames, getServletConfig, getServletContext, getServletInfo, getServletName, init, log, log |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public ZussServlet()
Method Detail |
---|
public void init() throws javax.servlet.ServletException
init
in class javax.servlet.GenericServlet
javax.servlet.ServletException
protected void doGet(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response) throws javax.servlet.ServletException, java.io.IOException
doGet
in class javax.servlet.http.HttpServlet
javax.servlet.ServletException
java.io.IOException
protected byte[] translate(javax.servlet.http.HttpServletRequest request, java.lang.String path) throws java.io.IOException
path
- the path of the ZUSS file, which is decided by getPath(javax.servlet.http.HttpServletRequest)
.
java.io.IOException
protected Resolver getResolver(javax.servlet.http.HttpServletRequest request)
Default: an instance of RequestResolver
.
protected java.io.InputStream getInputStream(java.lang.String path)
Default: invoke getServletContext().getResourceAsStream() to load the ZUSS file.
path
- the path of the ZUSS file, which is decided by getPath(javax.servlet.http.HttpServletRequest)
.protected java.lang.String getPath(javax.servlet.http.HttpServletRequest request)
Default: returns request.getPath()
protected boolean isIncluded(javax.servlet.http.HttpServletRequest request)
protected void setCacheControl(javax.servlet.http.HttpServletResponse response)
Default: it depends on client.cache.hours
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |