public class StringUtils extends Object
| Constructor and Description |
|---|
StringUtils() |
| Modifier and Type | Method and Description |
|---|---|
static Optional<String> |
getNonEmptyStringAfterTrim(String str)
Returns non-empty
Optional<String>, if the given String is non-empty after
applying trim() operation. |
static boolean |
isNullOrEmpty(String str)
Check whether the given
String is null or empty. |
static boolean |
isNullOrEmptyAfterTrim(String str)
Check whether the given
String is null of empty after the trim operation. |
public static boolean isNullOrEmpty(String str)
String is null or empty.str - input stringString is null or empty.public static boolean isNullOrEmptyAfterTrim(String str)
String is null of empty after the trim operation.str - input string.String is null or empty after trim.public static Optional<String> getNonEmptyStringAfterTrim(String str)
Optional<String>, if the given String is non-empty after
applying trim() operation.str - input String.Optional<String>, if the given String is non-empty after
applying trim() operation. If not an empty Optional<String> will be returned.Copyright © 2017 WSO2. All rights reserved.