[jdom-interest] XPath bindings?

Elliotte Rusty Harold elharo at metalab.unc.edu
Fri Oct 12 10:02:51 PDT 2001


At 11:20 AM -0400 10/12/01, bob mcwhirter wrote:
>

>You're correct in that an xpathExpr may select non-node items, but
>following the 80/20 rule, folks are mostly going to be selecting
>nodes.  
>

80/20 solutions should nonetheless be 100% conformant to the relevant specs. We must not try to simplify the API by pretending that XPath is simpler than it actually is. JDOM should be as simple as it can be, but no simpler!

The API proposed allows programmers to pass in any XPath expression. Therefore the return value needs to make sense for any possible XPath expression. Simply saying that 80% of the time programmers are going to pass in XPath expressions that do select nodes isn't good enough. 
-- 

+-----------------------+------------------------+-------------------+
| Elliotte Rusty Harold | elharo at metalab.unc.edu | Writer/Programmer |
+-----------------------+------------------------+-------------------+ 
|          The XML Bible, 2nd Edition (Hungry Minds, 2001)           |
|              http://www.ibiblio.org/xml/books/bible2/              |
|   http://www.amazon.com/exec/obidos/ISBN=0764547607/cafeaulaitA/   |
+----------------------------------+---------------------------------+
|  Read Cafe au Lait for Java News:  http://www.cafeaulait.org/      | 
|  Read Cafe con Leche for XML News: http://www.ibiblio.org/xml/     |
+----------------------------------+---------------------------------+



More information about the jdom-interest mailing list