[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Re: Passing through character entities intact

Subject: Re: Passing through character entities intact
From: David Carlisle <davidc@xxxxxxxxx>
Date: Thu, 11 Oct 2001 16:05:19 +0100
maths elements
> why can the serializer check for document specific references?

because there is nothing in the data model that could tell the XSLT
processor what entities are defined in a DTD. And remember enities are
not just characters, If you had an entiy that was defined to be a whole
fragment of XML, with element and attribute nodes, would you expect the
serialiser to recognise that branch of the result tree and output it as
&xxx;?

> Why then doesn't XSLT processors or the output XML serializer take a look at
> output document type and any included general entity declarations could
> matched to the output stream to replace with a reference.


Taking a real example, the DTD most used around here has a thousand or
so enity definitions that look like the one at the end of this message.


Do you really expect the serialiser to spot that occuring in the result
tree and write it out as &e04BL-a; ?

& has to be output as &amp; (or some equivalent thing) as an unquoted &
is illegal, so the situation there is different.


Given that you are writing an XML (or HTML) file and so any application
that is reading that output will not care whether there is an entity
reference or its expansion, why do you think it important that XSLT
support that?

David


<!ENTITY e04BL-a	'<input><arg>BL</arg> must contain the lower bounds and <arg>BU</arg> the upper bounds, for all the constraints in the following order.  The first <maths>n</maths> elements of each array must contain the bounds on the variables, the next <maths>n_{L}</maths> elements the bounds for the general linear constraints (if any) and the next <maths>n_{<arg>N</arg>}</maths> elements the bounds for the general nonlinear constraints (if any).  To specify a non-existent lower bound (&ie; <maths>l_{j} = -\infty</maths>), set <maths><arg>BL</arg>(j) \leq -bigbnd</maths>, and to specify a non-existent upper bound (&ie; <maths>u_{j} = +\infty</maths>), set <maths><arg>BU</arg>(j) \geq bigbnd</maths>; the default value of <maths>bigbnd</maths> is <maths>10^{20}</maths>, but this may be changed by the optional parameter <bold>Infinite Bound Size</bold> (see <xref type="sec" id="optparamsdescription"/>).  To specify the <maths>j</maths>th constraint as an <italic>equality</italic>, set <maths><arg>BL</arg>(j) = <arg>BU</arg>(j) = \beta</maths>, say, where <maths>|\beta | &lt; bigbnd</maths>.</input><cons><list type="cons"><item><maths><arg>BL</arg>(j) \leq <arg>BU</arg>(j)</maths>, for <maths>j = 1,2,\ldots,<arg>N</arg>+<arg>NCLIN</arg>+<arg>NCNLN</arg></maths>,</item><item><maths>|\beta | &lt; bigbnd</maths> when <maths><arg>BL</arg>(j) = <arg>BU</arg>(j) = \beta</maths>.</item></list></cons>'	>

_____________________________________________________________________
This message has been checked for all known viruses by Star Internet
delivered through the MessageLabs Virus Scanning Service. For further
information visit http://www.star.net.uk/stats.asp or alternatively call
Star Internet for details on the Virus Scanning Service.

 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.