This is the mail archive of the xsl-list@mulberrytech.com mailing list .


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

RE: use cases for d-o-e


Quoting Michael Kay <michael.h.kay@ntlworld.com>:

> > In the case of outputting nearly-but-not-quite-XML formats such as
> *SP
> > (and now, regretably, XQuery) it might be possible to
> > consider a variant
> > of the text output method that serialised element nodes as XML markup
> > rather than discarded them and processed content. That would mean
> > switching from xml output method with d-o-e to the text output method
> > would not involve explictly calling templates to serialize the node
> > structure.
> 
> I was wondering about another approach, a serialize() method that
> returns
> the XML serialization of (say) an element node, as a character string,
> which
> you can then insert into text output.

That would be great.  There have been occasions when I've wanted to
decorate my XSLT output with an XML comment which showed the fragment
of the input tree which was responsible for that output.  It might be
a bit difficult to get this to be indented properly on output, but I
suppose that if serialize() used column zero as an indentation base
and if there were an attribute to xsl:text which gave it permission
to add the current indentation to each line (I forget, does it do
that already?  My computer's in the shop so I don't have my environment
around to test it) then the indentation would work too.




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


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]