public abstract class AbstractTusExtension extends Object implements TusExtension
| Constructor and Description |
|---|
AbstractTusExtension() |
| Modifier and Type | Method and Description |
|---|---|
void |
handleError(HttpMethod method,
TusServletRequest request,
TusServletResponse response,
UploadStorageService uploadStorageService,
String ownerKey)
If a request is invalid, or when processing the request fails, it might be necessary to react to this failure.
|
protected abstract void |
initRequestHandlers(List<RequestHandler> requestHandlers) |
protected abstract void |
initValidators(List<RequestValidator> requestValidators) |
void |
process(HttpMethod method,
TusServletRequest servletRequest,
TusServletResponse servletResponse,
UploadStorageService uploadStorageService,
String ownerKey)
Process the given request
|
void |
validate(HttpMethod method,
javax.servlet.http.HttpServletRequest servletRequest,
UploadStorageService uploadStorageService,
String ownerKey)
Validate the given request
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetMinimalSupportedHttpMethods, getNameprotected abstract void initValidators(List<RequestValidator> requestValidators)
protected abstract void initRequestHandlers(List<RequestHandler> requestHandlers)
public void validate(HttpMethod method, javax.servlet.http.HttpServletRequest servletRequest, UploadStorageService uploadStorageService, String ownerKey) throws TusException, IOException
TusExtensionvalidate in interface TusExtensionmethod - The HTTP method of this request (taking into account overrides)servletRequest - The HTTP requestuploadStorageService - The current upload storage serviceownerKey - Identifier of the owner of this uploadTusException - When the request is invalidIOException - When unable to read upload informationpublic void process(HttpMethod method, TusServletRequest servletRequest, TusServletResponse servletResponse, UploadStorageService uploadStorageService, String ownerKey) throws IOException, TusException
TusExtensionprocess in interface TusExtensionmethod - The HTTP method of this request (taking into account overrides)servletRequest - The HTTP requestservletResponse - The HTTP responseuploadStorageService - The current upload storage serviceownerKey - Identifier of the owner of this uploadIOException - When unable to read upload informationTusException - When processing the request failspublic void handleError(HttpMethod method, TusServletRequest request, TusServletResponse response, UploadStorageService uploadStorageService, String ownerKey) throws IOException, TusException
TusExtensionhandleError in interface TusExtensionmethod - The HTTP method of this request (taking into account overrides)request - The HTTP requestresponse - The HTTP responseuploadStorageService - The current upload storage serviceownerKey - Identifier of the owner of this uploadIOException - When unable to read upload informationTusException - When handling the error failsCopyright © 2023. All rights reserved.