Opened 15 years ago

Closed 15 years ago

#510 closed defect (fixed)

FDO Schema Writer bases gml:AbstractFeatureType on itself

Reported by: brentrobinson Owned by: brentrobinson
Priority: minor Milestone: 3.5.0
Component: FDO API Version: 3.5.0
Severity: 3 Keywords: FDO XML Schema writer AbstractFeatureType infinite recursion
Cc: External ID:

Description

The following code:

    FdoFeatureSchemasP schemas = FdoFeatureSchemaCollection::Create(NULL);
    FdoFeatureSchemasP schemas2 = FdoFeatureSchemaCollection::Create(NULL);

    FdoXmlFlagsP flags = FdoXmlFlags::Create(
        L"",
        FdoXmlFlags::ErrorLevel_VeryLow
    );

    schemas = FdoFeatureSchemaCollection::Create(NULL);
    FdoXmlReaderP gmlReader = FdoGml212Schema::CreateReader();
    schemas->ReadXml( gmlReader, flags );

    // Write the schema back to an XML document.
    schemas->WriteXml( L"schema_gml212a.xml", flags );

    schemas2 = FdoFeatureSchemaCollection::Create(NULL);
    schemas2->ReadXml( L"schema_gml212a.xml", flags );

leads to an infinite recursion on the 2nd ReadXml. The problem is that WriteXML writes out gml:AbstractFeatureType as an extension of itself.

Change History (1)

comment:1 by brentrobinson, 15 years ago

Resolution: fixed
Status: newclosed

Revision: 4561 Author: brentrobinson Date: 8:54:24 AM, Tuesday, April 21, 2009 Message: Ticket#510: prevent circular extension when writing gml:AbstractfeatureType to XML.


Modified : /trunk/Fdo/UnitTest/SchemaTest.cpp Modified : /trunk/Fdo/UnitTest/SchemaTest.h Modified : /trunk/Fdo/UnitTest/schema_ext1.xml Modified : /trunk/Fdo/UnitTest/schema_ext_a_master.txt Modified : /trunk/Fdo/Unmanaged/Src/Fdo/Schema/SchemaFromInternal.h Modified : /trunk/Fdo/Unmanaged/Src/Fdo/Schema/SchemaFromInternal.xslt

Note: See TracTickets for help on using tickets.