public final class Strings extends Object
| Modifier and Type | Method and Description |
|---|---|
static boolean |
containsAny(CharSequence cs,
char[] searchChars)
Checks if the CharSequence contains any character in the given set of characters.
|
static boolean |
containsAny(CharSequence cs,
CharSequence searchChars)
Checks if the CharSequence contains any character in the given set of characters.
|
static int |
countMatches(CharSequence str,
CharSequence sub)
Counts how many times the substring appears in the larger string.
|
static boolean |
equalsAny(CharSequence cs,
CharSequence[] strs)
Checks if the CharSequence equals any character in the given set of characters.
|
static boolean |
isEmpty(CharSequence cs)
Checks if a CharSequence is empty ("") or null.
|
public static boolean equalsAny(CharSequence cs, CharSequence[] strs)
cs - the CharSequence to checkfirst - the first CharSequencerest - the rest CharSequencepublic static boolean containsAny(CharSequence cs, CharSequence searchChars)
cs - the CharSequence to check, may be nullsearchChars - the chars to search for, may be nulltrue if any of the chars are found, false if no match or null inputpublic static boolean containsAny(CharSequence cs, char[] searchChars)
cs - the CharSequence to check, may be nullsearchChars - the chars to search for, may be nulltrue if any of the chars are found, false if no match or null inputpublic static boolean isEmpty(CharSequence cs)
cs - the CharSequence to check, may be nulltrue if the CharSequence is empty or nullpublic static int countMatches(CharSequence str, CharSequence sub)
str - the CharSequence to check, may be nullsub - the substring to count, may be nullnullCopyright © 2017 Eclipse Paho. All Rights Reserved.