[xsd-users] xsd compiler question about the --file-per-type option

Schrader, Glenn - 1002 - MITLL gschrad at ll.mit.edu
Wed Apr 19 17:46:25 EDT 2017


I have a hopefully simple question:

 

I have an xsd file with a number of root elements and I'm using
-generate-serialization to create the corresponding parser and serialization
functions. That all works fine. In the end I'll wind up with a huge schema
so I'd like to use -file-per-type so that each application module only needs
to #include the small header(s) for the type(s) it cares about. 

 

The issue is that when I use -file-per-type the type definitions are placed
in separate header files as I expected but all of the parser and
serialization functions are placed into the <xxx>.hxx header (for a schema
file named "<xxx>.xsd"). I would have expected the parser and serialization
function prototypes to also be in the same header as the type definition
rather than in the common header that #includes everything. 

 

Is there some way to tell the compiler to include those definitions in their
corresponding type headers? I didn't seen an obvious compiler parameter that
looked relevant.

 

Thanks,

Glenn Schrader

 

-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 5471 bytes
Desc: not available
Url : http://codesynthesis.com/pipermail/xsd-users/attachments/20170419/a4aa9351/smime.bin


More information about the xsd-users mailing list