[xsde-users] XSD or XSD/e?

Duncan.Perrett at elekta.com Duncan.Perrett at elekta.com
Tue Aug 18 12:29:23 EDT 2009


Thank you Boris.



From:
Boris Kolpackov <boris at codesynthesis.com>
To:
Duncan.Perrett at elekta.com
Cc:
xsde-users at codesynthesis.com
Date:
18/08/2009 15:14
Subject:
Re: [xsde-users] XSD or XSD/e?



Hi Duncan,

Duncan.Perrett at elekta.com <Duncan.Perrett at elekta.com> writes:

> "The code generated by the CodeSynthesis compiler is the complete code 
> needed in order to serialize objects based on the defined schema.  XSD/e 

> is aimed at embedded applications, using its own library, whilst XSD 
> relies on XML parsers provided by other libraries.  For object 
> serialization, this library choice is restricted to Xerces.  On closer 
> examiniation, there appears to be no means of serializing an XML 
document 
> into a class with CodeSynthesis XSD/e; code is only generated for 
> serializing object data to file.  CodeSynthesis XSD, however could be 
used 
> to generate XML data of the required form".

Some of this analysis is not exactly correct. Let me clarify a few
things:

1. XSD (or, more precisely, the C++/Tree mapping) consists of three 
   parts: the generated code, the header-only runtime library (libxsd),
   and the underlying XML parser/serializer (Xerces-C++).

2. XSD/e (again, more precisely, the C++/Hybrid mapping which is
   similar to C++/Tree but is designed and optimized for embedded
   systems) consists of two parts: the generated code and the
   runtime library (libxsde). The runtime library includes a
   customized versions of XML parser (expat) and serializer 
   (genx).

3. The C++/Hybrid mapping in XSD/e, just like C++/Tree in XSD, is
   capable of parsing the XML documents to the in-memory object
   model (C++ classes) and serializing this object model back to XML.


> I notice that XSD/e supports LynxOS but does XSD?

There is a way to use XSD on LynxOS but the procedure for building
Xerces-C++ is quite complex (we have built it once on LynxOS 4.2
for a client). So unless you have strong reasons to prefer XSD,
I suggest that you go with XSD/e. It has been tested and is
fully supported on LynxOS 4.2 and 5.0.

Let me know if you have any further questions.

Boris




More information about the xsde-users mailing list