commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Michael Davey <Michael.Da...@CodeRage.ORG>
Subject [betwixt] XML files and XMLIntrospector
Date Sun, 27 Oct 2002 20:10:53 GMT

I am having a problem with betwixt and I am not sure whether it is a bug 
or lack of unserstanding.  I am trying to write an inner class as XML, 
using BeanWriter and a *.betwixt configuration file.  Neither the outer 
nor the inner class extend XMLBeanInfo or BeanInfo, however the inner 
class does have public mutators and accessors.

The problem is that XMLIntrospector (actually 
ElementDescriptor.hasAttributes()) does not see the 'id' attribute for 
my inner class when looking for the ID/IDREF attribute 
(getIDAttribute()) while preparing to write the class.  The introspector 
does see the attribute later, when looking for other elements and 
attributes to write out.  The result is that a sequential id is used 
rather than the id provided by getId() in my inner class (actually, both 
are written).

I've attached a testcase that demonstrates the problem.  Untar it from 
the base directory (the the directory with build.xml).  Please note that 
the tar contains a modified version of 

Does this look like user error or a bug?

Also, I had problems running the test target from build.xml.  The 
basedir seems to be set incorrectly.  I've attached a patch in case I am 


View raw message