[ http://issues.apache.org/jira/browse/TUSCANY-445?page=all ]
Yang ZHONG updated TUSCANY-445: ------------------------------- Attachment: fidelity.xsd fidelity.xml Wrong Type is generated/used to load XML. "fidelity.xsd" and "fidelity.xml" are attached for the following Test Case. int sdotest::testFidelity() { DataFactoryPtr mdg = DataFactory::getDataFactory(); XSDHelperPtr xsh = HelperProvider::getXSDHelper(mdg); xsh->defineFile("fidelity.xsd"); XMLHelperPtr myXMLHelper = HelperProvider::getXMLHelper(mdg); XMLDocumentPtr myXMLDocument = myXMLHelper->loadFile("fidelity.xml"); DataObjectPtr root = myXMLDocument->getRootDataObject(); DataObjectPtr open = root->getDataObject("ComplexTypeOpenContent"); DataObjectPtr ElementSubstitutionGroupExtends = open->getDataObject(0u); const Type& type = ElementSubstitutionGroupExtends->getType(); const char* p = type.getName(); if(strcmp(p, "ComplexTypeSubstitutionGroupExtendsType")) return 0; return 1; } > ComplexTypeOpenContent output element type incorrect > ---------------------------------------------------- > > Key: TUSCANY-445 > URL: http://issues.apache.org/jira/browse/TUSCANY-445 > Project: Tuscany > Issue Type: Bug > Components: C++ SDO > Affects Versions: Cpp-current > Environment: Windows XP > Reporter: Simon Laws > Fix For: Cpp-current > > Attachments: fidelity.xml, fidelity.xsd > > > Reading > <ComplexTypeOpenContent> > <tns:ElementSubstitutionGroupExtends> > > <ElementInSubstitutionGroupBase>ElementInSubstitutionGroupBase</ElementInSubstitutionGroupBase> > > <ElementInSubstitutionGroupExtends>ElementInSubstitutionGroupExtends</ElementInSubstitutionGroupExtends> > </tns:ElementSubstitutionGroupExtends> > </ComplexTypeOpenContent> > With schema > <complexType name="ComplexTypeOpenContentType"> > <sequence> > <any namespace="##any"/> > </sequence> > </complexType> > Gets written as > <ComplexTypeOpenContent> > <ElementSubstitutionGroupExtends > xsi:type="ComplexTypeSubstitutionGroupBaseType"> > <ElementInSubstitutionGroupBase> > ElementInSubstitutionGroupBase > </ElementInSubstitutionGroupBase> > </ElementSubstitutionGroupExtends> > </ComplexTypeOpenContent> > Where the type indicated is the base of the substitution group -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]