public class FileWebService extends WebService
HttpUtil.HEADER, HttpUtil.Helper, HttpUtil.METHOD, HttpUtil.STATUS
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
KEY_PATH
The dictionary key for the base storage path for files.
|
static Path |
PATH_FILES
The web files storage path.
|
KEY_DESCRIPTION, KEY_MATCH, matchers, METHODS_GET, METHODS_GET_POST, METHODS_POST, PATH
dict, KEY_CLASSNAME, KEY_ID, KEY_TYPE
Constructor and Description |
---|
FileWebService(java.lang.String id,
java.lang.String type,
Dict dict)
Creates a new file web service from a serialized representation.
|
Modifier and Type | Method and Description |
---|---|
protected void |
doGet(Request request)
Processes an HTTP GET request.
|
protected java.lang.String[] |
methodsImpl(Request request)
Returns the HTTP methods implemented for the specified
request.
|
Path |
path()
Returns the base storage path for file lookups.
|
protected void |
processFile(Request request,
Path path)
Processes a storage file retrieval request (if possible).
|
description, doDelete, doHead, doOptions, doPatch, doPost, doPut, doTrace, errorBadRequest, errorForbidden, errorInternal, errorMethodNotAllowed, errorNotFound, errorUnauthorized, findAllMatchers, headerAllow, methods, process, session
public static final Path PATH_FILES
public static final java.lang.String KEY_PATH
public FileWebService(java.lang.String id, java.lang.String type, Dict dict)
id
- the object identifiertype
- the object type namedict
- the serialized representationpublic Path path()
path
in class StorableObject
protected java.lang.String[] methodsImpl(Request request)
methodsImpl
in class WebService
request
- the request to checkWebService.methods(Request)
protected void doGet(Request request)
doGet
in class WebService
request
- the request to process