Java org.apache.hadoop.util StringUtils fields, constructors, methods, implement or subclass

Example usage for Java org.apache.hadoop.util StringUtils fields, constructors, methods, implement or subclass

Introduction

In this page you can find the methods, fields and constructors for org.apache.hadoop.util StringUtils.

The text is from its open source code.

Subclass

org.apache.hadoop.util.StringUtils has subclasses.
Click this link to see all its subclasses.

Field

Method

StringarrayToString(String[] strs)
Given an array of strings, return a comma-separated list of its elements.
StringbyteDesc(long len)
StringbyteToHexString(byte bytes[])
Same as byteToHexString(bytes, 0, bytes.length).
StringbyteToHexString(byte b)
Convert a byte to a hex string.
StringbyteToHexString(byte[] bytes, int start, int end)
Given an array of bytes it will convert the bytes to a hex string representation of the bytes
Stringcamelize(String s)
Convert SOME_STUFF to SomeStuff
booleanequalsIgnoreCase(String s1, String s2)
Compare strings locale-freely by using String#equalsIgnoreCase.
StringescapeString(String str)
Escape commas in the string using the default escape char
StringescapeString(String str, char escapeChar, char charToEscape)
Escape charToEscape in the string with the escape char escapeChar
StringescapeString(String str, char escapeChar, char[] charsToEscape)
intfindNext(String str, char separator, char escapeChar, int start, StringBuilder split)
Finds the first occurrence of the separator character ignoring the escaped separators starting from the index.
StringformatPercent(double fraction, int decimalPlaces)
Format a percentage for presentation to the user.
StringformatTime(long timeDiff)
Given the time in long milliseconds, returns a String in the format Xhrs, Ymins, Z sec.
StringformatTimeDiff(long finishTime, long startTime)
Given a finish and start time in long milliseconds, returns a String in the format Xhrs, Ymins, Z sec, for the time difference between two times.
CollectiongetStringCollection(String str)
Returns a collection of strings.
CollectiongetStringCollection(String str, String delim)
Returns a collection of strings.
String[]getStrings(String str)
Returns an arraylist of strings.
CollectiongetTrimmedStringCollection(String str)
Splits a comma separated value String, trimming leading and trailing whitespace on each value.
String[]getTrimmedStrings(String str)
Splits a comma or newline separated value String, trimming leading and trailing whitespace on each value.
byte[]hexStringToByte(String hex)
Given a hexstring this will return the byte array corresponding to the string
StringhumanReadableInt(long number)
Given an integer, return a string that is in an approximate, but human readable format.
Stringjoin(CharSequence separator, Iterable strings)
Concatenates strings, using a separator.
Stringjoin(char separator, Iterable strings)
Stringjoin(CharSequence separator, String[] strings)
Concatenates strings, using a separator.
Stringjoin(char separator, String[] strings)
StringlimitDecimalTo2(double d)
StringsimpleHostname(String fullHostname)
Given a full hostname, return the word upto the first dot.
String[]split(String str, char separator)
Split a string using the given separator, with no escaping performed.
String[]split(String str)
Split a string using the default separator
String[]split(String str, char escapeChar, char separator)
Split a string using the given separator
voidstartupShutdownMessage(Class clazz, String[] args, final org.apache.commons.logging.Log LOG)
Print a log message for starting up and shutting down
voidstartupShutdownMessage(Class clazz, String[] args, final org.slf4j.Logger LOG)
Print a log message for starting up and shutting down
voidstartupShutdownMessage(Class clazz, String[] args, final LogAdapter LOG)
StringstringifyException(Throwable e)
Make a string representation of the exception.
Path[]stringToPath(String[] str)
StringtoLowerCase(String str)
Converts all of the characters in this String to lower case with Locale.ENGLISH.
StringunEscapeString(String str)
Unescape commas in the string using the default escape char
StringunEscapeString(String str, char escapeChar, char charToEscape)
Unescape charToEscape in the string with the escape char escapeChar
StringunEscapeString(String str, char escapeChar, char[] charsToEscape)
StringuriToString(URI[] uris)