Hi James,
 
> 
> Is this limitation on element name uniqueness limited only to
> sequences?  I've got a schema with a duplicate name for two different
> complex types and it seems like the source generator is only creating
> a single occurrence of the class (the first one, BTW).  Am I missing
> an option someplace?

What do you mean by "duplicate name for two different complex types"?
The name of top-level complexType has to be unique.
However if a top-level complexType and a top-level element shares the
same name, you can run across a name collision when running the source
generator in default mode. You'll need to write a small binding file to
tell the source generator how to handle names shared by both
complexTypes and elements.


> 
> If not, is this something that might be in the works to support in the
> future?

Yes definitely, we want Castor to read/write all XML Schemas as defined
by the W3C recommendation.

Arnaud



> 
> 
>                       "Arnaud Blandin"
>                       <blandin@intalio.        To:
[EMAIL PROTECTED]
>                       com>                     cc:
>                                                Subject:  Re:
[castor-dev]
> Source Gen. Fails for Valid Schema
>                       11/29/2002 08:31
>                       AM
>                       Please respond to
>                       castor-dev
> 
> 
> 
> 
> 
> Hi,
> 
> This is a known limitation: the Schema Object Model doesn't currently
> allow two elements with the same name inside a <sequence>.
> 
> Sorry for the inconvenience,
> 
> Arnaud
> 
> -----Original Message-----
> From: Tankut Koray [mailto:[EMAIL PROTECTED]]
> Sent: Friday, November 29, 2002 1:42 PM
> To: [EMAIL PROTECTED]
> Subject: [castor-dev] Source Gen. Fails for Valid Schema
> 
> Hi all,
> 
> I have a schema that is valid with XmlSpy 5. And also it looks ok with
> me.
> 
> But castor gives the�below exception:
> 
> What could be the reason for this?
> 
> Thanks,
> 
> Tankut Koray
> 
>
------------------------------------------------------------------------
> 
> ----------------------------------------------------
> An element declaration with the given name, Unit, already exists
> in this scope.
> ������� at
> org.exolab.castor.xml.schema.reader.Sax2ComponentReader.startElement(
> Unknown Source)
> ������� at
> org.apache.xerces.parsers.SAXParser.startElement(SAXParser.java:1340)
> 
> ������� at
> org.apache.xerces.validators.common.XMLValidator.callStartElement(XML
> Validator.java:1197)
> ������� at
> org.apache.xerces.framework.XMLDocumentScanner.scanElement(XMLDocumen
> tScanner.java:1862)
> ������� at
> org.apache.xerces.framework.XMLDocumentScanner$ContentDispatcher.disp
> atch(XMLDocumentScanner.java:1238)
> ������� at
> org.apache.xerces.framework.XMLDocumentScanner.parseSome(XMLDocumentS
> canner.java:381)
> ������� at
> org.apache.xerces.framework.XMLParser.parse(XMLParser.java:1035)
> ������� at
> org.exolab.castor.xml.schema.reader.IncludeUnmarshaller.<init>(Unknow
> n Source)
> ������� at
> org.exolab.castor.xml.schema.reader.SchemaUnmarshaller.startElement(U
> nknown Source)
> ������� at
> org.exolab.castor.xml.schema.reader.Sax2ComponentReader.startElement(
> Unknown Source)
> ������� at
> org.apache.xerces.parsers.SAXParser.startElement(SAXParser.java:1340)
> 
> ������� at
> org.apache.xerces.validators.common.XMLValidator.callStartElement(XML
> Validator.java:1197)
> ������� at
> org.apache.xerces.framework.XMLDocumentScanner.scanElement(XMLDocumen
> tScanner.java:1862)
> ������� at
> org.apache.xerces.framework.XMLDocumentScanner$ContentDispatcher.disp
> atch(XMLDocumentScanner.java:1238)
> ������� at
> org.apache.xerces.framework.XMLDocumentScanner.parseSome(XMLDocumentS
> canner.java:381)
> ������� at
> org.apache.xerces.framework.XMLParser.parse(XMLParser.java:1035)
> ������� at
> org.exolab.castor.builder.SourceGenerator.generateSource(Unknown Sour
> ce)
> ������� at
> org.exolab.castor.builder.SourceGenerator.generateSource(Unknown Sour
> ce)
> ������� at org.exolab.castor.builder.SourceGenerator.main(Unknown
> Source)
>
------------------------------------------------------------------------
> 
> -------------------------------------------------
> 
> -----------------------------------------------------------
> If you wish to unsubscribe from this mailing, send mail to
> [EMAIL PROTECTED] with a subject of:
>              unsubscribe castor-dev
> 
> -----------------------------------------------------------
> If you wish to unsubscribe from this mailing, send mail to
> [EMAIL PROTECTED] with a subject of:
>       unsubscribe castor-dev

----------------------------------------------------------- 
If you wish to unsubscribe from this mailing, send mail to
[EMAIL PROTECTED] with a subject of:
        unsubscribe castor-dev

Reply via email to