Modifier and Type | Field and Description |
---|---|
private static final String[] | |
private static final String[] | |
public static final char | |
public static final char | |
private static final int | CSV_NUMBER_ESCAPE_CHARACTERS
2 - Quote character at beginning and end. |
public static final char | |
public static final String | |
private static final byte[] | |
public static final char | |
public static final String | |
private static final char | |
public static final char | |
public static final char |
Access | Constructor and Description |
---|---|
private |
Modifier and Type | Method and Description |
---|---|
public static String | |
public static <T extends Appendable> T | byteToHexString(T buf, int value)
Converts the specified byte value into a hexadecimal integer and appends it to the specified buffer. |
public static String | byteToHexStringPadded(int value)
Converts the specified byte value into a 2-digit hexadecimal integer. |
public static <T extends Appendable> T | byteToHexStringPadded(T buf, int value)
Converts the specified byte value into a 2-digit hexadecimal integer and appends it to the specified buffer. |
public static boolean | Returns: true if both s and p are not null and both have the same suffix. Otherwise - falsestring s, String string p, int length of the common suffix len)Checks if two strings have the same suffix of specified length |
public static byte | |
public static byte[] | decodeHexDump(CharSequence
a hexDump, int CharSequence which contains the hex dumpstart of hex dump in fromIndex, int hexDump hex string length length)Decodes part of a string with hex dump |
public static byte[] | |
public static int | Returns: The hexadecimal value represented in the ASCII character given, or-1 if the character is invalid.The ASCII character of the hexadecimal number to decode.
Must be in the range c)[0-9a-fA-F] .Helper to decode half of a hexadecimal number from a string. |
public static int | Returns: The hexadecimal value represented in the ASCII character given, or-1 if the character is invalid.The ASCII character of the hexadecimal number to decode.
Must be in the range b)[0-9a-fA-F] .Helper to decode half of a hexadecimal number from a string. |
public static boolean | Returns: true ifs ends with the char c the string to test s, char the tested char c)Determine if the string |
public static CharSequence | Returns: CharSequence the escaped value if necessary, or the value unchangedThe value which will be escaped according to
RFC-4180 value)Escapes the specified value, if necessary according to RFC-4180. |
public static CharSequence | Returns: CharSequence the escaped value if necessary, or the value unchangedThe value which will be escaped according to
RFC-4180 value, boolean The value will first be trimmed of its optional white-space characters,
according to RFC-7230 trimWhiteSpace)Escapes the specified value, if necessary according to RFC-4180. |
private static int | |
private static int | |
public static int | Returns: the index of the first non-white space character or <-1 if none was found.The string to search. seq, int The offset to start searching at. offset)Find the index of the first non-white space character in |
public static int | Returns: the index of the first white space character or <-1 if none was found.The string to search. seq, int The offset to start searching at. offset)Find the index of the first white space character in |
private static boolean | |
public static boolean | |
private static boolean | |
public static boolean | Returns: true if c lies within the range of values defined for
Surrogate Code Point. false otherwise.the character to check. c)Determine if |
public static CharSequence | Returns: a char sequence joined by a given separator.for each element separator, Iterable<? extends CharSequence> to join together elements)Returns a char sequence that contains all |
public static int | |
private static IllegalArgumentException | |
public static String | |
public static String | |
public static String | substringAfter(String value, char delim)
Get the item after one char delim if the delim is found (else null). |
public static String | substringBefore(String value, char delim)
Get the item before one char delim if the delim is found (else null). |
public static String | |
public static String | toHexString(byte[] src, int offset, int length)
Converts the specified byte array into a hexadecimal value. |
public static <T extends Appendable> T | toHexString(T dst, byte[] src)
Converts the specified byte array into a hexadecimal value and appends it to the specified buffer. |
public static <T extends Appendable> T | toHexString(T dst, byte[] src, int offset, int length)
Converts the specified byte array into a hexadecimal value and appends it to the specified buffer. |
public static String | |
public static String | toHexStringPadded(byte[] src, int offset, int length)
Converts the specified byte array into a hexadecimal value. |
public static <T extends Appendable> T | toHexStringPadded(T dst, byte[] src)
Converts the specified byte array into a hexadecimal value and appends it to the specified buffer. |
public static <T extends Appendable> T | toHexStringPadded(T dst, byte[] src, int offset, int length)
Converts the specified byte array into a hexadecimal value and appends it to the specified buffer. |
public static CharSequence | Returns: CharSequence the trimmed value if necessary, or the value unchangedthe value to trim value)Trim optional white-space characters from the specified value, according to RFC-7230. |
public static CharSequence | Returns: CharSequence the unescaped value if necessary, or the value unchangedThe escaped CSV field which will be unescaped according to
RFC-4180 value)Unescapes the specified escaped CSV field, if necessary according to RFC-4180. |
public static List | Returns: List the list of unescaped fieldsA string with multiple CSV escaped fields which will be unescaped according to
RFC-4180 value)Unescapes the specified escaped CSV fields according to RFC-4180. |
private static void |
BYTE2HEX_NOPAD | back to summary |
---|---|
private static final String[] BYTE2HEX_NOPAD |
BYTE2HEX_PAD | back to summary |
---|---|
private static final String[] BYTE2HEX_PAD |
CARRIAGE_RETURN | back to summary |
---|---|
public static final char CARRIAGE_RETURN |
COMMA | back to summary |
---|---|
public static final char COMMA |
CSV_NUMBER_ESCAPE_CHARACTERS | back to summary |
---|---|
private static final int CSV_NUMBER_ESCAPE_CHARACTERS 2 - Quote character at beginning and end. 5 - Extra allowance for anticipated escape characters that may be added. |
DOUBLE_QUOTE | back to summary |
---|---|
public static final char DOUBLE_QUOTE |
EMPTY_STRING | back to summary |
---|---|
public static final String EMPTY_STRING |
HEX2B | back to summary |
---|---|
private static final byte[] HEX2B |
LINE_FEED | back to summary |
---|---|
public static final char LINE_FEED |
NEWLINE | back to summary |
---|---|
public static final String NEWLINE |
PACKAGE_SEPARATOR_CHAR | back to summary |
---|---|
private static final char PACKAGE_SEPARATOR_CHAR |
SPACE | back to summary |
---|---|
public static final char SPACE |
TAB | back to summary |
---|---|
public static final char TAB |
StringUtil | back to summary |
---|---|
private StringUtil() |
byteToHexString | back to summary |
---|---|
public static String byteToHexString(int value) Converts the specified byte value into a hexadecimal integer. |
byteToHexString | back to summary |
---|---|
public static <T extends Appendable> T byteToHexString(T buf, int value) Converts the specified byte value into a hexadecimal integer and appends it to the specified buffer. |
byteToHexStringPadded | back to summary |
---|---|
public static String byteToHexStringPadded(int value) Converts the specified byte value into a 2-digit hexadecimal integer. |
byteToHexStringPadded | back to summary |
---|---|
public static <T extends Appendable> T byteToHexStringPadded(T buf, int value) Converts the specified byte value into a 2-digit hexadecimal integer and appends it to the specified buffer. |
commonSuffixOfLength | back to summary |
---|---|
public static boolean commonSuffixOfLength(String s, String p, int len) Checks if two strings have the same suffix of specified length |
decodeHexByte | back to summary |
---|---|
public static byte decodeHexByte(CharSequence s, int pos) Decode a 2-digit hex byte from within a string. |
decodeHexDump | back to summary |
---|---|
public static byte[] decodeHexDump(CharSequence hexDump, int fromIndex, int length) Decodes part of a string with hex dump
|
decodeHexDump | back to summary |
---|---|
public static byte[] decodeHexDump(CharSequence hexDump) Decodes a hex dump |
decodeHexNibble | back to summary |
---|---|
public static int decodeHexNibble(final char c) Helper to decode half of a hexadecimal number from a string.
|
decodeHexNibble | back to summary |
---|---|
public static int decodeHexNibble(final byte b) Helper to decode half of a hexadecimal number from a string.
|
endsWith | back to summary |
---|---|
public static boolean endsWith(CharSequence s, char c) Determine if the string
|
escapeCsv | back to summary |
---|---|
public static CharSequence escapeCsv(CharSequence value) Escapes the specified value, if necessary according to RFC-4180.
|
escapeCsv | back to summary |
---|---|
public static CharSequence escapeCsv(CharSequence value, boolean trimWhiteSpace) Escapes the specified value, if necessary according to RFC-4180.
|
indexOfFirstNonOwsChar | back to summary |
---|---|
private static int indexOfFirstNonOwsChar(CharSequence value, int length)
|
indexOfLastNonOwsChar | back to summary |
---|---|
private static int indexOfLastNonOwsChar(CharSequence value, int start, int length)
|
indexOfNonWhiteSpace | back to summary |
---|---|
public static int indexOfNonWhiteSpace(CharSequence seq, int offset) Find the index of the first non-white space character in
|
indexOfWhiteSpace | back to summary |
---|---|
public static int indexOfWhiteSpace(CharSequence seq, int offset) Find the index of the first white space character in
|
isDoubleQuote | back to summary |
---|---|
private static boolean isDoubleQuote(char c) |
isNullOrEmpty | back to summary |
---|---|
public static boolean isNullOrEmpty(String s) Determine if a string is |
isOws | back to summary |
---|---|
private static boolean isOws(char c) |
isSurrogate | back to summary |
---|---|
public static boolean isSurrogate(char c) Determine if
|
join | back to summary |
---|---|
public static CharSequence join(CharSequence separator, Iterable<? extends CharSequence> elements) Returns a char sequence that contains all
|
length | back to summary |
---|---|
public static int length(String s) Get the length of a string, |
newInvalidEscapedCsvFieldException | back to summary |
---|---|
private static IllegalArgumentException newInvalidEscapedCsvFieldException(CharSequence value, int index) |
simpleClassName | back to summary |
---|---|
public static String simpleClassName(Object o) The shortcut to |
simpleClassName | back to summary |
---|---|
public static String simpleClassName(Class<?> clazz) Generates a simplified name from a |
substringAfter | back to summary |
---|---|
public static String substringAfter(String value, char delim) Get the item after one char delim if the delim is found (else null).
This operation is a simplified and optimized
version of |
substringBefore | back to summary |
---|---|
public static String substringBefore(String value, char delim) Get the item before one char delim if the delim is found (else null).
This operation is a simplified and optimized
version of |
toHexString | back to summary |
---|---|
public static String toHexString(byte[] src) Converts the specified byte array into a hexadecimal value. |
toHexString | back to summary |
---|---|
public static String toHexString(byte[] src, int offset, int length) Converts the specified byte array into a hexadecimal value. |
toHexString | back to summary |
---|---|
public static <T extends Appendable> T toHexString(T dst, byte[] src) Converts the specified byte array into a hexadecimal value and appends it to the specified buffer. |
toHexString | back to summary |
---|---|
public static <T extends Appendable> T toHexString(T dst, byte[] src, int offset, int length) Converts the specified byte array into a hexadecimal value and appends it to the specified buffer. |
toHexStringPadded | back to summary |
---|---|
public static String toHexStringPadded(byte[] src) Converts the specified byte array into a hexadecimal value. |
toHexStringPadded | back to summary |
---|---|
public static String toHexStringPadded(byte[] src, int offset, int length) Converts the specified byte array into a hexadecimal value. |
toHexStringPadded | back to summary |
---|---|
public static <T extends Appendable> T toHexStringPadded(T dst, byte[] src) Converts the specified byte array into a hexadecimal value and appends it to the specified buffer. |
toHexStringPadded | back to summary |
---|---|
public static <T extends Appendable> T toHexStringPadded(T dst, byte[] src, int offset, int length) Converts the specified byte array into a hexadecimal value and appends it to the specified buffer. |
trimOws | back to summary |
---|---|
public static CharSequence trimOws(CharSequence value) Trim optional white-space characters from the specified value, according to RFC-7230.
|
unescapeCsv | back to summary |
---|---|
public static CharSequence unescapeCsv(CharSequence value) Unescapes the specified escaped CSV field, if necessary according to RFC-4180.
|
unescapeCsvFields | back to summary |
---|---|
public static List Unescapes the specified escaped CSV fields according to RFC-4180.
|
validateCsvFormat | back to summary |
---|---|
private static void validateCsvFormat(CharSequence value) Validate if
|