|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectnl.pbemengine.engine.ng.base.webserver.ContextPathHandler
public class ContextPathHandler
Handler class for a specific context path of the web server, handles all actions and page requests for this context path.
| Field Summary | |
|---|---|
static java.lang.String |
ACTION_SUFFIX
The file extension that signifies we are invoking an action rather than requesting a file |
| Constructor Summary | |
|---|---|
ContextPathHandler(java.lang.String name,
freemarker.cache.TemplateLoader loader,
ResourceFetcher fetcher)
Create a new ContextPathHandler with the indicate template loader |
|
| Method Summary | |
|---|---|
freemarker.cache.TemplateLoader |
getLoader()
Return the templateloader for this ContextPathHandler, used to instantiate result mappings that use templates |
Content |
processRequest(java.lang.String requestedObject,
PageContext context)
Process a web request for this context path |
boolean |
registerAction(java.lang.String name,
java.lang.Class action)
Register an action class for use when a specific action name is invoked |
boolean |
registerResult(java.lang.String actionName,
java.lang.String resultName,
ResultAction response)
Register a Result object to be associated with a specific result from a specific action |
void |
setIndexAction(java.lang.Class indexAction)
|
void |
setServer(WebServer server)
|
void |
setServerCallback(WebserverCallback serverCallback)
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final java.lang.String ACTION_SUFFIX
| Constructor Detail |
|---|
public ContextPathHandler(java.lang.String name,
freemarker.cache.TemplateLoader loader,
ResourceFetcher fetcher)
name - The name of the context path handler, used for error messagesloader - The TemplateLoader object, which is used to load template objectsfetcher - The ResourceFetcher object, which is used to load non-template objects| Method Detail |
|---|
public void setServerCallback(WebserverCallback serverCallback)
public void setServer(WebServer server)
public boolean registerAction(java.lang.String name,
java.lang.Class action)
name - The name of the action request that triggers this action
class. For instance, if your name equals "foo", then
"foo.action" will trigger this classaction - The action class triggered by the name
true if succesful, false otherwise
public boolean registerResult(java.lang.String actionName,
java.lang.String resultName,
ResultAction response)
actionName - The action to tie this result toresultName - The result name to trigger the response objectresponse - The response to tie to this action/result combination
true if succesful, false otherwise
public Content processRequest(java.lang.String requestedObject,
PageContext context)
requestedObject - The object requestedcontext - The context in which it was requested
public freemarker.cache.TemplateLoader getLoader()
public void setIndexAction(java.lang.Class indexAction)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||