[xsd-users] Questions on few features.
Boris Kolpackov
boris at codesynthesis.com
Wed Jul 18 05:08:06 EDT 2007
Hi Shivakumar,
Balasubramanyam, Shivakumar <sbalasub at qualcomm.com> writes:
> [Shiva] I am using the xerces parser and have no issues at present.
> It seems like you guys are already headed towards other serializers.
> I was thinking plugging in a binary serializer. Like Boost, the
> serializers could be XML, binary or simple text logging.
Well, this is already supported. You can serialize to XML (using
Xerces-C++), to a binary data representation such as XDR or CDR
(for which you will need a library that performs low-level binary
serialization, such as ACE CDR streams, see the 'binary' example)
or to simple "unstructured" text by generating the std::ostream
insertion operators with the --generate-ostream option.
> But XSD has the important function to generate the mapping and
> structure. Why should XSD depend on xerces for logging in XML?
Because XSD does not do low-level XML serialization itself (things
like character encoding, escaping of special symbols, indentation,
etc.). Instead it depends on existing facilities in Xerces-C++.
Plus it is much more flexible since you can serialize the data
to DOM instead of XML and then do some extra processing like
calculating a digital signature, etc.
hth,
-boris
More information about the xsd-users
mailing list