Qt 5.4 : XML and XSD in data model



  • Hi,

    I have an xsd file with more than 700 fields. There are to many fields to use QXmlStreamReader, and test each branch or node.

    In C#, we can create a .cs file from an .xsd file, and use the class to fill data into and serialize / deserialize it into / from an XML file.

    How can I do this in Qt ? What is the best way to fill or read data received into an XML file, validate it using on .xsd file, and use the data as a class (or data model) in my software ?

    Thanks for answers or advices.


  • Lifetime Qt Champion

    Hi and welcome to devnet,

    AFAIK, there's no direct Qt way to do this however your can use "this":http://www.codesynthesis.com/products/xsd/ to generate C++ classes that you can then use in your Qt code


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.