public final class MultipartUtil extends Object
Modifier and Type | Method and Description |
---|---|
static MultipartHttpServletRequest |
convert(int nSizeThreshold,
long nRequestSizeMax,
boolean bActivateNormalizeFileName,
javax.servlet.http.HttpServletRequest request)
Convert a HTTP request to a
MultipartHttpServletRequest |
static boolean |
isMultipart(javax.servlet.http.HttpServletRequest request)
Check if the given HTTP request has multipart content
|
public static boolean isMultipart(javax.servlet.http.HttpServletRequest request)
request
- the HTTP requestpublic static MultipartHttpServletRequest convert(int nSizeThreshold, long nRequestSizeMax, boolean bActivateNormalizeFileName, javax.servlet.http.HttpServletRequest request) throws org.apache.commons.fileupload.FileUploadException
MultipartHttpServletRequest
nSizeThreshold
- the size thresholdnRequestSizeMax
- the request size maxbActivateNormalizeFileName
- true if the file name must be normalized,
false otherwiserequest
- the HTTP requestMultipartHttpServletRequest
, null if the request does not
have a multipart contentorg.apache.commons.fileupload.FileUploadBase.SizeLimitExceededException
- exception if the file size is too bigorg.apache.commons.fileupload.FileUploadException
- exception if an unknown error has occurredCopyright © 2020 City of Paris. All rights reserved.