public class GlobalFileUploadFilter extends Object
Modifier and Type | Class and Description |
---|---|
static class |
GlobalFileUploadFilter.MagicNumberFileFilter
Hold a snapshot of values to be passed to an GlobalFileUploadFilter.
|
Modifier and Type | Field and Description |
---|---|
static int |
ALLOWED_NUMBER_OF_UPLOADS |
Constructor and Description |
---|
GlobalFileUploadFilter() |
Modifier and Type | Method and Description |
---|---|
static boolean |
accept(byte[] fileContent,
List<GlobalFileUploadFilter.MagicNumberFileFilter> filters) |
List<GlobalFileUploadFilter.MagicNumberFileFilter> |
getFilterConfig() |
static long |
getMaxFileSizeAllowed(List<GlobalFileUploadFilter.MagicNumberFileFilter> filters)
Getting the maximum file size allowed from the config
|
protected static byte[] |
hexStringToByteArray(String s) |
static GlobalFileUploadFilter |
newFileUploadFilter() |
public static final int ALLOWED_NUMBER_OF_UPLOADS
public List<GlobalFileUploadFilter.MagicNumberFileFilter> getFilterConfig()
protected static byte[] hexStringToByteArray(String s)
public static boolean accept(byte[] fileContent, List<GlobalFileUploadFilter.MagicNumberFileFilter> filters)
public static long getMaxFileSizeAllowed(List<GlobalFileUploadFilter.MagicNumberFileFilter> filters)
public static GlobalFileUploadFilter newFileUploadFilter()
Copyright © 2020 JBoss by Red Hat. All rights reserved.