|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectorg.liquidsite.app.servlet.RequestProcessor
A request processor.
| Constructor Summary | |
RequestProcessor(ContentManager manager,
java.io.File baseDir)
Creates a new request processor. |
|
| Method Summary | |
abstract void |
destroy()
Destroys this request processor. |
protected ContentManager |
getContentManager()
Returns the content manager used by this processor. |
protected java.io.File |
getFile(java.lang.String path)
Returns an application file. |
abstract void |
process(Request request)
Processes a request. |
protected void |
processLiquidSite(Request request,
java.lang.String path)
Processes a request for the special "/liquidsite" path at the root of each site. |
protected void |
processNormal(Request request,
ContentSite site,
java.lang.String path,
boolean preview)
Processes a request for a normal resource in a content site. |
protected void |
sendContent(Request request,
Content content)
Processes a request to a content object. |
protected void |
sendError(Request request,
int code)
Processes an error response. |
protected void |
sendTemplate(Request request,
java.lang.String templateName)
Processes a request to a template file. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public RequestProcessor(ContentManager manager,
java.io.File baseDir)
manager - the content manager to usebaseDir - the base directory for application files| Method Detail |
protected ContentManager getContentManager()
protected java.io.File getFile(java.lang.String path)
path - the relative file path
public abstract void process(Request request)
throws RequestException
request - the request to process
RequestException - if the request couldn't be processedpublic abstract void destroy()
protected void processNormal(Request request,
ContentSite site,
java.lang.String path,
boolean preview)
throws RequestException
request - the request objectsite - the content site objectpath - the request path (inside the site)preview - the preview flag
RequestException - if the request couldn't be processed
protected void processLiquidSite(Request request,
java.lang.String path)
throws RequestException
request - the request objectpath - the request path (inside the directory)
RequestException - if the request couldn't be processed
protected void sendContent(Request request,
Content content)
throws ContentException,
ContentSecurityException,
TemplateException,
RequestException
request - the request objectcontent - the content object requested
ContentException - if the database couldn't be accessed
properly
ContentSecurityException - if the requested content
object wasn't readable by the user
TemplateException - if the page template couldn't be
processed correctly
RequestException - if the content wasn't found
protected void sendTemplate(Request request,
java.lang.String templateName)
throws TemplateException
request - the request objecttemplateName - the template file name
TemplateException - if the file template couldn't be
processed correctly
protected void sendError(Request request,
int code)
throws TemplateException
request - the request objectcode - the response HTTP error code
TemplateException - if the file template couldn't be
processed correctly
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||