public class StatusFilter extends Filter
| Constructor and Description |
|---|
StatusFilter(Context context,
boolean overwriting)
Constructor.
|
StatusFilter(Context context,
StatusService statusService)
Constructor from a status service.
|
| Modifier and Type | Method and Description |
|---|---|
void |
afterHandle(Request request,
Response response)
Allows filtering after its handling by the target Restlet.
|
protected int |
doHandle(Request request,
Response response)
Handles the call by distributing it to the next Restlet.
|
StatusService |
getStatusService()
Returns the helped status service.
|
boolean |
isOverwriting()
Indicates if existing representations should be overwritten.
|
void |
setOverwriting(boolean overwriting)
Indicates if existing representations should be overwritten.
|
void |
setStatusService(StatusService statusService)
Sets the helped status service.
|
beforeHandle, getNext, handle, hasNext, setNext, setNext, start, stopcreateFinder, finalize, getApplication, getAuthor, getContext, getDescription, getFinderClass, getLogger, getName, getOwner, handle, handle, handle, isStarted, isStopped, setAuthor, setContext, setDescription, setFinderClass, setName, setOwnerpublic StatusFilter(Context context, boolean overwriting)
context - The context.overwriting - Indicates whether an existing representation should be
overwritten.public StatusFilter(Context context, StatusService statusService)
context - The context.statusService - The helped status service.public void afterHandle(Request request, Response response)
Status.SUCCESS_OK by default.
If this is an error status, try to get a representation of it with
StatusService.toRepresentation(Status, Request, Response)
.afterHandle in class Filterrequest - The request to handle.response - The response to update.protected int doHandle(Request request, Response response)
StatusService.toStatus(Throwable, Request, Response)
method is invoked.public StatusService getStatusService()
public boolean isOverwriting()
public void setOverwriting(boolean overwriting)
overwriting - True if existing representations should be overwritten.public void setStatusService(StatusService statusService)
statusService - The helped status service.Copyright © 2005–2025. All rights reserved.