[jdom-interest] Problem with getChildren() (again)
Matthew Merlo
matthew.j.merlo at lmco.com
Thu Aug 17 06:49:40 PDT 2000
Take a harder look at your XML, <Feature role="test"> is the only child of
<Metadata>. Do a getChildren() on <Metadata>'s child, and you'll get your
other two features.
> -----Original Message-----
> From: jdom-interest-admin at jdom.org
> [mailto:jdom-interest-admin at jdom.org]On Behalf Of Christophe D. Laprun
> Sent: Thursday, August 17, 2000 9:13 AM
> To: jdom-interest at jdom.org
> Subject: [jdom-interest] Problem with getChildren() (again)
>
>
> Hi,
>
> I have a piece of XMl that looks like this:
> ...
> <Metadata>
> <Feature role="test">
> <Feature id="dr1" role="dialect">
> <Parameter role="dialect-code" datatype="string">dr1</Parameter>
> <Parameter role="dialect" datatype="string">Northeast</Parameter>
> </Feature>
>
> <Feature id="jsp0" role="speaker-id">
> <Parameter role="initials" datatype="string">jsp</Parameter>
> <Parameter role="suffix" datatype="int">0</Parameter>
> <Parameter role="sex" datatype="string">female</Parameter>
> <Parameter role="DOB" datatype="string">06/10/64</Parameter>
> </Feature>
> </Feature>
> </Metadata>
> ...
>
> and when I try to do the following:
>
> metadata.getChildren("Feature"),
>
> the only thing that's returned is the first Feature element (with
> role="test").
>
> The problem seems to come at the Element level since content only
> contains this first element. Could that be a bug of SAXBuilder or Xerces
> ?
> Also, on a similar note, has anyone experienced segmentation fault of
> JDK1.2.2 from Sun on Linux because of Xerces
> (InvalidDatatypeFacetException) ?
>
> Regards,
>
> Chris
>
> --
> Christophe Laprun [Ingenieur ISIMA, France / Guest researcher @NIST]
> web: http://www.nist.gov/speech/staff/laprunch.htm
> email: chris.laprun at nist.gov
> phone: (301) 975 3191 fax: (301) 670 0939
> --
> The universe seems neither benign nor hostile, merely indifferent -
> Sagan
> _______________________________________________
> To control your jdom-interest membership:
> http://lists.denveronline.net/mailman/options/jdom-interest/yourad
dr at yourhost.com
More information about the jdom-interest
mailing list