• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Need Xalan Help

 
Ranch Hand
Posts: 67
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
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
 
Your buns are mine! But you can have this tiny ad:
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic