org.mortbay.util
public class TypeUtil extends Object
Since: Jetty 4.1
Version: $Revision: 1.14 $
Method Summary | |
---|---|
static byte | convertHexDigit(byte b) |
static void | dump(Class c) |
static void | dump(ClassLoader cl) |
static byte[] | fromHexString(String s) |
static Class | fromName(String name) Class from a canonical name for a type. |
static Integer | newInteger(int i) Convert int to Integer using cache. |
static byte[] | parseBytes(String s, int base) |
static int | parseInt(String s, int offset, int length, int base) Parse an int from a substring.
|
static char | toHexChar(int b) |
static String | toHexString(byte[] b) |
static String | toHexString(byte[] b, int offset, int length) |
static String | toName(Class type) Canonical name for a type. |
static String | toString(int i) Convert int to String using cache. |
static String | toString(byte[] bytes, int base) |
static Object | valueOf(Class type, String value) Convert String value to instance. |
static Object | valueOf(String type, String value) Convert String value to instance. |
Parameters: b An ASCII encoded character 0-9 a-f A-F
Returns: The byte value of the character 0-16.
Parameters: name A class or type name.
Returns: A class , which may be a primitive TYPE field..
Parameters: s String offset Offset within string length Length of integer or -1 for remainder of string base base of the integer
Throws: NumberFormatException
Parameters: type A class , which may be a primitive TYPE field.
Returns: Canonical name.
Parameters: type The class of the instance, which may be a primitive TYPE field. value The value as a string.
Returns: The value as an Object.
Parameters: type classname or type (eg int) value The value as a string.
Returns: The value as an Object.