Difference between revisions of "Rationale"
From wiki
(New page: This section lists some design decisions that have been during the development of the library. The output streams do not accept a grammar during construction for validation : * validation...) |
(→In an output stream the attributes of an element are sorted alphabetically and not in their serialization order) |
||
(4 intermediate revisions by the same user not shown) | |||
Line 1: | Line 1: | ||
− | This section lists some design decisions that have been during the development of the library. | + | This section lists some design decisions that have been made during the development of the library. |
− | The output streams do not accept a grammar during construction for validation | + | == The output streams do not accept a grammar during construction for validation == |
* validation can only occur once the document is complete | * validation can only occur once the document is complete | ||
* failed validation usually throws an exception | * failed validation usually throws an exception | ||
Line 7: | Line 7: | ||
* a destructor must not throw | * a destructor must not throw | ||
* anyway it's simple enough to re-open the output stream with an input stream for validation afterwards | * anyway it's simple enough to re-open the output stream with an input stream for validation afterwards | ||
+ | |||
+ | == Document type definitions (DTD) cannot be specified with an external grammar == | ||
+ | * see [http://mail-archives.apache.org/mod_mbox/xerces-c-users/200605.mbox/%3Ce5jj27$vh$2@sea.gmane.org%3E this thread] for details | ||
+ | |||
+ | == In an output stream the attributes of an element are sorted alphabetically == | ||
+ | * there is no control over the order of attributes in {{MediaWiki:Xerces-link}}, see [http://mail-archives.apache.org/mod_mbox/xerces-c-users/200610.mbox/%3C454783CE.5050604@apache.org%3E this thread] for a (short) explanation |
Latest revision as of 12:04, 22 November 2010
This section lists some design decisions that have been made during the development of the library.
The output streams do not accept a grammar during construction for validation
- validation can only occur once the document is complete
- failed validation usually throws an exception
- the xml::xofstream uses RAII to flush the document to file in its destructor
- a destructor must not throw
- anyway it's simple enough to re-open the output stream with an input stream for validation afterwards
Document type definitions (DTD) cannot be specified with an external grammar
- see this thread for details
In an output stream the attributes of an element are sorted alphabetically
- there is no control over the order of attributes in Apache Xerces, see this thread for a (short) explanation