| java.lang.Object com.sun.tools.internal.txw2.NameUtil
NameUtil | public class NameUtil (Code) | | author: Kohsuke Kawaguchi |
capitalize | public static String capitalize(String s)(Code) | | Capitalizes the first character of the specified string,
and de-capitalize the rest of characters.
|
equal | public static boolean equal(String s, String t)(Code) | | determine if two Strings are iqual allowing null values
Parameters: s - string 1 Parameters: t - string 2 true iff the strings are equal, false if they aren't equal or either ofthem are null. |
equalsIgnoreCase | public static boolean equalsIgnoreCase(String s, String t)(Code) | | determine if two Strings are equal ignoring case allowing null values
Parameters: s - string 1 Parameters: t - string 2 true iff the given strings are equal ignoring case, false if they aren'tequal or either of them are null. |
escape | public static void escape(StringBuffer sb, String s, int start)(Code) | | Escapes characters is the given string so that they can be
printed by only using US-ASCII characters.
The escaped characters will be appended to the given
StringBuffer.
Parameters: sb - StringBuffer that receives escaped string. Parameters: s - String to be escaped. s.substring(start) will be escaped and copied to the string buffer. |
escapeURI | public static String escapeURI(String s)(Code) | | Escape any characters that would cause the single arg constructor
of java.net.URI to complain about illegal chars.
Parameters: s - source string to be escaped |
getParentUriPath | public static String getParentUriPath(String uriPath)(Code) | | Calculate the parent URI path of the given URI path.
Parameters: uriPath - the uriPath (as returned by java.net.URI#getPath() the parent URI path of the given URI path |
isDigit | protected static boolean isDigit(char c)(Code) | | |
isLetter | protected static boolean isLetter(char c)(Code) | | |
isLower | protected static boolean isLower(char c)(Code) | | |
isPunct | protected static boolean isPunct(char c)(Code) | | |
isUpper | protected static boolean isUpper(char c)(Code) | | |
nextBreak | protected static int nextBreak(String s, int start)(Code) | | |
normalizeUriPath | public static String normalizeUriPath(String uriPath)(Code) | | Calculate the normalized form of the given uriPath.
For example:
/a/b/c/ -> /a/b/c/
/a/b/c -> /a/b/
/a/ -> /a/
/a -> /
Parameters: uriPath - path of a URI (as returned by java.net.URI#getPath() the normalized uri path |
toConstantName | public static String toConstantName(String s)(Code) | | Formats a string into "THIS_KIND_OF_FORMAT_ABC_DEF".
Always return a string but there's no guarantee thatthe generated code is a valid Java identifier. |
toConstantName | public static String toConstantName(String[] ss)(Code) | | Formats a string into "THIS_KIND_OF_FORMAT_ABC_DEF".
Always return a string but there's no guarantee thatthe generated code is a valid Java identifier. |
toMixedCaseName | protected static String toMixedCaseName(String[] ss, boolean startUpper)(Code) | | |
toMixedCaseVariableName | protected static String toMixedCaseVariableName(String[] ss, boolean startUpper, boolean cdrUpper)(Code) | | |
toWordList | public static String[] toWordList(String s)(Code) | | Tokenizes a string into words and capitalizes the first
character of each word.
This method uses a change in character type as a splitter
of two words. For example, "abc100ghi" will be splitted into
{"Abc", "100","Ghi"}.
|
|
|