Basically clients will be reading information from a DOM Document Object. I am using XPathAPI so the clients can query the Document Object, but the clients want methods like
getString, getInt, getLong, etc.. the prim types.
Currently I have this:
public
String search(String xPathExpression) {
String result = null;
try {
XObject temp = XSearch.eval(doc.getDocumentElement(),
xPathExpression);
result = temp.toString();
return result;
} catch (Exception e) {
return null;
}
}
Which just returns a string, what can I do to get the XObject returned by the eval call to also return ints, floats, etc..??
Also if there is a better way to do this, PLEASE let me know.
Rob