Package org.keycloak.common.util
Class ObjectUtil
- java.lang.Object
-
- org.keycloak.common.util.ObjectUtil
-
public class ObjectUtil extends Object
- Author:
- Marek Posolda
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static String
capitalize(String str)
static boolean
isBlank(CharSequence cs)
Forked from apache-commons StringUtilsstatic boolean
isEqualOrBothNull(Object str1, Object str2)
-
-
-
Method Detail
-
isEqualOrBothNull
public static boolean isEqualOrBothNull(Object str1, Object str2)
- Parameters:
str1
-str2
-- Returns:
- true if both strings are null or equal
-
isBlank
public static boolean isBlank(CharSequence cs)
Forked from apache-commons StringUtilsChecks if a CharSequence is whitespace, empty ("") or null.
ObjectUtil.isBlank(null) = true ObjectUtil.isBlank("") = true ObjectUtil.isBlank(" ") = true ObjectUtil.isBlank("bob") = false ObjectUtil.isBlank(" bob ") = false
- Parameters:
cs
-- Returns:
true
if the CharSequence is null, empty or whitespace
-
-