public class DelegatedFilter extends Filter
Filter
that wraps an underlying DelegatedHandler
.
Supported entry points are:
handleBefore(conversation)
handleAfter(conversation)
The handleBefore entry point should return a string which an action. It can
be either "continue", "skip", or "stop" for the usual filter actions.
However, if the string begins with a "/", it will be treated as a redirection
using CapturingRedirector
.
Constructor and Description |
---|
DelegatedFilter(Context context,
Restlet next,
String documentName)
Constructor.
|
DelegatedFilter(Context context,
String documentName)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
protected void |
afterHandle(Request request,
Response response) |
protected int |
beforeHandle(Request request,
Response response) |
int |
getDefaultBeforeAction() |
String |
getEntryPointNameForAfter() |
String |
getEntryPointNameForBefore() |
void |
setDefaultAction(int defaultBeforeAction) |
void |
setEntryPointNameForAfter(String entryPointNameForAfter) |
void |
setEntryPointNameForBefore(String entryPointNameForBefore) |
String |
toString() |
doHandle, getNext, handle, hasNext, setNext, setNext, start, stop
createFinder, finalize, getApplication, getAuthor, getContext, getDescription, getFinderClass, getLogger, getName, getOwner, handle, handle, handle, isStarted, isStopped, setAuthor, setContext, setDescription, setFinderClass, setName, setOwner
public DelegatedFilter(Context context, String documentName)
context
- The contextdocumentName
- The document namepublic String getEntryPointNameForBefore()
setEntryPointNameForBefore(String)
public void setEntryPointNameForBefore(String entryPointNameForBefore)
entryPointNameForBefore
- The entry point name for handleBeforegetEntryPointNameForBefore()
public String getEntryPointNameForAfter()
setEntryPointNameForAfter(String)
public void setEntryPointNameForAfter(String entryPointNameForAfter)
entryPointNameForAfter
- The entry point name for handleAftergetEntryPointNameForAfter()
public int getDefaultBeforeAction()
handleBefore()
if none
is specifiedsetDefaultAction(int)
public void setDefaultAction(int defaultBeforeAction)
defaultBeforeAction
- The default action to use for handleBefore()
if none
is specifiedgetDefaultBeforeAction()
protected int beforeHandle(Request request, Response response)
beforeHandle
in class Filter
protected void afterHandle(Request request, Response response)
afterHandle
in class Filter
Copyright © 2009-2016 Three Crickets LLC.