[xsd-users] Removing whitespace from xml document

Boris Kolpackov boris at codesynthesis.com
Wed Sep 16 09:56:46 EDT 2009


Hi Simon,

PICKUP Simon <simon at thinkresearch.co.uk> writes:

> Is there any modifier or function I can use to write the xml file without
> whitespace and tabs? 
> 
> [...]
> 
>       ACE_RUNWAY_ANALYSIS(ofs, R, map);

Assuming you are using XSD 3.2.0, you can pass the dont_pretty_print
flag to the serialization functions. For example:

ACE_RUNWAY_ANALYSIS(ofs, R, map, "UTF-8", xml_schema::flags::dont_pretty_print);

For more information on serialization flags, see Section 4.3, "Flags"
in the C++/Tree Mapping User Manual:

http://www.codesynthesis.com/projects/xsd/documentation/cxx/tree/manual/#4.3


Boris




More information about the xsd-users mailing list