|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjd.xml.xpath.object.XObject
jd.xml.xpath.object.XString
XString represents a XPath object with type string.
Field Summary |
Fields inherited from class jd.xml.xpath.object.XObject |
TYPE_BOOLEAN, TYPE_NODESET, TYPE_NUMBER, TYPE_STRING, TYPE_VARIABLE, TYPES |
Constructor Summary | |
XString(String value)
Create a XString. |
Method Summary | |
int |
canConvertTo(Class javaClass)
Test if the XObject can be converted to an object with the given class. |
boolean |
compare(Equality equality,
String value)
Return if this XObject equals the given value. |
int |
getType()
Return XObject.TYPE_STRING |
boolean |
toBooleanValue()
Return true iff the string value has positive length. |
static boolean |
toBooleanValue(String s)
Return true iff the string value has positive length. |
static Character |
toCharacterValue(String value)
Convert a string to a character. |
double |
toNumberValue()
Return the number value of the string. |
static double |
toNumberValue(String in)
Convert a string into a double |
String |
toString()
Return a debug string representation of this XObject. |
String |
toStringValue()
Return the string value. |
Object |
toValue()
Return the string value. |
Object |
toValue(Class javaClass)
Convert the objects value to an object of the given class. |
Methods inherited from class jd.xml.xpath.object.XObject |
compare, compare, compare, compare, compare, equals, getTypeName, getTypeName, hashCode, toNodeSet, toXObject |
Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Constructor Detail |
public XString(String value)
value
- the string valueMethod Detail |
public int getType()
getType
in class XObject
public Object toValue()
toValue
in class XObject
public Object toValue(Class javaClass)
toValue
in class XObject
public int canConvertTo(Class javaClass)
canConvertTo
in class XObject
public static Character toCharacterValue(String value) throws XPathException
XPathException
- if the string hsa not a length of onepublic boolean toBooleanValue()
toBooleanValue
in class XObject
public static boolean toBooleanValue(String s)
public double toNumberValue()
toNumberValue
in class XObject
public static double toNumberValue(String in)
public String toStringValue()
toStringValue
in class XObject
public String toString()
toString
in class XObject
public boolean compare(Equality equality, String value)
compare
in class XObject
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |