|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.crosswire.common.util.Convert
public final class Convert
Conversions between various types and Strings.
The GNU Lesser General Public License for details.| Field Summary | |
|---|---|
private static org.slf4j.Logger |
log
The log stream |
| Constructor Summary | |
|---|---|
private |
Convert()
We don't want anyone doing this ... |
| Method Summary | |
|---|---|
static String |
boolean2String(boolean data)
Convert a boolean to a String |
static String |
int2String(int data)
Convert an int to a String |
static String |
map2String(Map<? extends Object,? extends Object> commands)
Convert a Map to a Sting |
static String |
object2String(Object data)
Convert an Object to a String |
static boolean |
string2Boolean(String data)
Convert a String to a boolean |
static int |
string2Int(String data)
Convert a String to an int |
static PropertyMap |
string2Map(String data)
Convert a String to a Map, without type checking |
static Object |
string2Object(String data)
Convert a String to an Object |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
private static final org.slf4j.Logger log
| Constructor Detail |
|---|
private Convert()
| Method Detail |
|---|
public static boolean string2Boolean(String data)
data - the thing to convert
public static String boolean2String(boolean data)
data - the thing to convert
public static int string2Int(String data)
data - the thing to convert
public static String int2String(int data)
data - the thing to convert
public static Object string2Object(String data)
throws InstantiationException,
ClassNotFoundException,
IllegalAccessException
data - the thing to convert
InstantiationException - if this data represents an abstract class,
an interface, an array class, a primitive type, or void;
or if the class has no nullary constructor;
or if the instantiation fails for some other reason.
ClassNotFoundException - if the class is not found
IllegalAccessException - if the class or its nullary
constructor is not accessible.public static String object2String(Object data)
data - the thing to convert
public static PropertyMap string2Map(String data)
data - the thing to convert
public static String map2String(Map<? extends Object,? extends Object> commands)
commands - the thing to convert
|
Copyright ยจ 2003-2015 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||