public final class WhitespaceConversions
extends java.lang.Object
Modifier | Constructor and Description |
---|---|
private |
WhitespaceConversions()
Non-constructor for class with no instances.
|
Modifier and Type | Method and Description |
---|---|
static java.lang.String |
collapse(java.lang.String text)
Collapse whitespace in string.
|
private static java.lang.String |
convertCollapsed(java.lang.String text,
int index)
Convert string value to whitespace-collapsed form.
|
private static java.lang.String |
convertReplaced(java.lang.String text,
int index)
Convert string value to whitespace-replaced form.
|
static java.lang.String |
replace(java.lang.String text)
Replace non-space whitespace in string.
|
static java.lang.String |
trim(java.lang.String text)
Trim leading and trailing whitespace in string.
|
private WhitespaceConversions()
private static java.lang.String convertReplaced(java.lang.String text, int index)
text
- value to be convertedindex
- first character offset to be dropped from resultpublic static java.lang.String replace(java.lang.String text)
text
- value to be converted (null
if none)null
if none)private static java.lang.String convertCollapsed(java.lang.String text, int index)
text
- value to be convertedindex
- first character offset to be dropped from resultpublic static java.lang.String collapse(java.lang.String text)
text
- value to be converted (null
if none)null
if none)public static java.lang.String trim(java.lang.String text)
text
- value to be converted (null
if none)null
if none)