Hi Glenn, Good catch. Seems the API and the implementation got out of synch here [1] shortly before the XML Schema API was published. The fix you're suggesting is correct. I need to check what affect it will have on other parts of the code before applying it.
Thanks. [1] http://svn.apache.org/viewcvs.cgi/xerces/java/trunk/src/org/apache/xerces/xs/XSObject.java?rev=319493&r1=319491&r2=319493&diff_format=h Michael Glavassevich XML Parser Development IBM Toronto Lab E-mail: [EMAIL PROTECTED] E-mail: [EMAIL PROTECTED] Glenn Ammons <[EMAIL PROTECTED]> wrote on 11/09/2005 12:41:08 PM: > I'm sorry if this is a known bug, but the bug repository at > > http://issues.apache.org/jira/browse/XERCESJ > > appears to be down. > > The problem is that getName() returns null for anonymous types. I > consider this a bug because the specification at > > http://www.w3.org/Submission/2004/SUBM-xmlschema-api-20040122/xml- > schema-api.html > > says > > For anonymous types, the processor must construct and expose an > anonymous type name that is distinct from the name of every named > type and the name of every other anonymous type. > > It appears that Xerces obeys the "construct" part but falls down on > the "expose" part. The culprit is > > src/org/apache/xerces/impl/xs/XSComplexTypeDecl.java > > which contains this: > > public String getName() { > return getAnonymous() ? null : fName; > } > > I think that it ought to read > > public String getName() { > return fName; > } > > Thanks. > --glenn > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
