public final class Util extends Object
| Modifier and Type | Field and Description |
|---|---|
static BigInteger |
BIG_INTEGER_TWO |
static Character[] |
ZERO_LENGTH_CHARACTER_ARRAY |
| Modifier and Type | Method and Description |
|---|---|
static BigInteger |
countCaseInsensitiveVariations(CharSequence value)
Count number of variation of words in case insensitive manner.
|
static OptionalInt |
indexOfNextCaseSensitiveCharacter(CharSequence text,
int startIndex)
Finds next case sensitive character.
|
static String |
randomlyChangeCase(Random rnd,
CharSequence input)
Randomly change case for the letters in a string
|
static String |
repeat_char(char c,
int times)
Repeats text multiple times
|
static Character[] |
stringToChars(CharSequence str) |
public static final Character[] ZERO_LENGTH_CHARACTER_ARRAY
public static final BigInteger BIG_INTEGER_TWO
public static Character[] stringToChars(CharSequence str)
public static String repeat_char(char c, int times)
c - character to repeattimes - number of times. Values less or equal to zero will result in empty stringpublic static String randomlyChangeCase(Random rnd, CharSequence input)
rnd - random to be usedinput - input string to randomizepublic static BigInteger countCaseInsensitiveVariations(CharSequence value)
value - word to calculate variationspublic static OptionalInt indexOfNextCaseSensitiveCharacter(CharSequence text, int startIndex)
text - text to be analyzedstartIndex - start search from index.empty if no such character presentCopyright © 2022. All rights reserved.