[dsdl-discuss] Re: DSRL - DSDL Part 8

From: Martin Bryan <martin@is-thought.co.uk>
Date: Wed Apr 11 2007 - 18:01:50 UTC

Murata-san

>XML Infoset has Unexpanded Entity Reference Information Items
and Unparsed Entity Information Items only. It does not provide entity
declarations. Furthermore, unexpanded entity reference information
Items occur only when entity references are not expanded. How do you apply renaming
to entity declarations and expanded references to entities?

The only way you can do it is to remove the entity declarations in the source file so that the entity references become unexpanded entity references. Not neat, but as I see it the only way to go. What I actually do is to create dummy entries for mapped entity names in a "entity definition translation" file and then require these to be manually edited to match the original entity exp[ansions as there is no way of getting at the declarations during parsing. But remember that what DSRL does in practice is create a set of rules to be applied to the source file. They ideally need to be applied before parsing and therefore entity expansion. This being difficult to do you have to presume some preprocessing. As entity sets are normally referenced rather than included in the local subset this becomes simple if you have a mechanism for redirecting references to the external file set.

Martin

--
DSDL members discussion list
To unsubscribe, please send a message with the
command  "unsubscribe" to dsdl-discuss-request@dsdl.org
(mailto:dsdl-discuss-request@dsdl.org?Subject=unsubscribe)
Received on Wed Apr 11 20:02:31 2007

This archive was generated by hypermail 2.1.8 : Thu Apr 12 2007 - 01:33:01 UTC