[xsd-users] validation problem xsd and parse

giuseppe ferrari giuseppe500 at yahoo.it
Tue Jan 18 05:22:54 EST 2011


hy.
I'm trying to generate the c++ code for parse/serialize an ifc document with 
CodeSynthesis XSD 3.3.
The ifc is an architectonic xml format file

and this is the url where my files come

http://www.iai-tech.org/products/ifc_specification/ifcxml-releases/ifcxml2x3-release


This is the xsd command that generate my code:

xsd cxx-tree --generate-serialization --file-per-type --generate-polymorphic 
--namespace-map 
urn:iso.org:standard:10303:part(28):version(2):xmlschema:common=ex 
--namespace-map http://www.iai-tech.org/ifcXML/IFC2x3/FINAL=ifc --output-dir 
test ifc2x3.xsd 


then i add my files (cxx and hxx) to the solution in vs 2003 , set the input lib 
file and add the needs include .
Then compiling , all  work fine

My problem is that when i do the parsing an ifcxml  the c++ code catch these 
errors:
this is the code:

try
    {
    
        auto_ptr<ex::iso_10303_28> h 
(ex::iso_10303_28_("c:\\esempioifcxml.xml"));
        

    }
    catch (const xml_schema::exception& e)
    {
        cerr << e << endl;
        char ch;
        cin >> ch;
        return 1;
    }

these are the errors :

c:\esempioifcxml.xml:127:26 error: undefined prefix in QName value 'ifc:IfcUnit'
c:\esempioifcxml.xml:161:33 error: undefined prefix in QName value 
'ifc:IfcLengthMeasure'
c:\esempioifcxml.xml:202:43 error: undefined prefix in QName value 
'ifc:IfcRepresentationContext'
c:\esempioifcxml.xml:347:27 error: undefined prefix in QName value 
'ifc:IfcPresentationStyleSelect'
c:\esempioifcxml.xml:361:33 error: undefined prefix in QName value 
'ifc:IfcLengthMeasure'
c:\esempioifcxml.xml:379:31 error: undefined prefix in QName value 
'ifc:IfcFillStyleSelect'
c:\esempioifcxml.xml:384:27 error: undefined prefix in QName value 
'ifc:IfcPresentationStyleSelect'
c:\esempioifcxml.xml:389:27 error: undefined prefix in QName value 
'ifc:IfcPresentationStyleAssignment'
c:\esempioifcxml.xml:397:26 error: undefined prefix in QName value 
'ifc:IfcRepresentationItem'
c:\esempioifcxml.xml:402:37 error: undefined prefix in QName value 
'ifc:IfcRepresentation'
c:\esempioifcxml.xml:417:36 error: undefined prefix in QName value 
'ifc:IfcMaterialLayer'
c:\esempioifcxml.xml:431:33 error: undefined prefix in QName value 
'ifc:IfcLengthMeasure'
c:\esempioifcxml.xml:467:39 error: undefined prefix in QName value 
'ifc:IfcRepresentation'
c:\esempioifcxml.xml:480:26 error: undefined prefix in QName value 
'ifc:IfcRepresentationItem'
c:\esempioifcxml.xml:482:30 error: undefined prefix in QName value 
'ifc:IfcCartesianPoint'
c:\esempioifcxml.xml:484:37 error: undefined prefix in QName value 
'ifc:IfcLengthMeasure'

what's mean?

I must post the xml file?
thanks.



      


More information about the xsd-users mailing list