xom-interest AT lists.ibiblio.org
Subject: XOM API for Processing XML with Java
List archive
- From: "O'Brien-Strain, Eamonn" <eob AT exch.hpl.hp.com>
- To: "'Elliotte Rusty Harold'" <elharo AT metalab.unc.edu>
- Cc: "'xom-interest AT lists.ibiblio.org'" <xom-interest AT lists.ibiblio.org>
- Subject: RE: [XOM-interest] Sparta: similar to XOM.
- Date: Sun, 29 Sep 2002 14:11:43 -0700
> -----Original Message-----
> From: Elliotte Rusty Harold [mailto:elharo AT metalab.unc.edu]
[...]
> 2. I saw that when XPath was eventually added, an Attribute node
> class would be necessary. What does Sparta do when someone passes it
> an XPath that selects an Attribute node or nodes?
In the Sparta XPath subset it is possible to statically determine, just by
parsing the XPath expression, whether it selects an element or a string.
There are different xpathSelect*() methods for returning Elements and
Strings. For example:
Element foo = doc.xpathSelectElement( "/Top[@g='ggg']/Foo[4]" );
String bar = doc.xpathSelectString( "/Top[@g='ggg']/Foo[4]/@bar" );
There are also versions that return iterators over Elements or Strings -- in
the case of multiple matches the above methods return the first match.
The methods throw an exception when the wrong type of XPath is passed to them.
__
Eamonn
-
Re: [XOM-interest] Sparta: similar to XOM.
, (continued)
- Re: [XOM-interest] Sparta: similar to XOM., Elliotte Rusty Harold, 09/28/2002
- Re: [XOM-interest] Sparta: similar to XOM., Elliotte Rusty Harold, 09/28/2002
- Re: [XOM-interest] Sparta: similar to XOM., Elliotte Rusty Harold, 09/28/2002
-
Re: [XOM-interest] Sparta: similar to XOM.,
Elliotte Rusty Harold, 09/28/2002
-
Re: [XOM-interest] Sparta: similar to XOM.,
John Cowan, 09/28/2002
- [XOM-interest] O[depth], Elliotte Rusty Harold, 09/28/2002
-
Re: [XOM-interest] Sparta: similar to XOM.,
John Cowan, 09/28/2002
- RE: [XOM-interest] Sparta: similar to XOM., O'Brien-Strain, Eamonn, 09/29/2002
- RE: [XOM-interest] Sparta: similar to XOM., O'Brien-Strain, Eamonn, 09/29/2002
-
RE: [XOM-interest] Sparta: similar to XOM.,
O'Brien-Strain, Eamonn, 09/29/2002
- RE: [XOM-interest] Sparta: similar to XOM., Elliotte Rusty Harold, 09/29/2002
-
RE: [XOM-interest] Sparta: similar to XOM.,
O'Brien-Strain, Eamonn, 09/29/2002
- RE: [XOM-interest] Sparta: similar to XOM., Elliotte Rusty Harold, 09/29/2002
-
RE: [XOM-interest] Sparta: similar to XOM.,
O'Brien-Strain, Eamonn, 09/29/2002
- RE: [XOM-interest] Sparta: similar to XOM., Elliotte Rusty Harold, 09/29/2002
-
RE: [XOM-interest] Sparta: similar to XOM.,
O'Brien-Strain, Eamonn, 09/29/2002
- RE: [XOM-interest] Sparta: similar to XOM., Elliotte Rusty Harold, 09/29/2002
-
RE: [XOM-interest] Sparta: similar to XOM.,
O'Brien-Strain, Eamonn, 09/30/2002
- RE: [XOM-interest] Sparta: similar to XOM., Elliotte Rusty Harold, 09/30/2002
Archive powered by MHonArc 2.6.24.