Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Is it possible to generate a C++ class from a xsd using Qt (without the XSD tool)?

I get several Datasets listed in a single xml File. I have to extract each dataset and do some operations depending on their values (not changing the content of the xml file). So I have to parse that file.

With the .Net Framework I would simply use the XSD tool to generate a matching class avoiding to write a parser myself. Unfortunately that project has to be done using Qt and mingw and I'm not sure if there is similar tool.

Is it possible to (auto)generate a c++/qt class from xsd?

If it is: how?

like image 724
mbx Avatar asked May 22 '11 09:05

mbx


2 Answers

Nice question! You should not worry if Qt has such a feature. You can use CodeSynthesisXSD which is open source. The you can combine the generated classes to your Qt project.

like image 145
Narek Avatar answered Oct 28 '22 22:10

Narek


You may want to check CodeSynthesis XSD see this

like image 20
snoofkin Avatar answered Oct 28 '22 23:10

snoofkin