|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.nutch.util.StringUtil
A collection of String processing utility methods.
Constructor Summary | |
StringUtil()
|
Method Summary | |
static String |
leftPad(String s,
int length)
Returns a copy of s padded with leading spaces so
that it's length is length . |
static void |
main(String[] args)
|
static String |
parseCharacterEncoding(String contentType)
Parse the character encoding from the specified content type header. |
static String |
resolveEncodingAlias(String encoding)
|
static String |
rightPad(String s,
int length)
Returns a copy of s padded with trailing spaces so
that it's length is length . |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public StringUtil()
Method Detail |
public static String rightPad(String s, int length)
s
padded with trailing spaces so
that it's length is length
. Strings already
length
characters long or longer are not altered.
public static String leftPad(String s, int length)
s
padded with leading spaces so
that it's length is length
. Strings already
length
characters long or longer are not altered.
public static String parseCharacterEncoding(String contentType)
null
is returned.
contentType
- a content type headerpublic static String resolveEncodingAlias(String encoding)
public static void main(String[] args)
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |