Class UnsafeUploadRequestException
- java.lang.Object
 - 
- java.lang.Throwable
 - 
- java.lang.Exception
 - 
- java.lang.RuntimeException
 - 
- javax.ws.rs.WebApplicationException
 - 
- de.xima.fc.api.rest.impl.common.reader.UnsafeUploadRequestException
 
 
 
 
 
 
- 
- All Implemented Interfaces:
 IErrorDetails,Serializable
public class UnsafeUploadRequestException extends javax.ws.rs.WebApplicationException implements IErrorDetails
This exception is thrown when malware or content type checks fail.- Since:
 - 8.4.0
 - Author:
 - XIMA MEDIA GmbH, Dresden
 - See Also:
 - Serialized Form
 
 
- 
- 
Constructor Summary
Constructors Constructor Description UnsafeUploadRequestException(String message, List<? extends IScannedFileItem> unsafeFiles)Creates an exception with the passed message that notifies about the passed 'unsafe' files. 
- 
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description StringgetErrorCode()StringgetErrorMessage(Locale locale)intgetHttpStatusCode()protected Stringkey()List<? extends IScannedFileItem>unsafeFiles()- 
Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString 
 - 
 
 - 
 
- 
- 
Constructor Detail
- 
UnsafeUploadRequestException
public UnsafeUploadRequestException(String message, List<? extends IScannedFileItem> unsafeFiles)
Creates an exception with the passed message that notifies about the passed 'unsafe' files.- Parameters:
 message- the message (more technical)unsafeFiles- the upload files classified as 'unsafe' by the malware or content type check
 
 - 
 
- 
Method Detail
- 
unsafeFiles
public List<? extends IScannedFileItem> unsafeFiles()
- Returns:
 - the upload files classified as 'unsafe' by the malware or content type check
 
 
- 
getErrorCode
public String getErrorCode()
- Specified by:
 getErrorCodein interfaceIErrorDetails- Returns:
 - the related error code string (as a technical error description)
 
 
- 
getHttpStatusCode
public int getHttpStatusCode()
- Specified by:
 getHttpStatusCodein interfaceIErrorDetails- Returns:
 - the HTTP status code related to this error
 
 
- 
getErrorMessage
public String getErrorMessage(Locale locale)
- Specified by:
 getErrorMessagein interfaceIErrorDetails- Parameters:
 locale- the local to be used for localization- Returns:
 - a (usually localized) detailed error description for the end user
 
 
- 
key
protected String key()
- Returns:
 - the i18n key for message localization
 
 
 - 
 
 -