Package eu.europa.esig.dss.utils
Interface IUtils
- All Known Implementing Classes:
ApacheCommonsUtils
,GoogleGuavaUtils
public interface IUtils
-
Method Summary
Modifier and Type Method Description boolean
areStringsEqual(String text1, String text2)
boolean
areStringsEqualIgnoreCase(String text1, String text2)
void
cleanDirectory(File directory)
void
closeQuietly(Closeable closeable)
int
collectionSize(Collection collection)
void
copy(InputStream is, OutputStream os)
boolean
endsWithIgnoreCase(String text, String expected)
byte[]
fromBase64(String base64)
byte[]
fromHex(String hex)
long
getInputStreamSize(InputStream is)
boolean
isArrayEmpty(byte[] array)
boolean
isArrayEmpty(Object[] array)
boolean
isArrayNotEmpty(byte[] array)
boolean
isArrayNotEmpty(Object[] array)
boolean
isBase64Encoded(String base64String)
boolean
isCollectionEmpty(Collection collection)
boolean
isCollectionNotEmpty(Collection collection)
boolean
isMapEmpty(Map<?,?> map)
boolean
isMapNotEmpty(Map<?,?> map)
boolean
isStringBlank(String text)
boolean
isStringDigits(String text)
boolean
isStringEmpty(String text)
boolean
isStringNotBlank(String text)
boolean
isStringNotEmpty(String text)
boolean
isTrue(Boolean bool)
String
joinStrings(Collection<String> strings, String separator)
Collection<File>
listFiles(File folder, String[] extensions, boolean recursive)
String
lowerCase(String text)
byte[]
subarray(byte[] array, int start, int length)
String
substringAfter(String text, String after)
String
toBase64(byte[] bytes)
byte[]
toByteArray(InputStream is)
String
toHex(byte[] bytes)
String
trim(String text)
String
upperCase(String text)
void
write(byte[] content, OutputStream os)
-
Method Details
-
isStringEmpty
-
isStringNotEmpty
-
isStringBlank
-
isStringNotBlank
-
areStringsEqual
-
areStringsEqualIgnoreCase
-
isStringDigits
-
trim
-
joinStrings
-
substringAfter
-
endsWithIgnoreCase
-
lowerCase
-
upperCase
-
isArrayEmpty
-
isArrayNotEmpty
-
isArrayNotEmpty
boolean isArrayNotEmpty(byte[] array) -
isArrayEmpty
boolean isArrayEmpty(byte[] array) -
subarray
byte[] subarray(byte[] array, int start, int length) -
isTrue
-
isCollectionEmpty
-
isCollectionNotEmpty
-
isMapEmpty
-
isMapNotEmpty
-
collectionSize
-
toHex
-
fromHex
-
isBase64Encoded
-
toBase64
-
fromBase64
-
toByteArray
- Throws:
IOException
-
closeQuietly
-
copy
- Throws:
IOException
-
write
- Throws:
IOException
-
getInputStreamSize
- Throws:
IOException
-
cleanDirectory
- Throws:
IOException
-
listFiles
-