public class StringUtils extends Object
| Modifier and Type | Method and Description |
|---|---|
static <T> StringBuilder |
appendAll(StringBuilder sb,
T... elements)
Append to the string Builder all elements
|
static boolean |
isEmptyBlankOr(String string,
String... ors)
Check if the string is empty or has one of specified values
|
static boolean |
isEmptyOrBlankNotNull(String string)
Check if the string is empty or blank
|
static boolean |
isEmptyOrNull(String string)
Check if the string is null or empty
|
static boolean |
isNullEmptyOrBlank(String string)
Check if the string is null, blank or empty
|
static boolean |
noOneIsEmpty(String... strings)
Check if the strings are empty
|
static boolean |
noOneIsEmptyNorBlank(String... strings)
Check if the strings are empty or blank
|
static <T> String |
separateArrayBy(T[] array,
String separator)
Generate a string based on array, with a specified separator
|
static <T> String |
separateTreeMapValuesBy(Map<T,String> map,
String separator)
Generate a string based on map values, with a specified separator.
|
public static boolean isEmptyOrNull(String string)
string - The input stringpublic static boolean isNullEmptyOrBlank(String string)
string - The input stringpublic static boolean isEmptyOrBlankNotNull(String string)
string - The input stringpublic static boolean noOneIsEmptyNorBlank(String... strings)
strings - The input stringspublic static boolean noOneIsEmpty(String... strings)
strings - The input stringspublic static boolean isEmptyBlankOr(String string, String... ors)
string - The input stringors - The values to checkpublic static <T> StringBuilder appendAll(StringBuilder sb, T... elements)
T - The elements typesb - The string builderelements - The elements to appendpublic static <T> String separateArrayBy(T[] array, String separator)
T - The array typearray - The input arrayseparator - The separatorpublic static <T> String separateTreeMapValuesBy(Map<T,String> map, String separator)
T - The map key typemap - The input mapseparator - The separatorCopyright © 2018 Okkam srl. All rights reserved.