Re: JDOM and XPath API

Michael Kay <[email protected]>
Newsgroups gmane.comp.java.jdom.general
Message-ID <[email protected]>
> Further, with that change, the XPath class can easily become an 
> interface... which may improve the flexibility of some things.
>
> The XPathFactory class can have the same newInstance(), selectNodes() 
> And selectSingleNode() methods which will in turn use a shortcut to 
> the defaultFactory(). But, it can also be used to allow for different 
> implementations of the factory.
>

The methods selectNodes() and selectSingleNode() are very XPath-1.0 
oriented. If there's going to be an API change at this stage of the 
game, it would really make sense to anticipate XPath 2.0. Unfortunately 
that's potentially quite complex, for example how do you handle an XPath 
expression that returns a sequence of dates? For two attempts to solve 
this problem, you can look at the XQJ API and Saxon's s9api API.

Michael Kay
_______________________________________________
To control your jdom-interest membership:
http://www.jdom.org/mailman/options/jdom-interest/[email protected]
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.