<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
	<id>tag:old.nabble.com,2006:forum-256</id>
	<title>Nabble - Xalan</title>
	<updated>2009-12-07T11:55:09Z</updated>
	<link rel="self" type="application/atom+xml" href="http://old.nabble.com/Xalan-f256.xml" />
	<link rel="alternate" type="text/html" href="http://old.nabble.com/Xalan-f256.html" />
	<subtitle type="html">Xalan is a XSLT processor for transforming XML documents into HTML, text, or other XML document types. Xalan home is &lt;a href=&quot;http://xml.apache.org/xalan-j/&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;here&lt;/a&gt;.</subtitle>
	
<entry>
	<id>tag:old.nabble.com,2006:post-26683096</id>
	<title>Re: Newbie questions regarding evaluating XPath using an arbitrary Xerces DOMElement as the context node</title>
	<published>2009-12-07T11:55:09Z</published>
	<updated>2009-12-07T11:55:09Z</updated>
	<author>
		<name>David Bertoni</name>
	</author>
	<content type="html">&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26683096&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;DJohnson@...&lt;/a&gt; wrote:
&lt;div class='shrinkable-quote'&gt;&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; I've looked over the relevant samples and documentation, but haven't 
&lt;br&gt;&amp;gt; found enough information. &amp;nbsp;Any pointers to useful doc or samples would 
&lt;br&gt;&amp;gt; be appreciated.
&lt;br&gt;&amp;gt; In fact, the samples and documentation lead me to additional questions:
&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; &amp;nbsp;From the XercesParserLiaison API, it would appear that I need 
&lt;br&gt;&amp;gt; buildMaps=true, and possibly buildWrapper=true, in order to map the 
&lt;br&gt;&amp;gt; Xerces DOMNode to its Xalan counterpart, but I don't see any method that 
&lt;br&gt;&amp;gt; uses the map to give me the Xalan node from the Xerces node.
&lt;/div&gt;buildWrapper determines if the wrapper is built all at once or as each 
&lt;br&gt;node is accessed. &amp;nbsp;And although it's not explicitly documented, I 
&lt;br&gt;believe asking for the maps will force the wrapper to be built.
&lt;br&gt;&lt;br&gt;To get at mapping information, you must cast the XalanDocument pointer 
&lt;br&gt;to the implementation type of XercesDocumentWrapper, and include the 
&lt;br&gt;header file for that class:
&lt;br&gt;&lt;br&gt;DOMNode* func(XalanDocument* doc, XalanNode* node)
&lt;br&gt;{
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;const XercesDocumentWrapper* wrapper = static_cast&amp;lt;const 
&lt;br&gt;XercesDocumentWrapper*&amp;gt;(doc);
&lt;br&gt;&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;return wrapper-&amp;gt;mapNode(node);
&lt;br&gt;}
&lt;br&gt;&lt;br&gt;XalanNode* func(XalanDocument* doc, DOMNode* node)
&lt;br&gt;{
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;const XercesDocumentWrapper* wrapper = static_cast&amp;lt;const 
&lt;br&gt;XercesDocumentWrapper*&amp;gt;(doc);
&lt;br&gt;&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;return wrapper-&amp;gt;mapNode(node);
&lt;br&gt;}
&lt;br&gt;&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; What is the overhead of enabling buildWrapper and buildMaps? &amp;nbsp;
&lt;br&gt;&amp;gt; Are they kept current across modifications to the original Xerces DOM?
&lt;br&gt;The overhead is the memory required to maintain the wrapper and the hash 
&lt;br&gt;maps of the nodes. This can be significant if your document is large.
&lt;br&gt;&lt;br&gt;The wrapper and the maps are _not_ maintained across modifications to 
&lt;br&gt;the Xerces DOM. Not only would it be complicated, but I'm not sure how 
&lt;br&gt;it's possible to track modifications to the Xerces DOM instance.
&lt;br&gt;&lt;div class='shrinkable-quote'&gt;&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; &amp;nbsp;From a sample, I have:
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp;// Set up our link between the Xerces and Xalan DOMs. (doc is a 
&lt;br&gt;&amp;gt; Xerces DOMDocument*)
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; XercesDOMSupport support;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; XercesParserLiaison liaison(support);
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; XercesDOMWrapperParsedSource &amp;nbsp;src(doc, liaison, support);
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; XalanDocument* xalanDoc = src.getDocument( );
&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; Yet it would appear from the API that I could pare that down to:
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp;// Set up our link between the Xerces and Xalan DOMs. (doc is a 
&lt;br&gt;&amp;gt; Xerces DOMDocument*)
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; XercesDOMSupport support;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; XercesParserLiaison liaison(support);
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; XalanDocument* xalanDoc = liaison.createDocument(doc, false, true, 
&lt;br&gt;&amp;gt; true);
&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; Are these equivalent, or is there a reason to use one over the other?
&lt;br&gt;&amp;gt; If I use XercesDOMWrapperParsedSource, do I need to set properties of 
&lt;br&gt;&amp;gt; liaison first to force mapping and wrapping?
&lt;/div&gt;You would only want to use a XercesDOMWrapperParsedSource if you plan to 
&lt;br&gt;use the XalanTransformer class to transform the document. Otherwise, if 
&lt;br&gt;you're using only the XPathEvaluator API, you can simply use the 
&lt;br&gt;XalanDocument instance returned from XercesParserLiaison::createDocument().
&lt;br&gt;&lt;br&gt;If you want the maps to be built, you must call 
&lt;br&gt;liaison.setBuildMaps(true) before you create the 
&lt;br&gt;XercesDOMWrapperParsedSource instance. XercesDOMWrapperParsed source 
&lt;br&gt;_forces_ the &amp;quot;threadSafe&amp;quot; and &amp;quot;buildWrapper&amp;quot; parameters to be true when 
&lt;br&gt;it calls XercesParserLiaison::createDocument().
&lt;br&gt;&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; If the overhead is significant to wrapping and/or mapping, especially if 
&lt;br&gt;&amp;gt; the entire document is processed, I would want to cache them for later 
&lt;br&gt;&amp;gt; use evaluating other XPaths. &amp;nbsp;
&lt;br&gt;&amp;gt; Which of the associated objects is sufficient to cache? &amp;nbsp;liason and 
&lt;br&gt;&amp;gt; xalanDoc? &amp;nbsp;support?
&lt;br&gt;The XercesParserLiaison owns the XalanDocument instance, so you must 
&lt;br&gt;keep that alive. The XalanDocument instance it creates owns the wrapper 
&lt;br&gt;and the maps, so you must keep that alive as well. Note that caching is 
&lt;br&gt;useless if you plan to modify the Xerces DOM instance.
&lt;br&gt;&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; And finally, how do I map a Xerces DOMNode/DOMElement to a Xalan node to 
&lt;br&gt;&amp;gt; use as the context for XPath evaluation?
&lt;br&gt;See the small function snippets I provided previously.
&lt;br&gt;&lt;br&gt;Dave
&lt;br&gt;&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Xalan---C---Users-f273.html&quot; embed=&quot;fixTarget[273]&quot; target=&quot;_top&quot; &gt;Xalan - C - Users&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/Newbie-questions-regarding-evaluating-XPath-using-an-arbitrary-Xerces-DOMElement-as-the-context-node-tp26680519p26683096.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26680519</id>
	<title>Newbie questions regarding evaluating XPath using an arbitrary Xerces DOMElement as the context node</title>
	<published>2009-12-07T09:13:51Z</published>
	<updated>2009-12-07T09:13:51Z</updated>
	<author>
		<name>DJohnson</name>
	</author>
	<content type="html">
&lt;br&gt;&lt;font size=2 face=&quot;sans-serif&quot;&gt;I've looked over the relevant samples
and documentation, but haven't found enough information. &amp;nbsp;Any pointers
to useful doc or samples would be appreciated.&lt;/font&gt;
&lt;br&gt;&lt;font size=2 face=&quot;sans-serif&quot;&gt;In fact, the samples and documentation
lead me to additional questions:&lt;/font&gt;
&lt;br&gt;
&lt;br&gt;&lt;font size=2 face=&quot;sans-serif&quot;&gt;From the XercesParserLiaison API, it
would appear that I need buildMaps=true, and possibly buildWrapper=true,
in order to map the Xerces DOMNode to its Xalan counterpart, but I don't
see any method that uses the map to give me the Xalan node from the Xerces
node.&lt;/font&gt;
&lt;br&gt;
&lt;br&gt;&lt;font size=2 face=&quot;sans-serif&quot;&gt;What is the overhead of enabling buildWrapper
and buildMaps? &amp;nbsp;&lt;/font&gt;
&lt;br&gt;&lt;font size=2 face=&quot;sans-serif&quot;&gt;Are they kept current across modifications
to the original Xerces DOM?&lt;/font&gt;
&lt;br&gt;
&lt;br&gt;&lt;font size=2 face=&quot;sans-serif&quot;&gt;From a sample, I have:&lt;/font&gt;
&lt;br&gt;&lt;font size=2&gt;&amp;nbsp; &amp;nbsp;&lt;/font&gt;&lt;font size=2 color=#008000&gt;// Set
up our link between the Xerces and Xalan DOMs. (doc is a Xerces DOMDocument*)&lt;/font&gt;
&lt;br&gt;&lt;font size=2&gt;&amp;nbsp; &amp;nbsp; XercesDOMSupport support;&lt;/font&gt;
&lt;br&gt;&lt;font size=2&gt;&amp;nbsp; &amp;nbsp; XercesParserLiaison liaison(support);&lt;/font&gt;
&lt;br&gt;&lt;font size=2&gt;&amp;nbsp; &amp;nbsp; XercesDOMWrapperParsedSource &amp;nbsp;src(doc,
liaison, support);&lt;/font&gt;
&lt;br&gt;&lt;font size=2&gt;&amp;nbsp; &amp;nbsp; XalanDocument* xalanDoc = src.getDocument(
);&lt;/font&gt;
&lt;br&gt;
&lt;br&gt;&lt;font size=2 face=&quot;sans-serif&quot;&gt;Yet it would appear from the API that
I could pare that down to:&lt;/font&gt;
&lt;br&gt;&lt;font size=2&gt;&amp;nbsp; &amp;nbsp;&lt;/font&gt;&lt;font size=2 color=#008000&gt;// Set
up our link between the Xerces and Xalan DOMs. (doc is a Xerces DOMDocument*)&lt;/font&gt;
&lt;br&gt;&lt;font size=2&gt;&amp;nbsp; &amp;nbsp; XercesDOMSupport support;&lt;/font&gt;
&lt;br&gt;&lt;font size=2&gt;&amp;nbsp; &amp;nbsp; XercesParserLiaison liaison(support);&lt;/font&gt;
&lt;br&gt;&lt;font size=2&gt;&amp;nbsp; &amp;nbsp; XalanDocument* xalanDoc = liaison.createDocument(doc,
false, true, true);&lt;/font&gt;
&lt;br&gt;
&lt;br&gt;&lt;font size=2 face=&quot;sans-serif&quot;&gt;Are these equivalent, or is there a
reason to use one over the other?&lt;/font&gt;
&lt;br&gt;&lt;font size=2 face=&quot;sans-serif&quot;&gt;If I use XercesDOMWrapperParsedSource,
do I need to set properties of liaison first to force mapping and wrapping?&lt;/font&gt;
&lt;br&gt;
&lt;br&gt;&lt;font size=2 face=&quot;sans-serif&quot;&gt;If the overhead is significant to wrapping
and/or mapping, especially if the entire document is processed, I would
want to cache them for later use evaluating other XPaths. &amp;nbsp;&lt;/font&gt;
&lt;br&gt;&lt;font size=2 face=&quot;sans-serif&quot;&gt;Which of the associated objects is sufficient
to cache? &amp;nbsp;liason and xalanDoc? &amp;nbsp;support?&lt;/font&gt;
&lt;br&gt;
&lt;br&gt;&lt;font size=2 face=&quot;sans-serif&quot;&gt;And finally, how do I map a Xerces DOMNode/DOMElement
to a Xalan node to use as the context for XPath evaluation?&lt;/font&gt;
&lt;br&gt;
&lt;br&gt;&lt;font size=2 face=&quot;sans-serif&quot;&gt;---------------------------------------------------&lt;br&gt;
David S. Johnson&lt;br&gt;
DeskNet Inc.&lt;/font&gt;&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Xalan---C---Users-f273.html&quot; embed=&quot;fixTarget[273]&quot; target=&quot;_top&quot; &gt;Xalan - C - Users&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/Newbie-questions-regarding-evaluating-XPath-using-an-arbitrary-Xerces-DOMElement-as-the-context-node-tp26680519p26680519.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26595959</id>
	<title>Re: How to achieve in xslt equivalent to xs:any in xerces</title>
	<published>2009-12-01T08:13:12Z</published>
	<updated>2009-12-01T08:13:12Z</updated>
	<author>
		<name>keshlam</name>
	</author>
	<content type="html">&lt;tt&gt;&lt;font size=2&gt;&amp;gt; So it seems to mean a new XSLT 2.0 processor has
been released about&lt;br&gt;
&amp;gt; two weeks ago?&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; &lt;/font&gt;&lt;/tt&gt;&lt;a href=&quot;http://www.ibm.com/common/ssi/rep_ca/1/897/ENUS209-391/ENUS209-391.PDF&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;&lt;tt&gt;&lt;font size=2&gt;http://www.ibm.com/common/ssi/rep_ca/1/897/ENUS209-391/ENUS209-391.PDF&lt;/font&gt;&lt;/tt&gt;&lt;/a&gt;&lt;tt&gt;&lt;font size=2&gt;&lt;br&gt;
&lt;/font&gt;&lt;/tt&gt;
&lt;br&gt;&lt;font size=2 face=&quot;sans-serif&quot;&gt;Yes, though it's only available as part
of the Websphere environment.&lt;/font&gt;
&lt;br&gt;
&lt;br&gt;&lt;font size=2 face=&quot;sans-serif&quot;&gt;(Don't bother asking me whether it will
be available through other channels. I honestly don't know, and if I did
I couldn't say so anyway.)&lt;/font&gt;
&lt;br&gt;&lt;font size=2 face=&quot;sans-serif&quot;&gt;&lt;br&gt;
______________________________________&lt;br&gt;
&amp;quot;... Three things see no end: A loop with exit code done wrong,&lt;br&gt;
A semaphore untested, And the change that comes along. ...&amp;quot;&lt;br&gt;
 &amp;nbsp;-- &amp;quot;Threes&amp;quot; Rev 1.1 - Duane Elms / Leslie Fish (&lt;/font&gt;&lt;a href=&quot;http://www.ovff.org/pegasus/songs/threes-rev-11.html&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;&lt;font size=2 face=&quot;sans-serif&quot;&gt;http://www.ovff.org/pegasus/songs/threes-rev-11.html&lt;/font&gt;&lt;/a&gt;&lt;font size=2 face=&quot;sans-serif&quot;&gt;)&lt;/font&gt;
&lt;br&gt;&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Xalan---J---Users-f275.html&quot; embed=&quot;fixTarget[275]&quot; target=&quot;_top&quot; &gt;Xalan - J - Users&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/How-to-achieve-in-xslt-equivalent-to-xs%3Aany-in-xerces-tp26577372p26595959.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26594002</id>
	<title>Re: How to achieve in xslt equivalent to xs:any in xerces</title>
	<published>2009-12-01T07:48:41Z</published>
	<updated>2009-12-01T07:48:41Z</updated>
	<author>
		<name>Michael Ludwig-6</name>
	</author>
	<content type="html">&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26594002&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;keshlam@...&lt;/a&gt; schrieb am 01.12.2009 um 09:13:46 (-0500):
&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; It means I've been involved with IBM's new XML Feature Pack for
&lt;br&gt;&amp;gt; Websphere, which supports the 2.0 versions; hence my carelessly
&lt;br&gt;&amp;gt; suggesting a 2.0-only solution.
&lt;br&gt;&lt;br&gt;So it seems to mean a new XSLT 2.0 processor has been released about
&lt;br&gt;two weeks ago?
&lt;br&gt;&lt;br&gt;&lt;a href=&quot;http://www.ibm.com/common/ssi/rep_ca/1/897/ENUS209-391/ENUS209-391.PDF&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://www.ibm.com/common/ssi/rep_ca/1/897/ENUS209-391/ENUS209-391.PDF&lt;/a&gt;&lt;br&gt;&lt;br&gt;-- 
&lt;br&gt;Michael Ludwig
&lt;br&gt;&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Xalan---J---Users-f275.html&quot; embed=&quot;fixTarget[275]&quot; target=&quot;_top&quot; &gt;Xalan - J - Users&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/How-to-achieve-in-xslt-equivalent-to-xs%3Aany-in-xerces-tp26577372p26594002.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26592819</id>
	<title>Re: Error in output when xmlns attribute is present</title>
	<published>2009-12-01T06:36:45Z</published>
	<updated>2009-12-01T06:36:45Z</updated>
	<author>
		<name>keshlam</name>
	</author>
	<content type="html">&lt;font size=2 face=&quot;sans-serif&quot;&gt;The xmlns attribute sets the default namespace.
XSLT is namespace-sensitive; to match namespace-qualified elements and
attributes you must match the namespaces as well (which means using prefixes
in your XSLT even though you used the default in the instance document,
since XSLT 1.0 has no ability to specify a default namespace for its match/select
patterns).&lt;/font&gt;
&lt;br&gt;
&lt;br&gt;&lt;font size=2 face=&quot;sans-serif&quot;&gt;&lt;br&gt;
______________________________________&lt;br&gt;
&amp;quot;... Three things see no end: A loop with exit code done wrong,&lt;br&gt;
A semaphore untested, And the change that comes along. ...&amp;quot;&lt;br&gt;
 &amp;nbsp;-- &amp;quot;Threes&amp;quot; Rev 1.1 - Duane Elms / Leslie Fish (&lt;/font&gt;&lt;a href=&quot;http://www.ovff.org/pegasus/songs/threes-rev-11.html&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;&lt;font size=2 face=&quot;sans-serif&quot;&gt;http://www.ovff.org/pegasus/songs/threes-rev-11.html&lt;/font&gt;&lt;/a&gt;&lt;font size=2 face=&quot;sans-serif&quot;&gt;)&lt;/font&gt;&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Xalan---J---Users-f275.html&quot; embed=&quot;fixTarget[275]&quot; target=&quot;_top&quot; &gt;Xalan - J - Users&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/Error-in-output-when-xmlns-attribute-is-present-tp26592425p26592819.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26592425</id>
	<title>Error in output when xmlns attribute is present</title>
	<published>2009-12-01T06:12:03Z</published>
	<updated>2009-12-01T06:12:03Z</updated>
	<author>
		<name>Gustavo de Sá Carvalho Honorato</name>
	</author>
	<content type="html">Hi all,&lt;br&gt;&lt;br&gt;I&amp;#39;m having some problems using Xalan
to make XSLT using JAXP Java API. When xmlns attribute is not present
in root element of the input xml, the output is fine. When xmlns is
present, Xalan is generating an empty output.
Is there any issue regarding this? I&amp;#39;ve been searching all over the
documentation and I could not find anything.&lt;br&gt;&lt;br&gt;Thanks in advance,&lt;br&gt;Gustavo Honorato&lt;br&gt;
&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Xalan---J---Users-f275.html&quot; embed=&quot;fixTarget[275]&quot; target=&quot;_top&quot; &gt;Xalan - J - Users&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/Error-in-output-when-xmlns-attribute-is-present-tp26592425p26592425.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26592410</id>
	<title>Re: How to achieve in xslt equivalent to xs:any in xerces</title>
	<published>2009-12-01T06:11:53Z</published>
	<updated>2009-12-01T06:11:53Z</updated>
	<author>
		<name>keshlam</name>
	</author>
	<content type="html">&lt;tt&gt;&lt;font size=2&gt;&amp;gt; Does that mean Xalan's going 2.0?&lt;/font&gt;&lt;/tt&gt;
&lt;br&gt;
&lt;br&gt;&lt;tt&gt;&lt;font size=2&gt;It means I've been involved with IBM's new XML Feature
Pack for Websphere, which supports the 2.0 versions; hence my carelessly
suggesting a 2.0-only solution.&lt;/font&gt;&lt;/tt&gt;&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Xalan---J---Users-f275.html&quot; embed=&quot;fixTarget[275]&quot; target=&quot;_top&quot; &gt;Xalan - J - Users&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/How-to-achieve-in-xslt-equivalent-to-xs%3Aany-in-xerces-tp26577372p26592410.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26592286</id>
	<title>Re: How to achieve in xslt equivalent to xs:any in xerces</title>
	<published>2009-12-01T06:01:55Z</published>
	<updated>2009-12-01T06:01:55Z</updated>
	<author>
		<name>Michael Ludwig-6</name>
	</author>
	<content type="html">&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26592286&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;keshlam@...&lt;/a&gt; schrieb am 30.11.2009 um 11:46:31 (-0500):
&lt;br&gt;&amp;gt; &amp;gt; Pretty sure XPath 1.0 [1] only allows foo:* wildcards (but not
&lt;br&gt;&amp;gt; &amp;gt; *:foo).
&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; ... Right. Sorry; too much time working on 2.0 recently.
&lt;br&gt;&lt;br&gt;Does that mean Xalan's going 2.0?
&lt;br&gt;&lt;br&gt;-- 
&lt;br&gt;Michael Ludwig
&lt;br&gt;&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Xalan---J---Users-f275.html&quot; embed=&quot;fixTarget[275]&quot; target=&quot;_top&quot; &gt;Xalan - J - Users&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/How-to-achieve-in-xslt-equivalent-to-xs%3Aany-in-xerces-tp26577372p26592286.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26592222</id>
	<title>Re: xml with dots in tags</title>
	<published>2009-12-01T05:58:03Z</published>
	<updated>2009-12-01T05:58:03Z</updated>
	<author>
		<name>Michael Ludwig-6</name>
	</author>
	<content type="html">Marc Ende schrieb am 01.12.2009 um 14:38:39 (+0100):
&lt;div class='shrinkable-quote'&gt;&lt;br&gt;&amp;gt; Hi Michael,
&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; thanks for your help. It seems that the issue doesn't relate to the
&lt;br&gt;&amp;gt; '.'. But I have no further ideas. Can you have a look on this
&lt;br&gt;&amp;gt; stylesheet and the input xml. I thought that the issue that the
&lt;br&gt;&amp;gt; xsd:value-of doesn't provide any data relates to the dots. But now I
&lt;br&gt;&amp;gt; know that's not the case.
&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; Maybe you can give me a hint. I've spend about 8 hours and haven't
&lt;br&gt;&amp;gt; found any point how I can resolve this issue.
&lt;/div&gt;&lt;br&gt;Marc,
&lt;br&gt;&lt;br&gt;please reply to the list, not privately. (I know you did it
&lt;br&gt;inadvertently, as this list does not set the Reply-To header
&lt;br&gt;as it should.)
&lt;br&gt;&lt;br&gt;As to the issue at hand, it is dead simple. Your input is in a
&lt;br&gt;namespace, and your stylesheet doesn't take that into account.
&lt;br&gt;Read up about XML namespaces to save you from further harm and
&lt;br&gt;waste of time. XML namespaces are trivial to understand, but a
&lt;br&gt;bit annoying due to excessive URI verbosity.
&lt;br&gt;&lt;br&gt;&amp;lt;xmeldit.datenlieferung.1100 fassung=&amp;quot;2009-07-31&amp;quot; version=&amp;quot;1.5&amp;quot;
&lt;br&gt;&amp;nbsp; produkt=&amp;quot;OK.EWO&amp;quot; produkthersteller=&amp;quot;AKDB&amp;quot; produktversion=&amp;quot;05.70.10&amp;quot;
&lt;br&gt;&amp;nbsp; xmlns=&amp;quot;&lt;a href=&quot;http://www.osci.de/xmeld15&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://www.osci.de/xmeld15&lt;/a&gt;&amp;quot;
&lt;br&gt;&amp;nbsp; xmlns:xoev=&amp;quot;www.deutschland-online.de/XOEV&amp;quot;
&lt;br&gt;&amp;nbsp; xmlns:xsi=&amp;quot;&lt;a href=&quot;http://www.w3.org/2001/XMLSchema-instance&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://www.w3.org/2001/XMLSchema-instance&lt;/a&gt;&amp;quot;
&lt;br&gt;&amp;nbsp; xsi:schemaLocation=&amp;quot;&lt;a href=&quot;http://www.osci.de/xmeld15&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://www.osci.de/xmeld15&lt;/a&gt;&lt;br&gt;&amp;nbsp; S:\e01entw_eGov\XMELD\XMELD1~1.5\xmeld-nachrichten-xmeldit.xsd&amp;quot;&amp;gt;
&lt;br&gt;&amp;nbsp; [...]
&lt;br&gt;&lt;br&gt;The URI for xoev does not look like a valid URI.
&lt;br&gt;&lt;br&gt;&amp;lt;xsl:transform version=&amp;quot;1.0&amp;quot;
&lt;br&gt;&amp;nbsp; xmlns:xsl=&amp;quot;&lt;a href=&quot;http://www.w3.org/1999/XSL/Transform&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://www.w3.org/1999/XSL/Transform&lt;/a&gt;&amp;quot;&amp;gt;
&lt;br&gt;&amp;nbsp; [...]
&lt;br&gt;&lt;br&gt;Your stylesheet should declare all namespaces that are needed and
&lt;br&gt;use them accordingly.
&lt;br&gt;&lt;br&gt;&amp;lt;xsl:transform version=&amp;quot;1.0&amp;quot;
&lt;br&gt;&amp;nbsp; xmlns=&amp;quot;&lt;a href=&quot;http://www.osci.de/xmeld15&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://www.osci.de/xmeld15&lt;/a&gt;&amp;quot;
&lt;br&gt;&amp;nbsp; xmlns:xsl=&amp;quot;&lt;a href=&quot;http://www.w3.org/1999/XSL/Transform&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://www.w3.org/1999/XSL/Transform&lt;/a&gt;&amp;quot;&amp;gt;
&lt;br&gt;&lt;br&gt;Plus, you *absolutely* need to learn about &amp;quot;push&amp;quot; vs &amp;quot;pull&amp;quot; approach.
&lt;br&gt;You're using the pull approach, which is only suitable for the most
&lt;br&gt;trivial tasks. The one you have looks like a job for a push approach.
&lt;br&gt;The &amp;quot;modified identity template&amp;quot; approach I mentioned is a push
&lt;br&gt;approach.
&lt;br&gt;&lt;br&gt;Good luck,
&lt;br&gt;-- 
&lt;br&gt;Michael Ludwig
&lt;br&gt;&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Xalan---J---Users-f275.html&quot; embed=&quot;fixTarget[275]&quot; target=&quot;_top&quot; &gt;Xalan - J - Users&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/xml-with-dots-in-tags-tp26589080p26592222.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26591616</id>
	<title>Re: xml with dots in tags</title>
	<published>2009-12-01T05:19:42Z</published>
	<updated>2009-12-01T05:19:42Z</updated>
	<author>
		<name>Michael Ludwig-6</name>
	</author>
	<content type="html">Marc Ende schrieb am 01.12.2009 um 10:39:20 (+0100):
&lt;br&gt;&lt;br&gt;&amp;gt; But within the source-xml they've got '.' in the tags. For example:
&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; &amp;lt;root.element&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;lt;test.element&amp;gt;Hello World&amp;lt;/test.element&amp;gt;
&lt;br&gt;&amp;gt; &amp;lt;/root.element&amp;gt;
&lt;br&gt;&lt;br&gt;There's nothing unusual at all with that.
&lt;br&gt;&lt;br&gt;&amp;gt; If I try to access the value with such xslt I got nothing:
&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; &amp;lt;xsl:template match=&amp;quot;/&amp;quot;&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;lt;test&amp;gt;&amp;lt;xsl:value-of select=&amp;quot;root.element/test.element&amp;quot;/&amp;gt;&amp;lt;/test&amp;gt;
&lt;br&gt;&amp;gt; &amp;lt;/xsl:template&amp;gt;
&lt;br&gt;&lt;br&gt;Works fine for me. Did you apply the stylesheet to the correct input?
&lt;br&gt;&lt;br&gt;&amp;gt; I tried to escape the dots in the select with '\.' but that doesn't
&lt;br&gt;&amp;gt; work.
&lt;br&gt;&lt;br&gt;It doesn't because you must not prefix the dot with a backslash. XPath
&lt;br&gt;does not follow the same rules as grep, or the shell, or Perl.
&lt;br&gt;&lt;br&gt;&amp;gt; In XPath there was the . mentioned as a replacement for a character.
&lt;br&gt;&amp;gt; So it should also work on '.' I think.
&lt;br&gt;&lt;br&gt;Don't know what you mean, but &amp;quot;.&amp;quot; is the current context node.
&lt;br&gt;&lt;br&gt;&amp;gt; By the way. Is there any way to 'copy' parts of one xml in the other
&lt;br&gt;&amp;gt; xml within the transformation?
&lt;br&gt;&amp;gt; It would be helpful if there are parts which doesn't need to
&lt;br&gt;&amp;gt; transformed (just copied).
&lt;br&gt;&lt;br&gt;I think you're looking for the standard pattern called &amp;quot;modified
&lt;br&gt;identity transform&amp;quot;. Googling for that will teach you the concept.
&lt;br&gt;It's not difficult and really practical.
&lt;br&gt;&lt;br&gt;Best,
&lt;br&gt;-- 
&lt;br&gt;Michael Ludwig
&lt;br&gt;&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Xalan---J---Users-f275.html&quot; embed=&quot;fixTarget[275]&quot; target=&quot;_top&quot; &gt;Xalan - J - Users&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/xml-with-dots-in-tags-tp26589080p26591616.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26589080</id>
	<title>xml with dots in tags</title>
	<published>2009-12-01T01:39:20Z</published>
	<updated>2009-12-01T01:39:20Z</updated>
	<author>
		<name>m_e</name>
	</author>
	<content type="html">Hi,
&lt;br&gt;&lt;br&gt;since yesterday I've got a project on xslt transformation from one xml 
&lt;br&gt;to another schema.
&lt;br&gt;But within the source-xml they've got '.' in the tags. For example:
&lt;br&gt;&lt;br&gt;&amp;lt;root.element&amp;gt;
&lt;br&gt;&amp;nbsp; &amp;nbsp;&amp;lt;test.element&amp;gt;Hello World&amp;lt;/test.element&amp;gt;
&lt;br&gt;&amp;lt;/root.element&amp;gt;
&lt;br&gt;&lt;br&gt;If I try to access the value with such xslt I got nothing:
&lt;br&gt;&lt;br&gt;&amp;lt;xsl:template match=&amp;quot;/&amp;quot;&amp;gt;
&lt;br&gt;&amp;nbsp; &amp;nbsp;&amp;lt;test&amp;gt;&amp;lt;xsl:value-of select=&amp;quot;root.element/test.element&amp;quot;/&amp;gt;&amp;lt;/test&amp;gt;
&lt;br&gt;&amp;lt;/xsl:template&amp;gt;
&lt;br&gt;&lt;br&gt;It I try it without dot's:
&lt;br&gt;&amp;lt;root&amp;gt;
&lt;br&gt;&amp;lt;test&amp;gt;Hello World&amp;lt;/test&amp;gt;
&lt;br&gt;&amp;lt;/root&amp;gt;
&lt;br&gt;and
&lt;br&gt;&amp;lt;xsl:template match=&amp;quot;/&amp;quot;&amp;gt;
&lt;br&gt;&amp;nbsp; &amp;nbsp;&amp;lt;test&amp;gt;&amp;lt;xsl:value-of select=&amp;quot;root/test&amp;quot;/&amp;gt;&amp;lt;/test&amp;gt;
&lt;br&gt;&amp;lt;/xsl:template&amp;gt;
&lt;br&gt;&lt;br&gt;Everything works fine. I tried to escape the dots in the select with 
&lt;br&gt;'\.' but that doesn't
&lt;br&gt;work. In XPath there was the . mentioned as a replacement for a 
&lt;br&gt;character. So it should
&lt;br&gt;also work on '.' I think.
&lt;br&gt;&lt;br&gt;Does anybody has an idea?
&lt;br&gt;&lt;br&gt;By the way. Is there any way to 'copy' parts of one xml in the other xml 
&lt;br&gt;within the transformation?
&lt;br&gt;It would be helpful if there are parts which doesn't need to transformed 
&lt;br&gt;(just copied).
&lt;br&gt;&lt;br&gt;Thanks for your help!
&lt;br&gt;&lt;br&gt;Marc
&lt;br&gt;&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Xalan---J---Users-f275.html&quot; embed=&quot;fixTarget[275]&quot; target=&quot;_top&quot; &gt;Xalan - J - Users&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/xml-with-dots-in-tags-tp26589080p26589080.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26581235</id>
	<title>[jira] Commented: (XALANJ-2510) Ability to set non tree fragment variable using an extension element (PATCH SUPPLIED)</title>
	<published>2009-11-30T12:22:20Z</published>
	<updated>2009-11-30T12:22:20Z</updated>
	<author>
		<name>Xalan - Dev mailing list</name>
	</author>
	<content type="html">&lt;br&gt;&amp;nbsp; &amp;nbsp; [ &lt;a href=&quot;https://issues.apache.org/jira/browse/XALANJ-2510?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&amp;focusedCommentId=12783833#action_12783833&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://issues.apache.org/jira/browse/XALANJ-2510?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&amp;focusedCommentId=12783833#action_12783833&lt;/a&gt;&amp;nbsp;] 
&lt;br&gt;&lt;br&gt;Adam Jenkins commented on XALANJ-2510:
&lt;br&gt;--------------------------------------
&lt;br&gt;&lt;br&gt;Hi Henry,
&lt;br&gt;&lt;br&gt;Yep, you're correct re xsl:param and xsl:variable. &amp;nbsp;I didn't really consider xsl:with-param or func:result, as I guessed that if people want to do that, they can just create a variable first and pass that to the with-param. &amp;nbsp;I only chose to modify ElemVariable so as to keep my impact on Xalan base minimal.
&lt;br&gt;&lt;br&gt;As for a sample, it depends on the use case and there are a lot of use cases :)
&lt;br&gt;&lt;br&gt;Usually I first test the parent thus:
&lt;br&gt;&lt;br&gt;&amp;nbsp; &amp;nbsp; protected boolean setVariableIfPossible(Object variable, ElemExtensionCall thisElement){
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; if(thisElement.getParentElem() instanceof ElemVariable){
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; ElemVariable varElement = (ElemVariable)thisElement.getParentElem();
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; varElement.overrideChildDocument(new XPath(new XObject(variable)));
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; return true;
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; }
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; return false;
&lt;br&gt;&amp;nbsp; &amp;nbsp; }
&lt;br&gt;&lt;br&gt;if this returns false, the action is different for each extension element. &amp;nbsp;For instance, I have an element that configures a JPA entity manager that is used thus:
&lt;br&gt;&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;xsl:variable name=&amp;quot;entityManager&amp;quot;&amp;gt;
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;jpa:entityManager persistenceUnit=&amp;quot;myPU&amp;quot;&amp;gt;
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;jpa:property name=&amp;quot;flush&amp;quot; value=&amp;quot;true&amp;quot;/&amp;gt;
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&amp;lt;/ejb:entityManager&amp;gt;
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;/xsl:variable&amp;gt;
&lt;br&gt;&lt;br&gt;Now, if that isn't inside a variable element, it sets up a default entityManager for the entire transformation. &amp;nbsp;However, I have another JPA element called query that is used thus:
&lt;br&gt;&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;&amp;lt;xsl:variable name=&amp;quot;customers&amp;quot;&amp;gt;
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;jpa:query name=&amp;quot;customer/name&amp;quot; location=&amp;quot;customer/address/city&amp;quot; type=&amp;quot;customer/@type&amp;quot;&amp;gt;
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;from Customer c where c.name = :name and c.city = :location and c.customerType = :type
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&amp;lt;jpa:query&amp;gt;
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;&amp;lt;xsl:variable&amp;gt;
&lt;br&gt;&lt;br&gt;where the attributes of the extension element are mapped to the named parameters of the JPA query. &amp;nbsp;Now if this element isn't inside a &amp;lt;xsl:variable&amp;gt; element, then the response is output as per standard:
&lt;br&gt;&lt;br&gt;context.outputToResultTree(context.getStylesheet(), queryResults);
&lt;br&gt;&lt;br&gt;I hope those two above give you a bit more of an idea of some of the stuff I'm doing. &amp;nbsp; The entire collection of extension elements/functions is open source at sxe.dev.java.net (though I think it's still going throug approval, so you might have to log in to see it, or ask me for permissions or something, I don't know how it works for pre-approved projects...let me know)....I know the code in there isn't the best, so be kind ;). &amp;nbsp; &amp;nbsp;Also, I know some of the stuff that those extensions allow you to do may not be considered best practice, however sometimes they come in handy :)
&lt;br&gt;&lt;br&gt;In terms of the dynamic scope question, the answer should be addressed above, each of my extension element has a different strategy for when it's not inside a xsl:variable element, and it's up to the users of the library to read the doco and understand the impact on their transformations.
&lt;br&gt;&lt;br&gt;In regards to using an XPath...may not be the best solution, I just tried to keep things as similar to how Xalan was currently doing things as possible so as to minimize my impact on the project :). &amp;nbsp;One of my primary motivations while thinking about how to impliment this was how to keep the impact on Xalan to an absolute minimum, so I chose the shortest path to accomplish my goal :)
&lt;br&gt;&lt;br&gt;I hope the above helps understand the motivation for this change a little more. &amp;nbsp;Feel free to checkout sxe.dev.java.net. &amp;nbsp;I know some of the things it does are considered not exactly best practice (for example, being able to send an email from an XSLT or being able to write to a graph to a parallel binary stream), however it's an optional library, so I expect users of it to understand the pros and cons of breaking some of the XSLT best practices.
&lt;br&gt;&lt;br&gt;I'll submit the license agreement you posted a link to sometime today (for some reason, my ISP blocks apache, so I have to wait until I get to work :) ).
&lt;br&gt;&lt;br&gt;&lt;div class='shrinkable-quote'&gt;&lt;br&gt;&amp;gt; Ability to set non tree fragment variable using an extension element (PATCH SUPPLIED)
&lt;br&gt;&amp;gt; -------------------------------------------------------------------------------------
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Key: XALANJ-2510
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; URL: &lt;a href=&quot;https://issues.apache.org/jira/browse/XALANJ-2510&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://issues.apache.org/jira/browse/XALANJ-2510&lt;/a&gt;&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Project: XalanJ2
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Issue Type: Improvement
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp;Security Level: No security risk; visible to anyone(Ordinary problems in Xalan projects. &amp;nbsp;Anybody can view the issue.) 
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Components: Xalan-extensions
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp;Affects Versions: The Latest Development Code
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Reporter: Adam Jenkins
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Fix For: The Latest Development Code
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Attachments: XALANJ-2510.patch
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; When using extension elements, there is no way to set a non XRTreeFrag related variable.
&lt;br&gt;&amp;gt; For example, say you have:
&lt;br&gt;&amp;gt; &amp;lt;xsl:variable name=&amp;quot;myvar&amp;quot;&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp;&amp;lt;my:extension someAttribute=&amp;quot;somevalue&amp;quot;/&amp;gt;
&lt;br&gt;&amp;gt; &amp;lt;/xsl:variable&amp;gt;
&lt;br&gt;&amp;gt; If my:extension wants to set a tree fragment, string or nodeset into myvar, that's not a problem, however if it wants to set a java object, currently there is no mechanism for that (any java object passed either returned from the method or passed to XSLProcessorContext.outputToResultTree is toString()'ed before being passed back to the ElemVariable.getValue() method).
&lt;br&gt;&amp;gt; The proposed change (patch supplied) is to supply an optional variable on ElemVariable.java whereby child extension elements can call up to their parent and set an XPath to be evaluated after the extension element has finished processing.
&lt;br&gt;&amp;gt; This requires only very minor modification to the ElemVariable.getValue method to check this variable.
&lt;br&gt;&amp;gt; This also ensures that this is optional functionality and will not affect that basic Xalan processing.
&lt;/div&gt;&lt;br&gt;-- 
&lt;br&gt;This message is automatically generated by JIRA.
&lt;br&gt;-
&lt;br&gt;You can reply to this email to add a comment to the issue online.
&lt;br&gt;&lt;br&gt;&lt;br&gt;---------------------------------------------------------------------
&lt;br&gt;To unsubscribe, e-mail: &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26581235&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;xalan-dev-unsubscribe@...&lt;/a&gt;
&lt;br&gt;For additional commands, e-mail: &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26581235&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;xalan-dev-help@...&lt;/a&gt;
&lt;br&gt;&lt;br&gt;&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Xalan---Dev-f274.html&quot; embed=&quot;fixTarget[274]&quot; target=&quot;_top&quot; &gt;Xalan - Dev&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/-jira--Created%3A-%28XALANJ-2510%29-Ability-to-set-non-tree-fragment-variable-using-an-extension-element-%28PATCH-SUPPLIED%29-tp26378213p26581235.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26577799</id>
	<title>Re: How to achieve in xslt equivalent to xs:any in xerces</title>
	<published>2009-11-30T08:46:31Z</published>
	<updated>2009-11-30T08:46:31Z</updated>
	<author>
		<name>keshlam</name>
	</author>
	<content type="html">&lt;tt&gt;&lt;font size=2&gt;&amp;gt; Pretty sure XPath 1.0 [1] only allows foo:* wildcards
(but not *:foo).&lt;/font&gt;&lt;/tt&gt;
&lt;br&gt;
&lt;br&gt;&lt;tt&gt;&lt;font size=2&gt;... Right. Sorry; too much time working on 2.0 recently.&lt;/font&gt;&lt;/tt&gt;
&lt;br&gt;
&lt;br&gt;&lt;tt&gt;&lt;font size=2&gt;The 1.0 equivalent would indeed be &lt;/font&gt;&lt;/tt&gt;
&lt;br&gt;&lt;tt&gt;&lt;font size=2&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; *[localname()=&amp;quot;foo&amp;quot;]&lt;/font&gt;&lt;/tt&gt;
&lt;br&gt;
&lt;br&gt;&lt;tt&gt;&lt;font size=2&gt;And, of course, if you want to ignore the name entirely,
just matching on * will do that.&lt;/font&gt;&lt;/tt&gt;
&lt;br&gt;
&lt;br&gt;&lt;tt&gt;&lt;font size=2&gt;NOTE: Since the namespace is part of the semantics
(meaning) of the document, ignoring it is usually an indicator of bad design
(unless you're working in 2.0 and manipulating schema types rather than
names). Think long and hard about what you're really trying to do and whether
this is the best way to do it.&lt;/font&gt;&lt;/tt&gt;
&lt;br&gt;&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Xalan---J---Users-f275.html&quot; embed=&quot;fixTarget[275]&quot; target=&quot;_top&quot; &gt;Xalan - J - Users&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/How-to-achieve-in-xslt-equivalent-to-xs%3Aany-in-xerces-tp26577372p26577799.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26577697</id>
	<title>Re: How to achieve in xslt equivalent to xs:any in xerces</title>
	<published>2009-11-30T08:37:45Z</published>
	<updated>2009-11-30T08:37:45Z</updated>
	<author>
		<name>Michael Glavassevich-3</name>
	</author>
	<content type="html">&lt;html&gt;&lt;body&gt;
&lt;p&gt;&lt;tt&gt;&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26577697&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;keshlam@...&lt;/a&gt; wrote on 11/30/2009 11:28:36 AM:&lt;br&gt;
&lt;br&gt;
&amp;gt; &amp;gt; As we have xs:any in xerces for any namespace usage , how do I &lt;br&gt;
&amp;gt; &amp;gt; achieve in xslt ? I could not find any construct in xsl as we have &lt;br&gt;
&amp;gt; &amp;gt; in schema language. &lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; XSLT 1.0 and XPath 1.0 are not schema-aware. (That was added in the &lt;br&gt;
&amp;gt; 2.0 version of these, which Xalan does not yet support.) &lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; If you want to match names without looking at the namespace, you can&lt;br&gt;
&amp;gt; use wildcard QNames such as *:foo, or match on a wildcard and then &lt;br&gt;
&amp;gt; qualify that with a predicate.&lt;/tt&gt;&lt;br&gt;
&lt;br&gt;
&lt;tt&gt;I believe that form [1] has only been supported since XPath 2.0. Pretty sure XPath 1.0 [1] only allows foo:* wildcards (but not *:foo).&lt;/tt&gt;&lt;br&gt;
&lt;br&gt;
&lt;tt&gt;Thanks.&lt;/tt&gt;&lt;br&gt;
&lt;br&gt;
&lt;tt&gt;[1] &lt;/tt&gt;&lt;tt&gt;&lt;a href=&quot;http://www.w3.org/TR/xpath20/#prod-xpath-NameTest&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://www.w3.org/TR/xpath20/#prod-xpath-NameTest&lt;/a&gt;&lt;/tt&gt;&lt;br&gt;
&lt;tt&gt;[2] &lt;a href=&quot;http://www.w3.org/TR/xpath#NT-NameTest&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://www.w3.org/TR/xpath#NT-NameTest&lt;/a&gt;&lt;/tt&gt;&lt;br&gt;
&lt;br&gt;
&lt;tt&gt;Michael Glavassevich&lt;br&gt;
XML Parser Development&lt;br&gt;
IBM Toronto Lab&lt;br&gt;
E-mail: &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26577697&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;mrglavas@...&lt;/a&gt;&lt;/tt&gt;&lt;br&gt;
&lt;tt&gt;E-mail: &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26577697&amp;i=2&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;mrglavas@...&lt;/a&gt;&lt;/tt&gt;&lt;/body&gt;&lt;/html&gt;&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Xalan---J---Users-f275.html&quot; embed=&quot;fixTarget[275]&quot; target=&quot;_top&quot; &gt;Xalan - J - Users&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/How-to-achieve-in-xslt-equivalent-to-xs%3Aany-in-xerces-tp26577372p26577697.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26577480</id>
	<title>Re: How to achieve in xslt equivalent to xs:any in xerces</title>
	<published>2009-11-30T08:28:36Z</published>
	<updated>2009-11-30T08:28:36Z</updated>
	<author>
		<name>keshlam</name>
	</author>
	<content type="html">&lt;tt&gt;&lt;font size=2&gt;&amp;gt; As we have xs:any in xerces for any namespace usage
, how do I &lt;br&gt;
&amp;gt; achieve in xslt ? I could not find any construct in xsl as we have
&lt;br&gt;
&amp;gt; in schema language.&lt;/font&gt;&lt;/tt&gt;
&lt;br&gt;
&lt;br&gt;&lt;tt&gt;&lt;font size=2&gt;XSLT 1.0 and XPath 1.0 are not schema-aware. (That
was added in the 2.0 version of these, which Xalan does not yet support.)&lt;/font&gt;&lt;/tt&gt;
&lt;br&gt;
&lt;br&gt;&lt;tt&gt;&lt;font size=2&gt;If you want to match names without looking at the
namespace, you can use wildcard QNames such as *:foo, or match on a wildcard
and then qualify that with a predicate.&lt;/font&gt;&lt;/tt&gt;&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Xalan---J---Users-f275.html&quot; embed=&quot;fixTarget[275]&quot; target=&quot;_top&quot; &gt;Xalan - J - Users&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/How-to-achieve-in-xslt-equivalent-to-xs%3Aany-in-xerces-tp26577372p26577480.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26577372</id>
	<title>How to achieve in xslt equivalent to xs:any in xerces</title>
	<published>2009-11-30T08:19:48Z</published>
	<updated>2009-11-30T08:19:48Z</updated>
	<author>
		<name>ajay bhadauria</name>
	</author>
	<content type="html">Hi all,
&lt;br&gt;&lt;br&gt;As we have xs:any in xerces for any namespace usage , how do I achieve in xslt ? I could not find any construct in xsl as we have in schema language.
&lt;br&gt;&lt;br&gt;Could you please tell me, &amp;nbsp;is there any way we can achieve the same thing like xs:any ??
&lt;br&gt;&lt;br&gt;Regards
&lt;br&gt;Ajay &amp;nbsp;
&lt;br&gt;&lt;br&gt;&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; 
&lt;br&gt;&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Xalan---J---Users-f275.html&quot; embed=&quot;fixTarget[275]&quot; target=&quot;_top&quot; &gt;Xalan - J - Users&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/How-to-achieve-in-xslt-equivalent-to-xs%3Aany-in-xerces-tp26577372p26577372.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26576577</id>
	<title>[jira] Commented: (XALANJ-2510) Ability to set non tree fragment variable using an extension element (PATCH SUPPLIED)</title>
	<published>2009-11-30T07:33:20Z</published>
	<updated>2009-11-30T07:33:20Z</updated>
	<author>
		<name>Xalan - Dev mailing list</name>
	</author>
	<content type="html">&lt;br&gt;&amp;nbsp; &amp;nbsp; [ &lt;a href=&quot;https://issues.apache.org/jira/browse/XALANJ-2510?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&amp;focusedCommentId=12783695#action_12783695&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://issues.apache.org/jira/browse/XALANJ-2510?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&amp;focusedCommentId=12783695#action_12783695&lt;/a&gt;&amp;nbsp;] 
&lt;br&gt;&lt;br&gt;Henry Zongaro commented on XALANJ-2510:
&lt;br&gt;---------------------------------------
&lt;br&gt;&lt;br&gt;Hi, Adam.
&lt;br&gt;&lt;br&gt;Thank you for the contribution.
&lt;br&gt;&lt;br&gt;I've taken a quick look at your patch. &amp;nbsp;One thing I notice immediately is that it applies to xsl:param and xsl:variable, but I expect you would want it to apply to xsl:with-param as well - right? &amp;nbsp;And probably the EXSLT func:result element, too.
&lt;br&gt;&lt;br&gt;I'd also like to understand how this interacts with other features of the language. &amp;nbsp;Without a sample implementation of an extension element like the one you've posited, it's difficult to tell whether this new feature is well-integrated.
&lt;br&gt;&lt;br&gt;For instance, suppose I make the extension element in the content of an xsl:if or xsl:choose to evaluate it conditionally, will that work?
&lt;br&gt;&lt;br&gt;&amp;lt;xsl:variable name=&amp;quot;myvar&amp;quot;&amp;gt;
&lt;br&gt;&amp;nbsp; &amp;nbsp;&amp;lt;xsl:if test=&amp;quot;condition&amp;quot;&amp;gt;
&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;my:extension someAttribute=&amp;quot;somevalue&amp;quot;/&amp;gt;
&lt;br&gt;&amp;nbsp; &amp;nbsp;&amp;lt;/xsl:if&amp;gt;
&lt;br&gt;&amp;lt;/xsl:variable&amp;gt;
&lt;br&gt;&lt;br&gt;The way you've written the patch, it looks like you're expecting this kind of element that needs to return an &amp;quot;override&amp;quot; value to be a child of an xsl:variable/xsl:param. &amp;nbsp;Similarly, what if the extension element is in the dynamic scope of an xsl:variable rather than the static scope - i.e., what if the xsl:variable contains an xsl:call-template, and that named template contains the extension element. &amp;nbsp;How does the override get set on the xsl:variable that contained the call? &amp;nbsp;Again, a sample implementation of such an extension element might have helped to clarify the way the mechanism works.
&lt;br&gt;&lt;br&gt;Finally, I wonder about the way the result is set on the xsl:variable is through this mechanism of supplying an alternative XPath expressions, rather than somehow integrating it as a different result kind.
&lt;br&gt;&lt;br&gt;By the way, it's important that any contribution that's not completely trivial be covered by a contributor's license agreement. &amp;nbsp;That assures the ASF that you have the right to make the contribution. &amp;nbsp;May I suggest that you submit one? &amp;nbsp;You can find it here.[1]
&lt;br&gt;&lt;br&gt;[1] &lt;a href=&quot;http://www.apache.org/licenses/#clas&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://www.apache.org/licenses/#clas&lt;/a&gt;&lt;br&gt;&lt;div class='shrinkable-quote'&gt;&lt;br&gt;&amp;gt; Ability to set non tree fragment variable using an extension element (PATCH SUPPLIED)
&lt;br&gt;&amp;gt; -------------------------------------------------------------------------------------
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Key: XALANJ-2510
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; URL: &lt;a href=&quot;https://issues.apache.org/jira/browse/XALANJ-2510&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://issues.apache.org/jira/browse/XALANJ-2510&lt;/a&gt;&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Project: XalanJ2
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Issue Type: Improvement
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp;Security Level: No security risk; visible to anyone(Ordinary problems in Xalan projects. &amp;nbsp;Anybody can view the issue.) 
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Components: Xalan-extensions
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp;Affects Versions: The Latest Development Code
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Reporter: Adam Jenkins
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Fix For: The Latest Development Code
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Attachments: XALANJ-2510.patch
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; When using extension elements, there is no way to set a non XRTreeFrag related variable.
&lt;br&gt;&amp;gt; For example, say you have:
&lt;br&gt;&amp;gt; &amp;lt;xsl:variable name=&amp;quot;myvar&amp;quot;&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp;&amp;lt;my:extension someAttribute=&amp;quot;somevalue&amp;quot;/&amp;gt;
&lt;br&gt;&amp;gt; &amp;lt;/xsl:variable&amp;gt;
&lt;br&gt;&amp;gt; If my:extension wants to set a tree fragment, string or nodeset into myvar, that's not a problem, however if it wants to set a java object, currently there is no mechanism for that (any java object passed either returned from the method or passed to XSLProcessorContext.outputToResultTree is toString()'ed before being passed back to the ElemVariable.getValue() method).
&lt;br&gt;&amp;gt; The proposed change (patch supplied) is to supply an optional variable on ElemVariable.java whereby child extension elements can call up to their parent and set an XPath to be evaluated after the extension element has finished processing.
&lt;br&gt;&amp;gt; This requires only very minor modification to the ElemVariable.getValue method to check this variable.
&lt;br&gt;&amp;gt; This also ensures that this is optional functionality and will not affect that basic Xalan processing.
&lt;/div&gt;&lt;br&gt;-- 
&lt;br&gt;This message is automatically generated by JIRA.
&lt;br&gt;-
&lt;br&gt;You can reply to this email to add a comment to the issue online.
&lt;br&gt;&lt;br&gt;&lt;br&gt;---------------------------------------------------------------------
&lt;br&gt;To unsubscribe, e-mail: &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26576577&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;xalan-dev-unsubscribe@...&lt;/a&gt;
&lt;br&gt;For additional commands, e-mail: &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26576577&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;xalan-dev-help@...&lt;/a&gt;
&lt;br&gt;&lt;br&gt;&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Xalan---Dev-f274.html&quot; embed=&quot;fixTarget[274]&quot; target=&quot;_top&quot; &gt;Xalan - Dev&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/-jira--Created%3A-%28XALANJ-2510%29-Ability-to-set-non-tree-fragment-variable-using-an-extension-element-%28PATCH-SUPPLIED%29-tp26378213p26576577.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26550618</id>
	<title>[jira] Commented: (XALANJ-2510) Ability to set non tree fragment variable using an extension element (PATCH SUPPLIED)</title>
	<published>2009-11-27T21:22:20Z</published>
	<updated>2009-11-27T21:22:20Z</updated>
	<author>
		<name>Xalan - Dev mailing list</name>
	</author>
	<content type="html">&lt;br&gt;&amp;nbsp; &amp;nbsp; [ &lt;a href=&quot;https://issues.apache.org/jira/browse/XALANJ-2510?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&amp;focusedCommentId=12783208#action_12783208&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://issues.apache.org/jira/browse/XALANJ-2510?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&amp;focusedCommentId=12783208#action_12783208&lt;/a&gt;&amp;nbsp;] 
&lt;br&gt;&lt;br&gt;Adam Jenkins commented on XALANJ-2510:
&lt;br&gt;--------------------------------------
&lt;br&gt;&lt;br&gt;Just a quick check to see where this is at...did you require any further information from me Henry? &amp;nbsp;We're hoping to release our open source extension element/function library the end of next week on dev.java.net, just wondering whether this is likely to be in by then?
&lt;br&gt;&lt;br&gt;Cheers
&lt;br&gt;Adam
&lt;br&gt;&lt;div class='shrinkable-quote'&gt;&lt;br&gt;&amp;gt; Ability to set non tree fragment variable using an extension element (PATCH SUPPLIED)
&lt;br&gt;&amp;gt; -------------------------------------------------------------------------------------
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Key: XALANJ-2510
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; URL: &lt;a href=&quot;https://issues.apache.org/jira/browse/XALANJ-2510&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://issues.apache.org/jira/browse/XALANJ-2510&lt;/a&gt;&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Project: XalanJ2
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Issue Type: Improvement
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp;Security Level: No security risk; visible to anyone(Ordinary problems in Xalan projects. &amp;nbsp;Anybody can view the issue.) 
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Components: Xalan-extensions
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp;Affects Versions: The Latest Development Code
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Reporter: Adam Jenkins
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Fix For: The Latest Development Code
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Attachments: XALANJ-2510.patch
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; When using extension elements, there is no way to set a non XRTreeFrag related variable.
&lt;br&gt;&amp;gt; For example, say you have:
&lt;br&gt;&amp;gt; &amp;lt;xsl:variable name=&amp;quot;myvar&amp;quot;&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp;&amp;lt;my:extension someAttribute=&amp;quot;somevalue&amp;quot;/&amp;gt;
&lt;br&gt;&amp;gt; &amp;lt;/xsl:variable&amp;gt;
&lt;br&gt;&amp;gt; If my:extension wants to set a tree fragment, string or nodeset into myvar, that's not a problem, however if it wants to set a java object, currently there is no mechanism for that (any java object passed either returned from the method or passed to XSLProcessorContext.outputToResultTree is toString()'ed before being passed back to the ElemVariable.getValue() method).
&lt;br&gt;&amp;gt; The proposed change (patch supplied) is to supply an optional variable on ElemVariable.java whereby child extension elements can call up to their parent and set an XPath to be evaluated after the extension element has finished processing.
&lt;br&gt;&amp;gt; This requires only very minor modification to the ElemVariable.getValue method to check this variable.
&lt;br&gt;&amp;gt; This also ensures that this is optional functionality and will not affect that basic Xalan processing.
&lt;/div&gt;&lt;br&gt;-- 
&lt;br&gt;This message is automatically generated by JIRA.
&lt;br&gt;-
&lt;br&gt;You can reply to this email to add a comment to the issue online.
&lt;br&gt;&lt;br&gt;&lt;br&gt;---------------------------------------------------------------------
&lt;br&gt;To unsubscribe, e-mail: &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26550618&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;xalan-dev-unsubscribe@...&lt;/a&gt;
&lt;br&gt;For additional commands, e-mail: &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26550618&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;xalan-dev-help@...&lt;/a&gt;
&lt;br&gt;&lt;br&gt;&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Xalan---Dev-f274.html&quot; embed=&quot;fixTarget[274]&quot; target=&quot;_top&quot; &gt;Xalan - Dev&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/-jira--Created%3A-%28XALANJ-2510%29-Ability-to-set-non-tree-fragment-variable-using-an-extension-element-%28PATCH-SUPPLIED%29-tp26378213p26550618.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26532217</id>
	<title>[jira] Resolved: (XALANJ-2495) Corrections to German error messages</title>
	<published>2009-11-26T08:56:40Z</published>
	<updated>2009-11-26T08:56:40Z</updated>
	<author>
		<name>Xalan - Dev mailing list</name>
	</author>
	<content type="html">&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;[ &lt;a href=&quot;https://issues.apache.org/jira/browse/XALANJ-2495?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://issues.apache.org/jira/browse/XALANJ-2495?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel&lt;/a&gt;&amp;nbsp;]
&lt;br&gt;&lt;br&gt;Henry Zongaro resolved XALANJ-2495.
&lt;br&gt;-----------------------------------
&lt;br&gt;&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Resolution: Fixed
&lt;br&gt;&amp;nbsp; &amp;nbsp; Fix Version/s: The Latest Development Code
&lt;br&gt;&lt;br&gt;Applied Martin's patch to the main trunk of the source code repository.
&lt;br&gt;&lt;div class='shrinkable-quote'&gt;&lt;br&gt;&amp;gt; Corrections to German error messages
&lt;br&gt;&amp;gt; ------------------------------------
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Key: XALANJ-2495
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; URL: &lt;a href=&quot;https://issues.apache.org/jira/browse/XALANJ-2495&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://issues.apache.org/jira/browse/XALANJ-2495&lt;/a&gt;&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Project: XalanJ2
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Issue Type: Bug
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp;Security Level: No security risk; visible to anyone(Ordinary problems in Xalan projects. &amp;nbsp;Anybody can view the issue.) 
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Components: Diagnostic-messages-resources
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp;Affects Versions: The Latest Development Code
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Reporter: Martin von Gagern
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Priority: Trivial
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Fix For: The Latest Development Code
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Attachments: Translation_de.patch
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; I've noticed two translation errors in the German XSLTErrorResources. I'll attach a patch for these. I haven't done a systematic check of translations, and don't know if I ever will, but two fixed messages are better than none imho.
&lt;/div&gt;&lt;br&gt;-- 
&lt;br&gt;This message is automatically generated by JIRA.
&lt;br&gt;-
&lt;br&gt;You can reply to this email to add a comment to the issue online.
&lt;br&gt;&lt;br&gt;&lt;br&gt;---------------------------------------------------------------------
&lt;br&gt;To unsubscribe, e-mail: &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26532217&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;xalan-dev-unsubscribe@...&lt;/a&gt;
&lt;br&gt;For additional commands, e-mail: &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26532217&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;xalan-dev-help@...&lt;/a&gt;
&lt;br&gt;&lt;br&gt;&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Xalan---Dev-f274.html&quot; embed=&quot;fixTarget[274]&quot; target=&quot;_top&quot; &gt;Xalan - Dev&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/-jira--Created%3A-%28XALANJ-2495%29-Corrections-to-German-error-messages-tp23060585p26532217.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26528104</id>
	<title>[jira] Commented: (XALANJ-2490) Class name derived from namespace URI, not xalan:script element</title>
	<published>2009-11-26T03:34:39Z</published>
	<updated>2009-11-26T03:34:39Z</updated>
	<author>
		<name>Xalan - Dev mailing list</name>
	</author>
	<content type="html">&lt;br&gt;&amp;nbsp; &amp;nbsp; [ &lt;a href=&quot;https://issues.apache.org/jira/browse/XALANJ-2490?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&amp;focusedCommentId=12782849#action_12782849&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://issues.apache.org/jira/browse/XALANJ-2490?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&amp;focusedCommentId=12782849#action_12782849&lt;/a&gt;&amp;nbsp;] 
&lt;br&gt;&lt;br&gt;Henry Zongaro commented on XALANJ-2490:
&lt;br&gt;---------------------------------------
&lt;br&gt;&lt;br&gt;Hi, Martin.
&lt;br&gt;Much of the documentation was originally written with the Xalan-J interpreter in mind. &amp;nbsp;XSLTC-specific limitations and differences are described on pages that are specific to XSLTC. &amp;nbsp;In particular, if you check the list at [1] you'll see that XSLTC does not support the xalan:component and xalan:script elements.
&lt;br&gt;&lt;br&gt;Of course, it would be nice if the XSLTC documentation was better integrated into the main Xalan-J documentation, so that differences could be called out in context.
&lt;br&gt;&lt;br&gt;We can either resolve this issue by returning it as &amp;quot;working as designed,&amp;quot; or by changing it to an enhancement request. &amp;nbsp;Which would you prefer?
&lt;br&gt;&lt;br&gt;[1] &lt;a href=&quot;http://xml.apache.org/xalan-j/extensions_xsltc.html#constraints&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://xml.apache.org/xalan-j/extensions_xsltc.html#constraints&lt;/a&gt;&lt;br&gt;&lt;div class='shrinkable-quote'&gt;&lt;br&gt;&amp;gt; Class name derived from namespace URI, not xalan:script element
&lt;br&gt;&amp;gt; ---------------------------------------------------------------
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Key: XALANJ-2490
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; URL: &lt;a href=&quot;https://issues.apache.org/jira/browse/XALANJ-2490&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://issues.apache.org/jira/browse/XALANJ-2490&lt;/a&gt;&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Project: XalanJ2
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Issue Type: Bug
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp;Security Level: No security risk; visible to anyone(Ordinary problems in Xalan projects. &amp;nbsp;Anybody can view the issue.) 
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Components: Xalan-extensions
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp;Affects Versions: The Latest Development Code
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Reporter: Martin von Gagern
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; When implementing extensions in Java, it seems that Xalan (as of SVN revision 752801) uses the namespace url to derive the name of an implementing class, whereas the documentation at &lt;a href=&quot;http://xml.apache.org/xalan-j/extensions.html#setup-script&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://xml.apache.org/xalan-j/extensions.html#setup-script&lt;/a&gt;&amp;nbsp;indicates that the xalan:script subelement of the xalan:component element would be used to bind a namespace to its implementation.
&lt;br&gt;&amp;gt; Before investigating this further, and trying to come up with a fix, I'd like to know which one you consider correct, which one reflects intended behaviour. Do you want to determine class names automagically from its namespace, or do you want to honour the script element when compiling a function call?
&lt;/div&gt;&lt;br&gt;-- 
&lt;br&gt;This message is automatically generated by JIRA.
&lt;br&gt;-
&lt;br&gt;You can reply to this email to add a comment to the issue online.
&lt;br&gt;&lt;br&gt;&lt;br&gt;---------------------------------------------------------------------
&lt;br&gt;To unsubscribe, e-mail: &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26528104&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;xalan-dev-unsubscribe@...&lt;/a&gt;
&lt;br&gt;For additional commands, e-mail: &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26528104&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;xalan-dev-help@...&lt;/a&gt;
&lt;br&gt;&lt;br&gt;&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Xalan---Dev-f274.html&quot; embed=&quot;fixTarget[274]&quot; target=&quot;_top&quot; &gt;Xalan - Dev&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/-jira--Created%3A-%28XALANJ-2490%29-Class-name-derived-from-namespace-URI%2C-not-xalan%3Ascript-element-tp22483255p26528104.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26524296</id>
	<title>[jira] Commented: (XALANJ-2473) DTMNodeProxy.getTextContent() does not return text content of child nodes</title>
	<published>2009-11-25T20:43:40Z</published>
	<updated>2009-11-25T20:43:40Z</updated>
	<author>
		<name>Xalan - Dev mailing list</name>
	</author>
	<content type="html">&lt;br&gt;&amp;nbsp; &amp;nbsp; [ &lt;a href=&quot;https://issues.apache.org/jira/browse/XALANJ-2473?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&amp;focusedCommentId=12782744#action_12782744&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://issues.apache.org/jira/browse/XALANJ-2473?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&amp;focusedCommentId=12782744#action_12782744&lt;/a&gt;&amp;nbsp;] 
&lt;br&gt;&lt;br&gt;Henry Zongaro commented on XALANJ-2473:
&lt;br&gt;---------------------------------------
&lt;br&gt;&lt;br&gt;Hi, Martin. &amp;nbsp;Your patch for this bug report looks correct. &amp;nbsp;However, I would recommend trying to delegate the implementation of getTextContent to the underlying DTM implementation instead of doing a recursive walk that ultimately gets the string value of each text or CData section node and concatenates them all together. &amp;nbsp;If the DTMNodeProxy wraps a node from a SAX2DTM instance, in particular, the implementation can take advantage of the FastStringBuffer that stores the character content of the SAX2DTM implementation. &amp;nbsp;(Take a look at SAX2DTM.getStringValue(int) to understand how that might be much faster.)
&lt;br&gt;&lt;div class='shrinkable-quote'&gt;&lt;br&gt;&amp;gt; DTMNodeProxy.getTextContent() does not return text content of child nodes
&lt;br&gt;&amp;gt; -------------------------------------------------------------------------
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Key: XALANJ-2473
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; URL: &lt;a href=&quot;https://issues.apache.org/jira/browse/XALANJ-2473&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://issues.apache.org/jira/browse/XALANJ-2473&lt;/a&gt;&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Project: XalanJ2
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Issue Type: Bug
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp;Security Level: No security risk; visible to anyone(Ordinary problems in Xalan projects. &amp;nbsp;Anybody can view the issue.) 
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Components: DTM
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp;Affects Versions: 2.7.1
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Environment: Java 1.5
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Reporter: Christian Schröder
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Attachments: XALANJ-2473-getTextContent.patch, XALANJ_2473_Test1.java
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; If a java extension functions takes an org.w3c.dom.Node as an argument then it gets an org.apache.xml.dtm.ref.DTMNodeProxy object.
&lt;br&gt;&amp;gt; The &amp;quot;getTextContent&amp;quot; method of this object returns null if the node is an element node, although according to the java 1.5 documentation, the &amp;quot;getTextContent&amp;quot; method should return the &amp;quot;concatenation of the textContent attribute value of every child node&amp;quot;.
&lt;br&gt;&amp;gt; This is the implementation:
&lt;br&gt;&amp;gt; public String getTextContent() throws DOMException {
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; return getNodeValue(); &amp;nbsp;// overriden in some subclasses
&lt;br&gt;&amp;gt; }
&lt;br&gt;&amp;gt; Of course, &amp;quot;getNodeValue&amp;quot; returns null if the node is an element node, but I think this is not the way &amp;quot;getTextContent&amp;quot; should be implemented.
&lt;br&gt;&amp;gt; The following code can be used to reproduce this error:
&lt;br&gt;&amp;gt; XSLT:
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;lt;xsl:value-of select=&amp;quot;src:myFunction(foo)&amp;quot;/&amp;gt;
&lt;br&gt;&amp;gt; XML:
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;lt;foo&amp;gt;Some Text&amp;lt;/foo&amp;gt;
&lt;br&gt;&amp;gt; Java:
&lt;br&gt;&amp;gt; public static String myFunction(org.w3c.dom.Node n) {
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; String s = n.getTextContent();
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; // s should be &amp;quot;Some Text&amp;quot;, but is actually null.
&lt;br&gt;&amp;gt; }
&lt;/div&gt;&lt;br&gt;-- 
&lt;br&gt;This message is automatically generated by JIRA.
&lt;br&gt;-
&lt;br&gt;You can reply to this email to add a comment to the issue online.
&lt;br&gt;&lt;br&gt;&lt;br&gt;---------------------------------------------------------------------
&lt;br&gt;To unsubscribe, e-mail: &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26524296&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;xalan-dev-unsubscribe@...&lt;/a&gt;
&lt;br&gt;For additional commands, e-mail: &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26524296&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;xalan-dev-help@...&lt;/a&gt;
&lt;br&gt;&lt;br&gt;&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Xalan---Dev-f274.html&quot; embed=&quot;fixTarget[274]&quot; target=&quot;_top&quot; &gt;Xalan - Dev&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/-jira--Created%3A-%28XALANJ-2473%29-DTMNodeProxy.getTextContent%28%29-does-not-return-text-content-of-child-nodes-tp20834961p26524296.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26520999</id>
	<title>[jira] Resolved: (XALANJ-2424) set:distinct() over attribute list breaks XSLTC throwing HIERARCHY_REQUEST_ERR</title>
	<published>2009-11-25T13:58:39Z</published>
	<updated>2009-11-25T13:58:39Z</updated>
	<author>
		<name>Xalan - Dev mailing list</name>
	</author>
	<content type="html">&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;[ &lt;a href=&quot;https://issues.apache.org/jira/browse/XALANJ-2424?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://issues.apache.org/jira/browse/XALANJ-2424?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel&lt;/a&gt;&amp;nbsp;]
&lt;br&gt;&lt;br&gt;Henry Zongaro resolved XALANJ-2424.
&lt;br&gt;-----------------------------------
&lt;br&gt;&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Resolution: Fixed
&lt;br&gt;&amp;nbsp; &amp;nbsp; Fix Version/s: The Latest Development Code
&lt;br&gt;&lt;br&gt;Fixed under JIra XALANJ-2493.
&lt;br&gt;&lt;div class='shrinkable-quote'&gt;&lt;br&gt;&amp;gt; set:distinct() over attribute list breaks XSLTC throwing HIERARCHY_REQUEST_ERR
&lt;br&gt;&amp;gt; ------------------------------------------------------------------------------
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Key: XALANJ-2424
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; URL: &lt;a href=&quot;https://issues.apache.org/jira/browse/XALANJ-2424&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://issues.apache.org/jira/browse/XALANJ-2424&lt;/a&gt;&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Project: XalanJ2
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Issue Type: Bug
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Components: XSLTC
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp;Affects Versions: 2.7.1, 2.7
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Environment: Linux, Sun java 1.6
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Reporter: Илья Казначеев
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Fix For: The Latest Development Code
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Attachments: Process.jad, xml1.xml, xsl1.xsl
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; If you do set:distinct over attribute list, XSLTC-compiled translet throws HIERARCHY_REQUEST_ERR exception.
&lt;br&gt;&amp;gt; Exception is localised to point where set:distinct is called, even if it is assigned into a variable.
&lt;br&gt;&amp;gt; Test case:
&lt;br&gt;&amp;gt; &amp;lt;xsl:stylesheet xmlns:xsl=&amp;quot;&lt;a href=&quot;http://www.w3.org/1999/XSL/Transform&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://www.w3.org/1999/XSL/Transform&lt;/a&gt;&amp;quot; xmlns:set=&amp;quot;&lt;a href=&quot;http://exslt.org/sets&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://exslt.org/sets&lt;/a&gt;&amp;quot; version=&amp;quot;1.0&amp;quot;&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;xsl:output method=&amp;quot;html&amp;quot; /&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;xsl:template match=&amp;quot;/&amp;quot;&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;xsl:variable name=&amp;quot;attrs&amp;quot; select=&amp;quot;set:distinct(source/element/@attr)&amp;quot; /&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;lt;html&amp;gt;&amp;lt;body&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;xsl:for-each select=&amp;quot;$attrs&amp;quot;&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;xsl:value-of select=&amp;quot;.&amp;quot; /&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;/xsl:for-each&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;/body&amp;gt;&amp;lt;/html&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;/xsl:template&amp;gt;
&lt;br&gt;&amp;gt; &amp;lt;/xsl:stylesheet&amp;gt;
&lt;br&gt;&amp;gt; With xml
&lt;br&gt;&amp;gt; &amp;lt;source&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;element attr=&amp;quot;val1&amp;quot; name=&amp;quot;foobar&amp;quot; /&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;element attr=&amp;quot;val2&amp;quot; name=&amp;quot;bar&amp;quot; /&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;element attr=&amp;quot;val2&amp;quot; name=&amp;quot;baz&amp;quot; /&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;element attr=&amp;quot;val3&amp;quot; name=&amp;quot;baz&amp;quot; /&amp;gt;
&lt;br&gt;&amp;gt; &amp;lt;/source&amp;gt;
&lt;br&gt;&amp;gt; that will cause an Exception to be thrown when variable is assigned.
&lt;br&gt;&amp;gt; My unedicated guess is that it tries to apply-templates over selected nodes into document in place where set:distinct is computed. This happens, as I see for different partially-serialized document, before variable's enclosing element is closed. I've disassembled the stylesheet but didn't understand much from there, it goes like this:
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; // &amp;nbsp; 30 &amp;nbsp; 66:invokeinterface #110 &amp;lt;Method org.w3c.dom.NodeList DOM.makeNodeList(DTMAxisIterator)&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; // &amp;nbsp; 31 &amp;nbsp; 71:invokestatic &amp;nbsp; &amp;nbsp;#116 &amp;lt;Method org.w3c.dom.NodeList ExsltSets.distinct(org.w3c.dom.NodeList)&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; // &amp;nbsp; 32 &amp;nbsp; 74:aload_0
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; // &amp;nbsp; 33 &amp;nbsp; 75:aload_1
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; // &amp;nbsp; 34 &amp;nbsp; 76:invokestatic &amp;nbsp; &amp;nbsp;#122 &amp;lt;Method DTMAxisIterator BasisLibrary.nodeList2Iterator(org.w3c.dom.NodeList, org.apache.xalan.xsltc.Translet, DOM)&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; // &amp;nbsp; 35 &amp;nbsp; 79:new &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; #126 &amp;lt;Class CachedNodeListIterator&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; // &amp;nbsp; 36 &amp;nbsp; 82:dup_x1
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; // &amp;nbsp; 37 &amp;nbsp; 83:swap
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; // &amp;nbsp; 38 &amp;nbsp; 84:invokespecial &amp;nbsp; #127 &amp;lt;Method void CachedNodeListIterator(DTMAxisIterator)&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; // &amp;nbsp; 39 &amp;nbsp; 87:iload &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; 4
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; // &amp;nbsp; 40 &amp;nbsp; 89:invokeinterface #41 &amp;nbsp;&amp;lt;Method DTMAxisIterator DTMAxisIterator.setStartNode(int)&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; // &amp;nbsp; 41 &amp;nbsp; 94:astore &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;9
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; // &amp;nbsp; 42 &amp;nbsp; 96:aload_3
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; // &amp;nbsp; 43 &amp;nbsp; 97:ldc1 &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;#129 &amp;lt;String &amp;quot;html&amp;quot;&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; // &amp;nbsp; 44 &amp;nbsp; 99:dup2
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; // &amp;nbsp; 45 &amp;nbsp;100:invokeinterface #14 &amp;nbsp;&amp;lt;Method void SerializationHandler.startElement(String)&amp;gt;
&lt;br&gt;&amp;gt; P.S. If said variable is located in prologue (not inside any xsl:template) the bug persists.
&lt;/div&gt;&lt;br&gt;-- 
&lt;br&gt;This message is automatically generated by JIRA.
&lt;br&gt;-
&lt;br&gt;You can reply to this email to add a comment to the issue online.
&lt;br&gt;&lt;br&gt;&lt;br&gt;---------------------------------------------------------------------
&lt;br&gt;To unsubscribe, e-mail: &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26520999&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;xalan-dev-unsubscribe@...&lt;/a&gt;
&lt;br&gt;For additional commands, e-mail: &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26520999&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;xalan-dev-help@...&lt;/a&gt;
&lt;br&gt;&lt;br&gt;&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Xalan---Dev-f274.html&quot; embed=&quot;fixTarget[274]&quot; target=&quot;_top&quot; &gt;Xalan - Dev&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/-jira--Created%3A-%28XALANJ-2424%29-set%3Adistinct%28%29-over-attribute-list-breaks-XSLTC-throwing-HIERARCHY_REQUEST_ERR-tp15085994p26520999.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26520975</id>
	<title>[jira] Resolved: (XALANJ-2493) BasisLibrary.nodeList2Iterator broken</title>
	<published>2009-11-25T13:56:39Z</published>
	<updated>2009-11-25T13:56:39Z</updated>
	<author>
		<name>Xalan - Dev mailing list</name>
	</author>
	<content type="html">&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp;[ &lt;a href=&quot;https://issues.apache.org/jira/browse/XALANJ-2493?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://issues.apache.org/jira/browse/XALANJ-2493?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel&lt;/a&gt;&amp;nbsp;]
&lt;br&gt;&lt;br&gt;Henry Zongaro resolved XALANJ-2493.
&lt;br&gt;-----------------------------------
&lt;br&gt;&lt;br&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Resolution: Fixed
&lt;br&gt;&amp;nbsp; &amp;nbsp; Fix Version/s: The Latest Development Code
&lt;br&gt;&lt;br&gt;I have reviewed and applied Martin's second patch for this bug report.
&lt;br&gt;&lt;div class='shrinkable-quote'&gt;&lt;br&gt;&amp;gt; BasisLibrary.nodeList2Iterator broken
&lt;br&gt;&amp;gt; -------------------------------------
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Key: XALANJ-2493
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; URL: &lt;a href=&quot;https://issues.apache.org/jira/browse/XALANJ-2493&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://issues.apache.org/jira/browse/XALANJ-2493&lt;/a&gt;&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Project: XalanJ2
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Issue Type: Bug
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp;Security Level: No security risk; visible to anyone(Ordinary problems in Xalan projects. &amp;nbsp;Anybody can view the issue.) 
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Components: XSLTC
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp;Affects Versions: The Latest Development Code
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Reporter: Martin von Gagern
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Fix For: The Latest Development Code
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Attachments: XALANJ-2493_1.patch, XALANJ-2493_2.patch, XALANJ_2493_Test1.java
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; The current implementation of nodeList2Iterator is broken, because it can not deal with attribute nodes. It relies on copyNodes which in turn tries to add attribute nodes as children of some top level node. Attributes don't live on the children axis, though, so this is against DOM and causes a DOM exception in the Xerces DOM implementation and probably most other implementations. The resulting HIERARCHY_REQUEST_ERR was noted e.g. in XALANJ-2424.
&lt;br&gt;&amp;gt; Furthermore, the implementation is inefficient, because it manually copies each and every node from the source document to a new DTM to some new DTM. The time overhead for the copying as well as the memory overhead for the additional DOM can be avoided in cases where the nodes come from some input document, as opposed to a document completely loaded within some extension function.
&lt;br&gt;&amp;gt; A comment in the related XALANJ-2425 suggests returning DTMIterator from extension functions and avoiding the re-import for those. I don't like this idea because it exposes a lot of Xalans internals to extension functions, and because the returned node list might be newly created, while at least some of thenodes might still be from the same document. So instead of special cases for the list type, I implemented special cases for every node of the list. If it is a proxy node of the same (Multi)DOM, we simply use its handle.
&lt;br&gt;&amp;gt; If not, we add it to some w3c DOM and turn that into a DTM, pretty much like the current implementation does. However, I dropped copyNodes in favor of Document.importNode, to avoid code duplication and rely on supposedly more heavily tested code. I also added another level of elements, so that there is one such dummy node for every item of the source list, with always a single child or element. A few assertions help ensure this single child policy. This is especially important in the new implementation, because otherwise it would become difficult to get the proxied nodes and the newly DTMified nodes into correct order.
&lt;br&gt;&amp;gt; Right now, the import of DOM nodes is only implemented for those nodes I expect to turn up in the DTM in pretty much the same form as they do in the w3c DOM. For all other nodes, an internal error is thrown. This especially concerns document fragment nodes. At least in w3c DOM, a document fragment can never be a child, so if DTM behaves the same, we would need to import document fragments seperately, or expand them to the list of their children instead. I'm not sure what correct behaviour would be here, so I'd rather throw an exception than implement wrong behaviour.
&lt;br&gt;&amp;gt; I also noticed that org.apache.xml.dtm.ref.DTMManagerDefault.getDTMHandleFromNode would in theory provide an implementation for turning w3c nodes into DTM handles - exactly what we need here. That method seems to start importing from the topmost ancestor of a node, giving as much context as possible, in contrast to both current and my suggested XSLTC approach, which destroys ancestor references. That method also seems to employ caches in order to avoid importing a document repeatedly. Sadly, actually using that method throws a ClassCastException as it expects a DTM generate from a DOM source to be a DOM2DTM, which SAXImpl is not. A comment inside that method also indicates that future implementations might drop auto-importing and instead leave it to the caller to import a DOM if it hasn't been imported before.
&lt;br&gt;&amp;gt; I left my own attempt at an nodeList2Iterator implementation using getDTMHandleFromNode in place, renamed to nodeList2IteratorUsingHandleFromNode and made private. So it's there, it even gets compiled, but it won't get used. If that method gets fixed in XSLTCDTMManager or its ancestor, then this method might be used instead, giving a much simpler and cleaner implementation. If some of my code would be useful for such an implementation as well, like the check for &amp;quot;is same DOM&amp;quot;, feel free to copy or move my code to those classes as well.
&lt;/div&gt;&lt;br&gt;-- 
&lt;br&gt;This message is automatically generated by JIRA.
&lt;br&gt;-
&lt;br&gt;You can reply to this email to add a comment to the issue online.
&lt;br&gt;&lt;br&gt;&lt;br&gt;---------------------------------------------------------------------
&lt;br&gt;To unsubscribe, e-mail: &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26520975&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;xalan-dev-unsubscribe@...&lt;/a&gt;
&lt;br&gt;For additional commands, e-mail: &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26520975&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;xalan-dev-help@...&lt;/a&gt;
&lt;br&gt;&lt;br&gt;&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Xalan---Dev-f274.html&quot; embed=&quot;fixTarget[274]&quot; target=&quot;_top&quot; &gt;Xalan - Dev&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/-jira--Created%3A-%28XALANJ-2493%29-BasisLibrary.nodeList2Iterator-broken-tp22660445p26520975.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26514373</id>
	<title>[jira] Commented: (XALANJ-2493) BasisLibrary.nodeList2Iterator broken</title>
	<published>2009-11-25T07:10:39Z</published>
	<updated>2009-11-25T07:10:39Z</updated>
	<author>
		<name>Xalan - Dev mailing list</name>
	</author>
	<content type="html">&lt;br&gt;&amp;nbsp; &amp;nbsp; [ &lt;a href=&quot;https://issues.apache.org/jira/browse/XALANJ-2493?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&amp;focusedCommentId=12782460#action_12782460&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://issues.apache.org/jira/browse/XALANJ-2493?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&amp;focusedCommentId=12782460#action_12782460&lt;/a&gt;&amp;nbsp;] 
&lt;br&gt;&lt;br&gt;Henry Zongaro commented on XALANJ-2493:
&lt;br&gt;---------------------------------------
&lt;br&gt;&lt;br&gt;Right. &amp;nbsp;I've always done my Xalan-J builds and test runs using JDK 1.3.x, to ensure I don't let any 1.4 or later features creep in.
&lt;br&gt;&lt;br&gt;There's an InternalError class in the org.apache.xalan.xsltc.compiler.util package that's intended to be used for situations where the compiler has found itself in some internally inconsistent state. &amp;nbsp;Traditionally we've avoided introducing dependencies on the compiler packages in the XSLTC run-time packages - just to allow for the possibility of building a smaller XSLTC run-time, though that hasn't been done recently. &amp;nbsp;So I would suggest introducing an InternalRuntimeError class in org.apache.xalan.xsltc.runtime instead of using AssertionError.
&lt;br&gt;&lt;div class='shrinkable-quote'&gt;&lt;br&gt;&amp;gt; BasisLibrary.nodeList2Iterator broken
&lt;br&gt;&amp;gt; -------------------------------------
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Key: XALANJ-2493
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; URL: &lt;a href=&quot;https://issues.apache.org/jira/browse/XALANJ-2493&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://issues.apache.org/jira/browse/XALANJ-2493&lt;/a&gt;&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Project: XalanJ2
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Issue Type: Bug
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp;Security Level: No security risk; visible to anyone(Ordinary problems in Xalan projects. &amp;nbsp;Anybody can view the issue.) 
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Components: XSLTC
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp;Affects Versions: The Latest Development Code
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Reporter: Martin von Gagern
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Attachments: XALANJ-2493_1.patch, XALANJ_2493_Test1.java
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; The current implementation of nodeList2Iterator is broken, because it can not deal with attribute nodes. It relies on copyNodes which in turn tries to add attribute nodes as children of some top level node. Attributes don't live on the children axis, though, so this is against DOM and causes a DOM exception in the Xerces DOM implementation and probably most other implementations. The resulting HIERARCHY_REQUEST_ERR was noted e.g. in XALANJ-2424.
&lt;br&gt;&amp;gt; Furthermore, the implementation is inefficient, because it manually copies each and every node from the source document to a new DTM to some new DTM. The time overhead for the copying as well as the memory overhead for the additional DOM can be avoided in cases where the nodes come from some input document, as opposed to a document completely loaded within some extension function.
&lt;br&gt;&amp;gt; A comment in the related XALANJ-2425 suggests returning DTMIterator from extension functions and avoiding the re-import for those. I don't like this idea because it exposes a lot of Xalans internals to extension functions, and because the returned node list might be newly created, while at least some of thenodes might still be from the same document. So instead of special cases for the list type, I implemented special cases for every node of the list. If it is a proxy node of the same (Multi)DOM, we simply use its handle.
&lt;br&gt;&amp;gt; If not, we add it to some w3c DOM and turn that into a DTM, pretty much like the current implementation does. However, I dropped copyNodes in favor of Document.importNode, to avoid code duplication and rely on supposedly more heavily tested code. I also added another level of elements, so that there is one such dummy node for every item of the source list, with always a single child or element. A few assertions help ensure this single child policy. This is especially important in the new implementation, because otherwise it would become difficult to get the proxied nodes and the newly DTMified nodes into correct order.
&lt;br&gt;&amp;gt; Right now, the import of DOM nodes is only implemented for those nodes I expect to turn up in the DTM in pretty much the same form as they do in the w3c DOM. For all other nodes, an internal error is thrown. This especially concerns document fragment nodes. At least in w3c DOM, a document fragment can never be a child, so if DTM behaves the same, we would need to import document fragments seperately, or expand them to the list of their children instead. I'm not sure what correct behaviour would be here, so I'd rather throw an exception than implement wrong behaviour.
&lt;br&gt;&amp;gt; I also noticed that org.apache.xml.dtm.ref.DTMManagerDefault.getDTMHandleFromNode would in theory provide an implementation for turning w3c nodes into DTM handles - exactly what we need here. That method seems to start importing from the topmost ancestor of a node, giving as much context as possible, in contrast to both current and my suggested XSLTC approach, which destroys ancestor references. That method also seems to employ caches in order to avoid importing a document repeatedly. Sadly, actually using that method throws a ClassCastException as it expects a DTM generate from a DOM source to be a DOM2DTM, which SAXImpl is not. A comment inside that method also indicates that future implementations might drop auto-importing and instead leave it to the caller to import a DOM if it hasn't been imported before.
&lt;br&gt;&amp;gt; I left my own attempt at an nodeList2Iterator implementation using getDTMHandleFromNode in place, renamed to nodeList2IteratorUsingHandleFromNode and made private. So it's there, it even gets compiled, but it won't get used. If that method gets fixed in XSLTCDTMManager or its ancestor, then this method might be used instead, giving a much simpler and cleaner implementation. If some of my code would be useful for such an implementation as well, like the check for &amp;quot;is same DOM&amp;quot;, feel free to copy or move my code to those classes as well.
&lt;/div&gt;&lt;br&gt;-- 
&lt;br&gt;This message is automatically generated by JIRA.
&lt;br&gt;-
&lt;br&gt;You can reply to this email to add a comment to the issue online.
&lt;br&gt;&lt;br&gt;&lt;br&gt;---------------------------------------------------------------------
&lt;br&gt;To unsubscribe, e-mail: &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26514373&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;xalan-dev-unsubscribe@...&lt;/a&gt;
&lt;br&gt;For additional commands, e-mail: &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26514373&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;xalan-dev-help@...&lt;/a&gt;
&lt;br&gt;&lt;br&gt;&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Xalan---Dev-f274.html&quot; embed=&quot;fixTarget[274]&quot; target=&quot;_top&quot; &gt;Xalan - Dev&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/-jira--Created%3A-%28XALANJ-2493%29-BasisLibrary.nodeList2Iterator-broken-tp22660445p26514373.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26505411</id>
	<title>[jira] Commented: (XALANJ-2493) BasisLibrary.nodeList2Iterator broken</title>
	<published>2009-11-24T15:55:40Z</published>
	<updated>2009-11-24T15:55:40Z</updated>
	<author>
		<name>Xalan - Dev mailing list</name>
	</author>
	<content type="html">&lt;br&gt;&amp;nbsp; &amp;nbsp; [ &lt;a href=&quot;https://issues.apache.org/jira/browse/XALANJ-2493?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&amp;focusedCommentId=12782251#action_12782251&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://issues.apache.org/jira/browse/XALANJ-2493?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&amp;focusedCommentId=12782251#action_12782251&lt;/a&gt;&amp;nbsp;] 
&lt;br&gt;&lt;br&gt;Michael Glavassevich commented on XALANJ-2493:
&lt;br&gt;----------------------------------------------
&lt;br&gt;&lt;br&gt;Probably not a good idea to start introducing dependencies on higher JDKs without discussing with the community. &amp;nbsp;Xerces is also still on JDK 1.3 (because we have users who are still on that level; probably some of them use Xalan too) and relies on Xalan's serializer also being at that level.
&lt;br&gt;&lt;div class='shrinkable-quote'&gt;&lt;br&gt;&amp;gt; BasisLibrary.nodeList2Iterator broken
&lt;br&gt;&amp;gt; -------------------------------------
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Key: XALANJ-2493
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; URL: &lt;a href=&quot;https://issues.apache.org/jira/browse/XALANJ-2493&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://issues.apache.org/jira/browse/XALANJ-2493&lt;/a&gt;&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Project: XalanJ2
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Issue Type: Bug
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp;Security Level: No security risk; visible to anyone(Ordinary problems in Xalan projects. &amp;nbsp;Anybody can view the issue.) 
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Components: XSLTC
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp;Affects Versions: The Latest Development Code
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Reporter: Martin von Gagern
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Attachments: XALANJ-2493_1.patch, XALANJ_2493_Test1.java
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; The current implementation of nodeList2Iterator is broken, because it can not deal with attribute nodes. It relies on copyNodes which in turn tries to add attribute nodes as children of some top level node. Attributes don't live on the children axis, though, so this is against DOM and causes a DOM exception in the Xerces DOM implementation and probably most other implementations. The resulting HIERARCHY_REQUEST_ERR was noted e.g. in XALANJ-2424.
&lt;br&gt;&amp;gt; Furthermore, the implementation is inefficient, because it manually copies each and every node from the source document to a new DTM to some new DTM. The time overhead for the copying as well as the memory overhead for the additional DOM can be avoided in cases where the nodes come from some input document, as opposed to a document completely loaded within some extension function.
&lt;br&gt;&amp;gt; A comment in the related XALANJ-2425 suggests returning DTMIterator from extension functions and avoiding the re-import for those. I don't like this idea because it exposes a lot of Xalans internals to extension functions, and because the returned node list might be newly created, while at least some of thenodes might still be from the same document. So instead of special cases for the list type, I implemented special cases for every node of the list. If it is a proxy node of the same (Multi)DOM, we simply use its handle.
&lt;br&gt;&amp;gt; If not, we add it to some w3c DOM and turn that into a DTM, pretty much like the current implementation does. However, I dropped copyNodes in favor of Document.importNode, to avoid code duplication and rely on supposedly more heavily tested code. I also added another level of elements, so that there is one such dummy node for every item of the source list, with always a single child or element. A few assertions help ensure this single child policy. This is especially important in the new implementation, because otherwise it would become difficult to get the proxied nodes and the newly DTMified nodes into correct order.
&lt;br&gt;&amp;gt; Right now, the import of DOM nodes is only implemented for those nodes I expect to turn up in the DTM in pretty much the same form as they do in the w3c DOM. For all other nodes, an internal error is thrown. This especially concerns document fragment nodes. At least in w3c DOM, a document fragment can never be a child, so if DTM behaves the same, we would need to import document fragments seperately, or expand them to the list of their children instead. I'm not sure what correct behaviour would be here, so I'd rather throw an exception than implement wrong behaviour.
&lt;br&gt;&amp;gt; I also noticed that org.apache.xml.dtm.ref.DTMManagerDefault.getDTMHandleFromNode would in theory provide an implementation for turning w3c nodes into DTM handles - exactly what we need here. That method seems to start importing from the topmost ancestor of a node, giving as much context as possible, in contrast to both current and my suggested XSLTC approach, which destroys ancestor references. That method also seems to employ caches in order to avoid importing a document repeatedly. Sadly, actually using that method throws a ClassCastException as it expects a DTM generate from a DOM source to be a DOM2DTM, which SAXImpl is not. A comment inside that method also indicates that future implementations might drop auto-importing and instead leave it to the caller to import a DOM if it hasn't been imported before.
&lt;br&gt;&amp;gt; I left my own attempt at an nodeList2Iterator implementation using getDTMHandleFromNode in place, renamed to nodeList2IteratorUsingHandleFromNode and made private. So it's there, it even gets compiled, but it won't get used. If that method gets fixed in XSLTCDTMManager or its ancestor, then this method might be used instead, giving a much simpler and cleaner implementation. If some of my code would be useful for such an implementation as well, like the check for &amp;quot;is same DOM&amp;quot;, feel free to copy or move my code to those classes as well.
&lt;/div&gt;&lt;br&gt;-- 
&lt;br&gt;This message is automatically generated by JIRA.
&lt;br&gt;-
&lt;br&gt;You can reply to this email to add a comment to the issue online.
&lt;br&gt;&lt;br&gt;&lt;br&gt;---------------------------------------------------------------------
&lt;br&gt;To unsubscribe, e-mail: &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26505411&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;xalan-dev-unsubscribe@...&lt;/a&gt;
&lt;br&gt;For additional commands, e-mail: &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26505411&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;xalan-dev-help@...&lt;/a&gt;
&lt;br&gt;&lt;br&gt;&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Xalan---Dev-f274.html&quot; embed=&quot;fixTarget[274]&quot; target=&quot;_top&quot; &gt;Xalan - Dev&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/-jira--Created%3A-%28XALANJ-2493%29-BasisLibrary.nodeList2Iterator-broken-tp22660445p26505411.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26504648</id>
	<title>[jira] Commented: (XALANJ-2493) BasisLibrary.nodeList2Iterator broken</title>
	<published>2009-11-24T14:47:39Z</published>
	<updated>2009-11-24T14:47:39Z</updated>
	<author>
		<name>Xalan - Dev mailing list</name>
	</author>
	<content type="html">&lt;br&gt;&amp;nbsp; &amp;nbsp; [ &lt;a href=&quot;https://issues.apache.org/jira/browse/XALANJ-2493?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&amp;focusedCommentId=12782216#action_12782216&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://issues.apache.org/jira/browse/XALANJ-2493?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&amp;focusedCommentId=12782216#action_12782216&lt;/a&gt;&amp;nbsp;] 
&lt;br&gt;&lt;br&gt;Martin von Gagern commented on XALANJ-2493:
&lt;br&gt;-------------------------------------------
&lt;br&gt;&lt;br&gt;It's a language feature: &lt;a href=&quot;http://java.sun.com/j2se/1.4.2/docs/api/java/lang/AssertionError.html&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://java.sun.com/j2se/1.4.2/docs/api/java/lang/AssertionError.html&lt;/a&gt;&lt;br&gt;&lt;br&gt;I just realized that this is &amp;quot;fairly new&amp;quot;, added in JDK 1.4, while Xalan according to its FAQ seems to still support 1.3. So I guess I'll have to rewrite my patch, either without assertions or with some other class for their errors.
&lt;br&gt;&lt;div class='shrinkable-quote'&gt;&lt;br&gt;&amp;gt; BasisLibrary.nodeList2Iterator broken
&lt;br&gt;&amp;gt; -------------------------------------
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Key: XALANJ-2493
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; URL: &lt;a href=&quot;https://issues.apache.org/jira/browse/XALANJ-2493&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://issues.apache.org/jira/browse/XALANJ-2493&lt;/a&gt;&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Project: XalanJ2
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Issue Type: Bug
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp;Security Level: No security risk; visible to anyone(Ordinary problems in Xalan projects. &amp;nbsp;Anybody can view the issue.) 
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Components: XSLTC
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp;Affects Versions: The Latest Development Code
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Reporter: Martin von Gagern
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Attachments: XALANJ-2493_1.patch, XALANJ_2493_Test1.java
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; The current implementation of nodeList2Iterator is broken, because it can not deal with attribute nodes. It relies on copyNodes which in turn tries to add attribute nodes as children of some top level node. Attributes don't live on the children axis, though, so this is against DOM and causes a DOM exception in the Xerces DOM implementation and probably most other implementations. The resulting HIERARCHY_REQUEST_ERR was noted e.g. in XALANJ-2424.
&lt;br&gt;&amp;gt; Furthermore, the implementation is inefficient, because it manually copies each and every node from the source document to a new DTM to some new DTM. The time overhead for the copying as well as the memory overhead for the additional DOM can be avoided in cases where the nodes come from some input document, as opposed to a document completely loaded within some extension function.
&lt;br&gt;&amp;gt; A comment in the related XALANJ-2425 suggests returning DTMIterator from extension functions and avoiding the re-import for those. I don't like this idea because it exposes a lot of Xalans internals to extension functions, and because the returned node list might be newly created, while at least some of thenodes might still be from the same document. So instead of special cases for the list type, I implemented special cases for every node of the list. If it is a proxy node of the same (Multi)DOM, we simply use its handle.
&lt;br&gt;&amp;gt; If not, we add it to some w3c DOM and turn that into a DTM, pretty much like the current implementation does. However, I dropped copyNodes in favor of Document.importNode, to avoid code duplication and rely on supposedly more heavily tested code. I also added another level of elements, so that there is one such dummy node for every item of the source list, with always a single child or element. A few assertions help ensure this single child policy. This is especially important in the new implementation, because otherwise it would become difficult to get the proxied nodes and the newly DTMified nodes into correct order.
&lt;br&gt;&amp;gt; Right now, the import of DOM nodes is only implemented for those nodes I expect to turn up in the DTM in pretty much the same form as they do in the w3c DOM. For all other nodes, an internal error is thrown. This especially concerns document fragment nodes. At least in w3c DOM, a document fragment can never be a child, so if DTM behaves the same, we would need to import document fragments seperately, or expand them to the list of their children instead. I'm not sure what correct behaviour would be here, so I'd rather throw an exception than implement wrong behaviour.
&lt;br&gt;&amp;gt; I also noticed that org.apache.xml.dtm.ref.DTMManagerDefault.getDTMHandleFromNode would in theory provide an implementation for turning w3c nodes into DTM handles - exactly what we need here. That method seems to start importing from the topmost ancestor of a node, giving as much context as possible, in contrast to both current and my suggested XSLTC approach, which destroys ancestor references. That method also seems to employ caches in order to avoid importing a document repeatedly. Sadly, actually using that method throws a ClassCastException as it expects a DTM generate from a DOM source to be a DOM2DTM, which SAXImpl is not. A comment inside that method also indicates that future implementations might drop auto-importing and instead leave it to the caller to import a DOM if it hasn't been imported before.
&lt;br&gt;&amp;gt; I left my own attempt at an nodeList2Iterator implementation using getDTMHandleFromNode in place, renamed to nodeList2IteratorUsingHandleFromNode and made private. So it's there, it even gets compiled, but it won't get used. If that method gets fixed in XSLTCDTMManager or its ancestor, then this method might be used instead, giving a much simpler and cleaner implementation. If some of my code would be useful for such an implementation as well, like the check for &amp;quot;is same DOM&amp;quot;, feel free to copy or move my code to those classes as well.
&lt;/div&gt;&lt;br&gt;-- 
&lt;br&gt;This message is automatically generated by JIRA.
&lt;br&gt;-
&lt;br&gt;You can reply to this email to add a comment to the issue online.
&lt;br&gt;&lt;br&gt;&lt;br&gt;---------------------------------------------------------------------
&lt;br&gt;To unsubscribe, e-mail: &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26504648&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;xalan-dev-unsubscribe@...&lt;/a&gt;
&lt;br&gt;For additional commands, e-mail: &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26504648&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;xalan-dev-help@...&lt;/a&gt;
&lt;br&gt;&lt;br&gt;&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Xalan---Dev-f274.html&quot; embed=&quot;fixTarget[274]&quot; target=&quot;_top&quot; &gt;Xalan - Dev&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/-jira--Created%3A-%28XALANJ-2493%29-BasisLibrary.nodeList2Iterator-broken-tp22660445p26504648.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26503703</id>
	<title>[jira] Commented: (XALANJ-2493) BasisLibrary.nodeList2Iterator broken</title>
	<published>2009-11-24T13:36:39Z</published>
	<updated>2009-11-24T13:36:39Z</updated>
	<author>
		<name>Xalan - Dev mailing list</name>
	</author>
	<content type="html">&lt;br&gt;&amp;nbsp; &amp;nbsp; [ &lt;a href=&quot;https://issues.apache.org/jira/browse/XALANJ-2493?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&amp;focusedCommentId=12782185#action_12782185&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://issues.apache.org/jira/browse/XALANJ-2493?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&amp;focusedCommentId=12782185#action_12782185&lt;/a&gt;&amp;nbsp;] 
&lt;br&gt;&lt;br&gt;Henry Zongaro commented on XALANJ-2493:
&lt;br&gt;---------------------------------------
&lt;br&gt;&lt;br&gt;Hi, Martin.
&lt;br&gt;I was just trying out your patch and was tripped up by the references to an AssertionError constructor. &amp;nbsp;Where is that class defined?
&lt;br&gt;&lt;div class='shrinkable-quote'&gt;&lt;br&gt;&amp;gt; BasisLibrary.nodeList2Iterator broken
&lt;br&gt;&amp;gt; -------------------------------------
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Key: XALANJ-2493
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; URL: &lt;a href=&quot;https://issues.apache.org/jira/browse/XALANJ-2493&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://issues.apache.org/jira/browse/XALANJ-2493&lt;/a&gt;&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Project: XalanJ2
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Issue Type: Bug
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp;Security Level: No security risk; visible to anyone(Ordinary problems in Xalan projects. &amp;nbsp;Anybody can view the issue.) 
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Components: XSLTC
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp;Affects Versions: The Latest Development Code
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Reporter: Martin von Gagern
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Attachments: XALANJ-2493_1.patch, XALANJ_2493_Test1.java
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; The current implementation of nodeList2Iterator is broken, because it can not deal with attribute nodes. It relies on copyNodes which in turn tries to add attribute nodes as children of some top level node. Attributes don't live on the children axis, though, so this is against DOM and causes a DOM exception in the Xerces DOM implementation and probably most other implementations. The resulting HIERARCHY_REQUEST_ERR was noted e.g. in XALANJ-2424.
&lt;br&gt;&amp;gt; Furthermore, the implementation is inefficient, because it manually copies each and every node from the source document to a new DTM to some new DTM. The time overhead for the copying as well as the memory overhead for the additional DOM can be avoided in cases where the nodes come from some input document, as opposed to a document completely loaded within some extension function.
&lt;br&gt;&amp;gt; A comment in the related XALANJ-2425 suggests returning DTMIterator from extension functions and avoiding the re-import for those. I don't like this idea because it exposes a lot of Xalans internals to extension functions, and because the returned node list might be newly created, while at least some of thenodes might still be from the same document. So instead of special cases for the list type, I implemented special cases for every node of the list. If it is a proxy node of the same (Multi)DOM, we simply use its handle.
&lt;br&gt;&amp;gt; If not, we add it to some w3c DOM and turn that into a DTM, pretty much like the current implementation does. However, I dropped copyNodes in favor of Document.importNode, to avoid code duplication and rely on supposedly more heavily tested code. I also added another level of elements, so that there is one such dummy node for every item of the source list, with always a single child or element. A few assertions help ensure this single child policy. This is especially important in the new implementation, because otherwise it would become difficult to get the proxied nodes and the newly DTMified nodes into correct order.
&lt;br&gt;&amp;gt; Right now, the import of DOM nodes is only implemented for those nodes I expect to turn up in the DTM in pretty much the same form as they do in the w3c DOM. For all other nodes, an internal error is thrown. This especially concerns document fragment nodes. At least in w3c DOM, a document fragment can never be a child, so if DTM behaves the same, we would need to import document fragments seperately, or expand them to the list of their children instead. I'm not sure what correct behaviour would be here, so I'd rather throw an exception than implement wrong behaviour.
&lt;br&gt;&amp;gt; I also noticed that org.apache.xml.dtm.ref.DTMManagerDefault.getDTMHandleFromNode would in theory provide an implementation for turning w3c nodes into DTM handles - exactly what we need here. That method seems to start importing from the topmost ancestor of a node, giving as much context as possible, in contrast to both current and my suggested XSLTC approach, which destroys ancestor references. That method also seems to employ caches in order to avoid importing a document repeatedly. Sadly, actually using that method throws a ClassCastException as it expects a DTM generate from a DOM source to be a DOM2DTM, which SAXImpl is not. A comment inside that method also indicates that future implementations might drop auto-importing and instead leave it to the caller to import a DOM if it hasn't been imported before.
&lt;br&gt;&amp;gt; I left my own attempt at an nodeList2Iterator implementation using getDTMHandleFromNode in place, renamed to nodeList2IteratorUsingHandleFromNode and made private. So it's there, it even gets compiled, but it won't get used. If that method gets fixed in XSLTCDTMManager or its ancestor, then this method might be used instead, giving a much simpler and cleaner implementation. If some of my code would be useful for such an implementation as well, like the check for &amp;quot;is same DOM&amp;quot;, feel free to copy or move my code to those classes as well.
&lt;/div&gt;&lt;br&gt;-- 
&lt;br&gt;This message is automatically generated by JIRA.
&lt;br&gt;-
&lt;br&gt;You can reply to this email to add a comment to the issue online.
&lt;br&gt;&lt;br&gt;&lt;br&gt;---------------------------------------------------------------------
&lt;br&gt;To unsubscribe, e-mail: &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26503703&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;xalan-dev-unsubscribe@...&lt;/a&gt;
&lt;br&gt;For additional commands, e-mail: &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26503703&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;xalan-dev-help@...&lt;/a&gt;
&lt;br&gt;&lt;br&gt;&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Xalan---Dev-f274.html&quot; embed=&quot;fixTarget[274]&quot; target=&quot;_top&quot; &gt;Xalan - Dev&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/-jira--Created%3A-%28XALANJ-2493%29-BasisLibrary.nodeList2Iterator-broken-tp22660445p26503703.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26503335</id>
	<title>Re: Xalan J Future</title>
	<published>2009-11-24T13:09:10Z</published>
	<updated>2009-11-24T13:09:10Z</updated>
	<author>
		<name>Martin von Gagern</name>
	</author>
	<content type="html">Hello Henry!
&lt;br&gt;&lt;br&gt;Henry Zongaro wrote:
&lt;br&gt;&amp;gt; Coincidentally, I was just getting myself set up to spend some time
&lt;br&gt;&amp;gt; reviewing some of your patches as I'd promised. &amp;nbsp;If those look good, I
&lt;br&gt;&amp;gt; wouldn't see any impediment to nominating you for committer status.
&lt;br&gt;&lt;br&gt;Have you found any time yet? You will keep those reviews in mind, right?
&lt;br&gt;&lt;br&gt;Greetings,
&lt;br&gt;&amp;nbsp;Martin
&lt;br&gt;&lt;br&gt;&lt;br /&gt; &lt;div class=&quot;small&quot;&gt;&lt;br/&gt;&lt;img src=&quot;http://old.nabble.com/images/icon_attachment.gif&quot; &gt; &lt;strong&gt;signature.asc&lt;/strong&gt; (270 bytes) &lt;a href=&quot;http://old.nabble.com/attachment/26503335/0/signature.asc&quot; target=&quot;_top&quot;&gt;Download Attachment&lt;/a&gt;&lt;/div&gt;&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Xalan---Dev-f274.html&quot; embed=&quot;fixTarget[274]&quot; target=&quot;_top&quot; &gt;Xalan - Dev&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/Xalan-J-Future---Summary-tp26289860p26503335.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26488647</id>
	<title>Re: fo:external-graphic and xml:base</title>
	<published>2009-11-23T16:33:16Z</published>
	<updated>2009-11-23T16:33:16Z</updated>
	<author>
		<name>Michael Ludwig-6</name>
	</author>
	<content type="html">Nathan Nadeau schrieb am 23.11.2009 um 18:12:01 (-0500):
&lt;div class='shrinkable-quote'&gt;&lt;br&gt;&amp;gt; The source of the problem is that FOP is mistakenly calculating the
&lt;br&gt;&amp;gt; base-URI for the images. The purpose of xml:base is to rectify
&lt;br&gt;&amp;gt; situations like this, but it seems that FOP does not know what to do
&lt;br&gt;&amp;gt; with xml:base. For you, it's reporting xml:base as an invalid
&lt;br&gt;&amp;gt; attribute of the fo:block element. For me, it just ignores xml:base
&lt;br&gt;&amp;gt; and continues (of course still incorrectly resolving the image URIs).
&lt;br&gt;&amp;gt; 
&lt;br&gt;&amp;gt; First thing I would verify is that your XSLT and/or XSL-FO files are
&lt;br&gt;&amp;gt; aware of the &amp;quot;xml&amp;quot; namespace. I tried this first on my setup, but it
&lt;br&gt;&amp;gt; did not help. Maybe it will help you?
&lt;/div&gt;&lt;br&gt;Can't help with FOP, but as for the &amp;quot;xml&amp;quot; namespace, it does not need to
&lt;br&gt;be declared as it is by default.
&lt;br&gt;&lt;br&gt;&lt;a href=&quot;http://www.w3.org/TR/xml-names/#ns-decl&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://www.w3.org/TR/xml-names/#ns-decl&lt;/a&gt;&lt;br&gt;&lt;br&gt;&amp;nbsp; Namespace constraint: Reserved Prefixes and Namespace Names
&lt;br&gt;&lt;br&gt;&amp;nbsp; The prefix xml is by definition bound to the namespace name
&lt;br&gt;&amp;nbsp; &lt;a href=&quot;http://www.w3.org/XML/1998/namespace&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://www.w3.org/XML/1998/namespace&lt;/a&gt;. It MAY, but need not,
&lt;br&gt;&amp;nbsp; be declared, and MUST NOT be bound to any other namespace
&lt;br&gt;&amp;nbsp; name. Other prefixes MUST NOT be bound to this namespace
&lt;br&gt;&amp;nbsp; name, and it MUST NOT be declared as the default namespace.
&lt;br&gt;&lt;br&gt;Note that the notion of *files* being &amp;quot;aware&amp;quot; of the &amp;quot;xml&amp;quot; namespace is
&lt;br&gt;misleading. A *parser* implementing namespaces is required to have a
&lt;br&gt;binding for &amp;quot;xml&amp;quot; to the appropriate namespace.
&lt;br&gt;&lt;br&gt;Next, there needs to be support for xml:base. XSLT 1.0, which was
&lt;br&gt;published in 1999 [1], does not mention xml:base, which was published
&lt;br&gt;two years later [2]. However, there is support for base URIs.
&lt;br&gt;&lt;br&gt;Support for enhanced base URIs as per the 2001 xml:base add-on is up to
&lt;br&gt;the implementation:
&lt;br&gt;&lt;br&gt;* Saxon 6.5 &amp;nbsp; &amp;nbsp; &amp;nbsp;- yes
&lt;br&gt;* LibXSLT 1.1.24 - yes
&lt;br&gt;* Xalan-J 2.7.1 &amp;nbsp;- no
&lt;br&gt;&lt;br&gt;Last, in XSLT/XPath 2.0 you can access the base URI directly using the
&lt;br&gt;base-uri() function [3].
&lt;br&gt;&lt;br&gt;[1] &lt;a href=&quot;http://www.w3.org/TR/xslt#base-uri&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://www.w3.org/TR/xslt#base-uri&lt;/a&gt;&lt;br&gt;[2] &lt;a href=&quot;http://www.w3.org/TR/xmlbase/&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://www.w3.org/TR/xmlbase/&lt;/a&gt;&lt;br&gt;[3] &lt;a href=&quot;http://www.w3.org/TR/xpath-functions/#func-base-uri&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://www.w3.org/TR/xpath-functions/#func-base-uri&lt;/a&gt;&lt;br&gt;&lt;br&gt;-- 
&lt;br&gt;Michael Ludwig
&lt;br&gt;&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Xalan---J---Users-f275.html&quot; embed=&quot;fixTarget[275]&quot; target=&quot;_top&quot; &gt;Xalan - J - Users&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/fo%3Aexternal-graphic-and-xml%3Abase-tp26462628p26488647.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26487817</id>
	<title>Re: fo:external-graphic and xml:base</title>
	<published>2009-11-23T15:10:50Z</published>
	<updated>2009-11-23T15:10:50Z</updated>
	<author>
		<name>Nathan Nadeau</name>
	</author>
	<content type="html">The source of the problem is that FOP is mistakenly calculating the 
&lt;br&gt;base-URI for the images. The purpose of xml:base is to rectify 
&lt;br&gt;situations like this, but it seems that FOP does not know what to do 
&lt;br&gt;with xml:base. For you, it's reporting xml:base as an invalid attribute 
&lt;br&gt;of the fo:block element. For me, it just ignores xml:base and continues 
&lt;br&gt;(of course still incorrectly resolving the image URIs).
&lt;br&gt;&lt;br&gt;First thing I would verify is that your XSLT and/or XSL-FO files are 
&lt;br&gt;aware of the &amp;quot;xml&amp;quot; namespace. I tried this first on my setup, but it did 
&lt;br&gt;not help. Maybe it will help you?
&lt;br&gt;&lt;br&gt;If that doesn't work, there are certainly ways to work around the problem:
&lt;br&gt;&lt;br&gt;1) Download the images to a corresponding local directory in a 
&lt;br&gt;pre-processing step. Or you could program a Xalan extension that 
&lt;br&gt;basically does the same thing &amp;quot;inline&amp;quot; in the XSLT.
&lt;br&gt;&lt;br&gt;2) Explicitly compute the base URI for the particular HTML document 
&lt;br&gt;you're processing and use that value to create an absolute URI in 
&lt;br&gt;&amp;lt;fo:external-graphic&amp;gt;. Something like &amp;quot;concat($base-URI,@src)&amp;quot;. You 
&lt;br&gt;could either pass in $base-URI as a global XSLT parameter (if you know 
&lt;br&gt;this beforehand), or you can calculate it dynamically for each document 
&lt;br&gt;you process by finding the directory of the a/@href attribute (the 
&lt;br&gt;portion of the URI leading up to the file, but not the file name 
&lt;br&gt;itself). Then you'd send that value along to the matching templates with 
&lt;br&gt;&amp;lt;xsl:apply-templates&amp;gt;&amp;lt;xsl:with-param name=&amp;quot;base-URI&amp;quot; select=&amp;quot;blah&amp;quot;/&amp;gt;, 
&lt;br&gt;and you'd need to make sure your matching templates include that 
&lt;br&gt;parameter with &amp;lt;xsl:param name=&amp;quot;base-URI&amp;quot;/&amp;gt;. Then, when you're 
&lt;br&gt;outputting the external graphic, you'd do something like 
&lt;br&gt;&amp;lt;fo:external-graphic src=&amp;quot;url('{concat($base-URI,@src)}')&amp;quot;/&amp;gt;.
&lt;br&gt;&lt;br&gt;3) Tell FOP to use a given base-URI via the configuration file. See 
&lt;br&gt;&lt;a href=&quot;http://xmlgraphics.apache.org/fop/0.94/configuration.html&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://xmlgraphics.apache.org/fop/0.94/configuration.html&lt;/a&gt;. It seems you 
&lt;br&gt;can only do this if you already know the base-URI value beforehand, and 
&lt;br&gt;you can only have one value per FOP run. I actually used this option 
&lt;br&gt;with your example files and it worked for me. No change was needed to 
&lt;br&gt;your files, and I didn't need to use xml:base, but of course you need to 
&lt;br&gt;know the base-URI beforehand, or otherwise somehow loop through calls to 
&lt;br&gt;FOP, updating the config file appropriately on each call.
&lt;br&gt;&lt;br&gt;Cheers,
&lt;br&gt;Nathan Nadeau
&lt;br&gt;&lt;br&gt;&lt;br&gt;Jack Bates wrote:
&lt;div class='shrinkable-quote'&gt;&lt;br&gt;&amp;gt; I originally posted this question to the FOP users list,
&lt;br&gt;&amp;gt; &lt;a href=&quot;http://thread.gmane.org/gmane.text.xml.fop.user/29778&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://thread.gmane.org/gmane.text.xml.fop.user/29778&lt;/a&gt;&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; I'm writing a stylesheet that includes this template,
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;lt;xsl:template match=&amp;quot;html:img&amp;quot;&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;lt;fo:external-graphic src=&amp;quot;url('{@src}')&amp;quot;/&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;lt;/xsl:template&amp;gt;
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; - but when I process it I get errors like,
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp;$ fop -xml index.html -xsl index.xsl index.pdf
&lt;br&gt;&amp;gt; &amp;nbsp;[...]
&lt;br&gt;&amp;gt; &amp;nbsp;16-Nov-2009 11:06:32 AM org.apache.fop.events.LoggingEventListener processEvent
&lt;br&gt;&amp;gt; &amp;nbsp;SEVERE: Image not found. URI: /docs/images/thumb/b/bb/UM-2.1.png/500px-UM-2.1.png. (No context info available)
&lt;br&gt;&amp;gt; &amp;nbsp;[...]
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; - and the generated PDF is missing some images : (
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; I think the problem is that the stylesheet uses the document() function
&lt;br&gt;&amp;gt; to get HTML pages from the web,
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;lt;xsl:template match=&amp;quot;html:a&amp;quot; mode=&amp;quot;foo&amp;quot;&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;lt;fo:block&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;xsl:apply-templates select=&amp;quot;document(@href)//html:body&amp;quot;/&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;lt;/fo:block&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;lt;/xsl:template&amp;gt;
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; - and these pages, e.g. &lt;a href=&quot;http://ica-atom.org/docs/index.php?title=UM-2.1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://ica-atom.org/docs/index.php?title=UM-2.1&lt;/a&gt;&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; - have some relative images,
&lt;br&gt;&amp;gt; e.g. /docs/images/thumb/b/bb/UM-2.1.png/500px-UM-2.1.png
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; The &amp;lt;img&amp;gt; elements are part of the HTML document, and so relative to
&lt;br&gt;&amp;gt; &lt;a href=&quot;http://ica-atom.org/docs/index.php?title=UM-2.1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://ica-atom.org/docs/index.php?title=UM-2.1&lt;/a&gt;, but I guess the
&lt;br&gt;&amp;gt; &amp;lt;external-graphic&amp;gt; elements aren't?
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; I tried adding an xml:base=&amp;quot;&amp;quot; attribute,
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;lt;xsl:template match=&amp;quot;html:a&amp;quot; mode=&amp;quot;foo&amp;quot;&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;lt;fo:block xml:base=&amp;quot;{@href}&amp;quot;&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;lt;xsl:apply-templates select=&amp;quot;document(@href)//html:body&amp;quot;/&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;lt;/fo:block&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;lt;/xsl:template&amp;gt;
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; Here's a simplified, complete example,
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; &lt;a href=&quot;http://www.sfu.ca/~jdbates/tmp/fop/200911160/index.html&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://www.sfu.ca/~jdbates/tmp/fop/200911160/index.html&lt;/a&gt;&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; &lt;a href=&quot;http://www.sfu.ca/~jdbates/tmp/fop/200911160/index.xsl&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://www.sfu.ca/~jdbates/tmp/fop/200911160/index.xsl&lt;/a&gt;&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; - but now when I process this example I get this error,
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp;$ fop -xml index.html -xsl index.xsl index.pdf
&lt;br&gt;&amp;gt; &amp;nbsp;16-Nov-2009 11:29:57 AM org.apache.fop.cli.Main startFOP
&lt;br&gt;&amp;gt; &amp;nbsp;SEVERE: Exception
&lt;br&gt;&amp;gt; &amp;nbsp;javax.xml.transform.TransformerException: org.apache.fop.fo.ValidationException: Invalid property encountered on &amp;quot;fo:block&amp;quot;: xml:base (No context info available)
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;at org.apache.fop.cli.InputHandler.transformTo(InputHandler.java:314)
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;at org.apache.fop.cli.InputHandler.renderTo(InputHandler.java:146)
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;at org.apache.fop.cli.Main.startFOP(Main.java:174)
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;at org.apache.fop.cli.Main.main(Main.java:205)
&lt;br&gt;&amp;gt; &amp;nbsp;[...]
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; How can I automatically convert these HTML pages to a PDF with XSL-FO?
&lt;br&gt;&amp;gt; &amp;nbsp; 
&lt;br&gt;&lt;/div&gt;&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Xalan---J---Users-f275.html&quot; embed=&quot;fixTarget[275]&quot; target=&quot;_top&quot; &gt;Xalan - J - Users&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/fo%3Aexternal-graphic-and-xml%3Abase-tp26462628p26487817.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26484732</id>
	<title>[jira] Commented: (XALANJ-2510) Ability to set non tree fragment variable using an extension element (PATCH SUPPLIED)</title>
	<published>2009-11-23T11:53:39Z</published>
	<updated>2009-11-23T11:53:39Z</updated>
	<author>
		<name>Xalan - Dev mailing list</name>
	</author>
	<content type="html">&lt;br&gt;&amp;nbsp; &amp;nbsp; [ &lt;a href=&quot;https://issues.apache.org/jira/browse/XALANJ-2510?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&amp;focusedCommentId=12781586#action_12781586&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://issues.apache.org/jira/browse/XALANJ-2510?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&amp;focusedCommentId=12781586#action_12781586&lt;/a&gt;&amp;nbsp;] 
&lt;br&gt;&lt;br&gt;Henry Zongaro commented on XALANJ-2510:
&lt;br&gt;---------------------------------------
&lt;br&gt;&lt;br&gt;Sorry - I was just getting caught up on the e-mail thread associated with this. &amp;nbsp;You wrote, &amp;quot;nope, they can't...trust me :)
&lt;br&gt;&lt;br&gt;It's a very advanced extension library with significant nested structure...to represent it as a sequence of nested function calls would be too complex and difficult to read/maintain...if it could be done at all.
&lt;br&gt;&lt;br&gt;The example I gave was an extremely simple use case to get across what I want to do, rather than get bogged down in the particulars of each use case. &amp;nbsp;I understand the use of functions, my extension library has a whole bunch of extension functions (I think it's up to about 30)...but also has about 40 extension elements for structures that are just too complex to be represented as extension functions. &amp;nbsp;Some of these extension elements have return values that don't suit being turned into a node set.&amp;quot;
&lt;br&gt;&lt;div class='shrinkable-quote'&gt;&lt;br&gt;&amp;gt; Ability to set non tree fragment variable using an extension element (PATCH SUPPLIED)
&lt;br&gt;&amp;gt; -------------------------------------------------------------------------------------
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Key: XALANJ-2510
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; URL: &lt;a href=&quot;https://issues.apache.org/jira/browse/XALANJ-2510&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://issues.apache.org/jira/browse/XALANJ-2510&lt;/a&gt;&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Project: XalanJ2
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Issue Type: Improvement
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp;Security Level: No security risk; visible to anyone(Ordinary problems in Xalan projects. &amp;nbsp;Anybody can view the issue.) 
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Components: Xalan-extensions
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp;Affects Versions: The Latest Development Code
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Reporter: Adam Jenkins
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Fix For: The Latest Development Code
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Attachments: XALANJ-2510.patch
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; When using extension elements, there is no way to set a non XRTreeFrag related variable.
&lt;br&gt;&amp;gt; For example, say you have:
&lt;br&gt;&amp;gt; &amp;lt;xsl:variable name=&amp;quot;myvar&amp;quot;&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp;&amp;lt;my:extension someAttribute=&amp;quot;somevalue&amp;quot;/&amp;gt;
&lt;br&gt;&amp;gt; &amp;lt;/xsl:variable&amp;gt;
&lt;br&gt;&amp;gt; If my:extension wants to set a tree fragment, string or nodeset into myvar, that's not a problem, however if it wants to set a java object, currently there is no mechanism for that (any java object passed either returned from the method or passed to XSLProcessorContext.outputToResultTree is toString()'ed before being passed back to the ElemVariable.getValue() method).
&lt;br&gt;&amp;gt; The proposed change (patch supplied) is to supply an optional variable on ElemVariable.java whereby child extension elements can call up to their parent and set an XPath to be evaluated after the extension element has finished processing.
&lt;br&gt;&amp;gt; This requires only very minor modification to the ElemVariable.getValue method to check this variable.
&lt;br&gt;&amp;gt; This also ensures that this is optional functionality and will not affect that basic Xalan processing.
&lt;/div&gt;&lt;br&gt;-- 
&lt;br&gt;This message is automatically generated by JIRA.
&lt;br&gt;-
&lt;br&gt;You can reply to this email to add a comment to the issue online.
&lt;br&gt;&lt;br&gt;&lt;br&gt;---------------------------------------------------------------------
&lt;br&gt;To unsubscribe, e-mail: &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26484732&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;xalan-dev-unsubscribe@...&lt;/a&gt;
&lt;br&gt;For additional commands, e-mail: &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26484732&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;xalan-dev-help@...&lt;/a&gt;
&lt;br&gt;&lt;br&gt;&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Xalan---Dev-f274.html&quot; embed=&quot;fixTarget[274]&quot; target=&quot;_top&quot; &gt;Xalan - Dev&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/-jira--Created%3A-%28XALANJ-2510%29-Ability-to-set-non-tree-fragment-variable-using-an-extension-element-%28PATCH-SUPPLIED%29-tp26378213p26484732.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26484609</id>
	<title>[jira] Commented: (XALANJ-2510) Ability to set non tree fragment variable using an extension element (PATCH SUPPLIED)</title>
	<published>2009-11-23T11:45:40Z</published>
	<updated>2009-11-23T11:45:40Z</updated>
	<author>
		<name>Xalan - Dev mailing list</name>
	</author>
	<content type="html">&lt;br&gt;&amp;nbsp; &amp;nbsp; [ &lt;a href=&quot;https://issues.apache.org/jira/browse/XALANJ-2510?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&amp;focusedCommentId=12781581#action_12781581&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://issues.apache.org/jira/browse/XALANJ-2510?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&amp;focusedCommentId=12781581#action_12781581&lt;/a&gt;&amp;nbsp;] 
&lt;br&gt;&lt;br&gt;Henry Zongaro commented on XALANJ-2510:
&lt;br&gt;---------------------------------------
&lt;br&gt;&lt;br&gt;Adam, could I ask you elaborate on the motivation for this change? &amp;nbsp;It's not clear to me why using an extension function instead wouldn't work. &amp;nbsp;Having an extension element return something other nodes feels odd to me for XSLT 1.0.
&lt;br&gt;&lt;div class='shrinkable-quote'&gt;&lt;br&gt;&amp;gt; Ability to set non tree fragment variable using an extension element (PATCH SUPPLIED)
&lt;br&gt;&amp;gt; -------------------------------------------------------------------------------------
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Key: XALANJ-2510
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; URL: &lt;a href=&quot;https://issues.apache.org/jira/browse/XALANJ-2510&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://issues.apache.org/jira/browse/XALANJ-2510&lt;/a&gt;&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Project: XalanJ2
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Issue Type: Improvement
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp;Security Level: No security risk; visible to anyone(Ordinary problems in Xalan projects. &amp;nbsp;Anybody can view the issue.) 
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Components: Xalan-extensions
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp;Affects Versions: The Latest Development Code
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;Reporter: Adam Jenkins
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Fix For: The Latest Development Code
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Attachments: XALANJ-2510.patch
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt;
&lt;br&gt;&amp;gt; When using extension elements, there is no way to set a non XRTreeFrag related variable.
&lt;br&gt;&amp;gt; For example, say you have:
&lt;br&gt;&amp;gt; &amp;lt;xsl:variable name=&amp;quot;myvar&amp;quot;&amp;gt;
&lt;br&gt;&amp;gt; &amp;nbsp; &amp;nbsp;&amp;lt;my:extension someAttribute=&amp;quot;somevalue&amp;quot;/&amp;gt;
&lt;br&gt;&amp;gt; &amp;lt;/xsl:variable&amp;gt;
&lt;br&gt;&amp;gt; If my:extension wants to set a tree fragment, string or nodeset into myvar, that's not a problem, however if it wants to set a java object, currently there is no mechanism for that (any java object passed either returned from the method or passed to XSLProcessorContext.outputToResultTree is toString()'ed before being passed back to the ElemVariable.getValue() method).
&lt;br&gt;&amp;gt; The proposed change (patch supplied) is to supply an optional variable on ElemVariable.java whereby child extension elements can call up to their parent and set an XPath to be evaluated after the extension element has finished processing.
&lt;br&gt;&amp;gt; This requires only very minor modification to the ElemVariable.getValue method to check this variable.
&lt;br&gt;&amp;gt; This also ensures that this is optional functionality and will not affect that basic Xalan processing.
&lt;/div&gt;&lt;br&gt;-- 
&lt;br&gt;This message is automatically generated by JIRA.
&lt;br&gt;-
&lt;br&gt;You can reply to this email to add a comment to the issue online.
&lt;br&gt;&lt;br&gt;&lt;br&gt;---------------------------------------------------------------------
&lt;br&gt;To unsubscribe, e-mail: &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26484609&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;xalan-dev-unsubscribe@...&lt;/a&gt;
&lt;br&gt;For additional commands, e-mail: &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26484609&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;xalan-dev-help@...&lt;/a&gt;
&lt;br&gt;&lt;br&gt;&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Xalan---Dev-f274.html&quot; embed=&quot;fixTarget[274]&quot; target=&quot;_top&quot; &gt;Xalan - Dev&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/-jira--Created%3A-%28XALANJ-2510%29-Ability-to-set-non-tree-fragment-variable-using-an-extension-element-%28PATCH-SUPPLIED%29-tp26378213p26484609.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26470311</id>
	<title>Re: Loosing significant space in LSSerializer</title>
	<published>2009-11-22T14:32:27Z</published>
	<updated>2009-11-22T14:32:27Z</updated>
	<author>
		<name>Michael Glavassevich-3</name>
	</author>
	<content type="html">&lt;html&gt;&lt;body&gt;
&lt;p&gt;&lt;tt&gt;Right, that's exactly how it works:&lt;/tt&gt;&lt;br&gt;
&lt;br&gt;
&lt;tt&gt;&amp;nbsp; &amp;nbsp; public LSSerializer createLSSerializer() {&lt;/tt&gt;&lt;br&gt;
&lt;tt&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; try {&lt;/tt&gt;&lt;br&gt;
&lt;tt&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; Class serializerClass = ObjectFactory.findProviderClass(&lt;/tt&gt;&lt;br&gt;
&lt;tt&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;quot;org.apache.xml.serializer.dom3.LSSerializerImpl&amp;quot;,&lt;/tt&gt;&lt;br&gt;
&lt;tt&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; ObjectFactory.findClassLoader(), true);&lt;/tt&gt;&lt;br&gt;
&lt;tt&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; return (LSSerializer) serializerClass.newInstance();&lt;/tt&gt;&lt;br&gt;
&lt;tt&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; }&lt;/tt&gt;&lt;br&gt;
&lt;tt&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; catch (Exception e) {}&lt;/tt&gt;&lt;br&gt;
&lt;tt&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; // Fall back to Xerces' deprecated serializer if &lt;/tt&gt;&lt;br&gt;
&lt;tt&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; // the Xalan based serializer is unavailable.&lt;/tt&gt;&lt;br&gt;
&lt;tt&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; return new DOMSerializerImpl();&lt;/tt&gt;&lt;br&gt;
&lt;tt&gt;&amp;nbsp; &amp;nbsp; }&lt;/tt&gt;&lt;br&gt;
&lt;br&gt;
&lt;tt&gt;Was hoping to put a warning in there if it takes the fallback path but there's no DOMErrorHandler to report it to at this point.&lt;/tt&gt;&lt;br&gt;
&lt;br&gt;
&lt;tt&gt;FYI: If you don't have Xerces on the classpath but instead try to access the JDK version [1] you may not get very far.&lt;/tt&gt;&lt;br&gt;
&lt;br&gt;
&lt;tt&gt;Thanks.&lt;/tt&gt;&lt;br&gt;
&lt;br&gt;
&lt;tt&gt;[1] &lt;/tt&gt;&lt;tt&gt;&lt;a href=&quot;http://markmail.org/message/e6rlhwymr43p4u4v&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://markmail.org/message/e6rlhwymr43p4u4v&lt;/a&gt;&lt;/tt&gt;&lt;br&gt;
&lt;br&gt;
&lt;tt&gt;Michael Glavassevich&lt;br&gt;
XML Parser Development&lt;br&gt;
IBM Toronto Lab&lt;br&gt;
E-mail: &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26470311&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;mrglavas@...&lt;/a&gt;&lt;/tt&gt;&lt;br&gt;
&lt;tt&gt;E-mail: &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26470311&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;mrglavas@...&lt;/a&gt;&lt;/tt&gt;&lt;br&gt;
&lt;br&gt;
&lt;tt&gt;Dick Deneer &amp;lt;&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26470311&amp;i=2&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;dick.deneer@...&lt;/a&gt;&amp;gt; wrote on 11/22/2009 04:06:06 PM:&lt;br&gt;
&lt;br&gt;
&amp;gt; Hi Benson,&lt;/tt&gt;&lt;br&gt;
&lt;tt&gt;&amp;gt; &lt;br&gt;
&amp;gt; As Michael notes, Xerces is now shipped with the serializer.jar &lt;br&gt;
&amp;gt; (which contains the xalan serializer). If you have this on your &lt;br&gt;
&amp;gt; classpath it will be used.&lt;/tt&gt;&lt;br&gt;
&lt;tt&gt;&amp;gt; If you leave it out, then xerces will fall back to it's own (deprecated) one.&lt;/tt&gt;&lt;br&gt;
&lt;tt&gt;&amp;gt; &lt;br&gt;
&amp;gt; regards&lt;/tt&gt;&lt;br&gt;
&lt;tt&gt;&amp;gt; Dick Deneer&lt;/tt&gt;&lt;br&gt;
&lt;tt&gt;&amp;gt; Op 22-nov-2009, om 21:54 heeft Benson Margulies het volgende geschreven:&lt;/tt&gt;&lt;br&gt;
&lt;tt&gt;&amp;gt; &lt;br&gt;
&amp;gt; Hi Michael,&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; So, if I put Xerces and not Xalan into classpath, and ask a document&lt;br&gt;
&amp;gt; for it's implementation, and ask that for the DOMImplementationLS, &lt;br&gt;
&amp;gt; what do I get? Whatever Sun tossed into the pot? And if I then add &lt;br&gt;
&amp;gt; Xalan, do I get the right one?&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; --benson&lt;br&gt;
&amp;gt; &lt;br&gt;
&lt;/tt&gt;&lt;br&gt;
&lt;tt&gt;&amp;gt; On Sat, Nov 21, 2009 at 10:24 PM, Michael Glavassevich &amp;lt;&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26470311&amp;i=3&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;mrglavas@...&lt;/a&gt;&lt;br&gt;
&amp;gt; &amp;gt; wrote:&lt;/tt&gt;&lt;br&gt;
&lt;tt&gt;&amp;gt; Hi Benson,&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; We're talking about two different implementations of the DOM Level 3&lt;br&gt;
&amp;gt; LSSerializer, the more recently developed one in Xalan &lt;br&gt;
&amp;gt; (serializer.jar which Xerces now ships and shares with Xalan) and &lt;br&gt;
&amp;gt; the much older deprecated one in Xerces. If you're curious about the&lt;br&gt;
&amp;gt; history on that, there's an FAQ [1] on the website.&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; Some users have decided to keep using Xerces' deprecated serializer &lt;br&gt;
&amp;gt; due to some quirks and issues with the currently available one from &lt;br&gt;
&amp;gt; Xalan. Folks really should be opening JIRA issues [2] against Xalan,&lt;br&gt;
&amp;gt; so those problems get addressed there. There's no intention to do &lt;br&gt;
&amp;gt; any further development or fixes to the one in Xerces.&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; Thanks.&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; [1] &lt;a href=&quot;http://xerces.apache.org/xerces2-j/faq-general.html#faq-6&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;http://xerces.apache.org/xerces2-j/faq-general.html#faq-6&lt;/a&gt;&lt;br&gt;
&amp;gt; [2] &lt;a href=&quot;https://issues.apache.org/jira/browse/XALANJ&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;https://issues.apache.org/jira/browse/XALANJ&lt;/a&gt;&lt;/tt&gt;&lt;br&gt;
&lt;tt&gt;&amp;gt; &lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; Michael Glavassevich&lt;br&gt;
&amp;gt; XML Parser Development&lt;br&gt;
&amp;gt; IBM Toronto Lab&lt;br&gt;
&amp;gt; E-mail: &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26470311&amp;i=4&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;mrglavas@...&lt;/a&gt;&lt;br&gt;
&amp;gt; E-mail: &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26470311&amp;i=5&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;mrglavas@...&lt;/a&gt;&lt;br&gt;
&lt;/tt&gt;&lt;br&gt;
&lt;tt&gt;&amp;gt; Benson Margulies &amp;lt;&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26470311&amp;i=6&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;bimargulies@...&lt;/a&gt;&amp;gt; wrote on 11/21/2009 02:17:49 PM:&lt;/tt&gt;&lt;br&gt;
&lt;tt&gt;&amp;gt; &lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; Could I please ask for a bit of clarification? The only LSSerializer&lt;br&gt;
&amp;gt; &amp;gt; I'm aware of is the DOM level 3 stuff, which, I thought, was the &lt;br&gt;
&amp;gt; &amp;gt; opposite of obsolete. As someone pointed out here, unlike TraX, it &lt;br&gt;
&amp;gt; &amp;gt; will serialize doctypes and do other handy things. In general, I'm &lt;br&gt;
&amp;gt; &amp;gt; beginning to prefer the DOMImplementationLS to JAXP and TraX.&lt;/tt&gt;&lt;br&gt;
&lt;tt&gt;&amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; On Sat, Nov 21, 2009 at 2:07 PM, Michael Glavassevich &amp;lt;&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26470311&amp;i=7&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;mrglavas@...&lt;/a&gt;&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; wrote:&lt;br&gt;
&amp;gt; &amp;gt; You should also be able to control whether spaces are preserved by &lt;br&gt;
&amp;gt; &amp;gt; registering an LSSerializerFilter.&lt;br&gt;
&amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; When I added one to your test program:&lt;br&gt;
&amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; if (useXerces)&lt;br&gt;
&amp;gt; &amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; {&lt;br&gt;
&amp;gt; &amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; domWriter = new DOMSerializerImpl();&lt;br&gt;
&amp;gt; &amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; domWriter.setFilter(new LSSerializerFilter() {&lt;br&gt;
&amp;gt; &amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; public int getWhatToShow() {&lt;br&gt;
&amp;gt; &amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; return LSSerializerFilter.SHOW_ALL;&lt;br&gt;
&amp;gt; &amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; }&lt;br&gt;
&amp;gt; &amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; public short acceptNode(Node n) {&lt;br&gt;
&amp;gt; &amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; return LSSerializerFilter.FILTER_ACCEPT;&lt;br&gt;
&amp;gt; &amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; }});&lt;br&gt;
&amp;gt; &amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; }&lt;br&gt;
&amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; the output I get is:&lt;br&gt;
&amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; Program started&lt;br&gt;
&amp;gt; &amp;gt; Xerces serializer will be used&lt;br&gt;
&amp;gt; &amp;gt; &amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;UTF-16&amp;quot;?&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; &amp;lt;root&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; &amp;lt;child1&amp;gt;text&amp;lt;/child1&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; &amp;lt;child2&amp;gt; &amp;lt;/child2&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; &amp;lt;/root&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; Xalan serializer will be used&lt;br&gt;
&amp;gt; &amp;gt; &amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;UTF-16&amp;quot;?&amp;gt;&amp;lt;root&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; &amp;lt;child1&amp;gt;text&amp;lt;/child1&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; &amp;lt;child2&amp;gt; &amp;lt;/child2&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; &amp;lt;/root&amp;gt;&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; which I believe is what you were expecting.&lt;br&gt;
&amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; Thanks.&lt;br&gt;
&amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; Michael Glavassevich&lt;br&gt;
&amp;gt; &amp;gt; XML Parser Development&lt;br&gt;
&amp;gt; &amp;gt; IBM Toronto Lab&lt;br&gt;
&amp;gt; &amp;gt; E-mail: &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26470311&amp;i=8&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;mrglavas@...&lt;/a&gt;&lt;br&gt;
&amp;gt; &amp;gt; E-mail: &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26470311&amp;i=9&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;mrglavas@...&lt;/a&gt;&lt;br&gt;
&amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; Dick Deneer &amp;lt;&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26470311&amp;i=10&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;dick.deneer@...&lt;/a&gt;&amp;gt; wrote on 11/21/2009 &lt;br&gt;
&amp;gt; &amp;gt; 01:19:27 PM:&lt;br&gt;
&amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; Hi Jake,&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; I just tried your suggestion and the spaces are indeed preserved.&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; But still, I woud prefer another solution. I do not have any clue &amp;nbsp;&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; about the xml (I use xerces in a xml editor) and I do not want to &amp;nbsp;&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; change the xml.&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; And also I would like to stay with the LSSerializer (it also &amp;nbsp;&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; serilalizes doctype nodes).&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; If there is another way please let me know.&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; Thanks&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; Dick Deneer&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; Op 21-nov-2009, om 19:03 heeft Jacob Kjome het volgende geschreven:&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &amp;gt; Have you tried xml:space=&amp;quot;preserve&amp;quot;?&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &amp;gt; Jake&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &amp;gt; On 11/20/2009 4:36 PM, Dick Deneer wrote:&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &amp;gt;&amp;gt; I am still using the deprecated LSSerializer because the xalan&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &amp;gt;&amp;gt; serializer has issues with the pretty print.&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &amp;gt;&amp;gt; But when I have simple elements with only space, the serializer &amp;nbsp;&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &amp;gt;&amp;gt; produces&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &amp;gt;&amp;gt; empty elements. Is there a tweak to keep the spaces in this elements?&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &amp;gt;&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &amp;gt;&amp;gt; Sample xml:&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &amp;gt;&amp;gt; &amp;lt;root&amp;gt;&amp;lt;child1&amp;gt;text&amp;lt;/child1&amp;gt;&amp;lt;child2&amp;gt; &amp;lt;/child2&amp;gt;&amp;lt;/root&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &amp;gt;&amp;gt; I attached a simple test program, that you can just run to see the &amp;nbsp;&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &amp;gt;&amp;gt; results:&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &amp;gt;&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &amp;gt;&amp;gt; Program started&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &amp;gt;&amp;gt; Xerces serializer will be used&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &amp;gt;&amp;gt; &amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;UTF-16&amp;quot;?&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &amp;gt;&amp;gt; &amp;lt;root&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &amp;gt;&amp;gt; &amp;lt;child1&amp;gt;text&amp;lt;/child1&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &amp;gt;&amp;gt; &amp;lt;child2/&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &amp;gt;&amp;gt; &amp;lt;/root&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &amp;gt;&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &amp;gt;&amp;gt; Xalan serializer will be used&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &amp;gt;&amp;gt; &amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;UTF-16&amp;quot;?&amp;gt;&amp;lt;root&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &amp;gt;&amp;gt; &amp;lt;child1&amp;gt;text&amp;lt;/child1&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &amp;gt;&amp;gt; &amp;lt;child2&amp;gt; &amp;lt;/child2&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &amp;gt;&amp;gt; &amp;lt;/root&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &amp;gt;&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &amp;gt;&amp;gt; Regards&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &amp;gt;&amp;gt; Dick Deneer&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &amp;gt;&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &amp;gt;&amp;gt; --------------------------------------------------------------------- &lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &amp;gt;&amp;gt; ---&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &amp;gt;&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &amp;gt; ---------------------------------------------------------------------&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &amp;gt; To unsubscribe, e-mail: &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26470311&amp;i=11&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;j-users-unsubscribe@...&lt;/a&gt;&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &amp;gt; For additional commands, e-mail: &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26470311&amp;i=12&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;j-users-help@...&lt;/a&gt;&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; ---------------------------------------------------------------------&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; To unsubscribe, e-mail: &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26470311&amp;i=13&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;j-users-unsubscribe@...&lt;/a&gt;&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; For additional commands, e-mail: &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26470311&amp;i=14&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;j-users-help@...&lt;/a&gt;&lt;/tt&gt;&lt;/body&gt;&lt;/html&gt;&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Xalan---J---Users-f275.html&quot; embed=&quot;fixTarget[275]&quot; target=&quot;_top&quot; &gt;Xalan - J - Users&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/Re%3A-Loosing-significant-space-in-LSSerializer-tp26466277p26470311.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26469379</id>
	<title>Re: Loosing significant space in LSSerializer</title>
	<published>2009-11-22T12:54:37Z</published>
	<updated>2009-11-22T12:54:37Z</updated>
	<author>
		<name>bimargulies</name>
	</author>
	<content type="html">Hi Michael,&lt;br&gt;&lt;br&gt;So, if I put Xerces and not Xalan into classpath, and ask a document for it&amp;#39;s implementation, and ask that for the DOMImplementationLS, what do I get? Whatever Sun tossed into the pot? And if I then add Xalan, do I get the right one?&lt;br&gt;
&lt;br&gt;--benson&lt;br&gt;&lt;br&gt;&lt;br&gt;&lt;div class=&quot;gmail_quote&quot;&gt;On Sat, Nov 21, 2009 at 10:24 PM, Michael Glavassevich &lt;span dir=&quot;ltr&quot;&gt;&amp;lt;&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26469379&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;mrglavas@...&lt;/a&gt;&amp;gt;&lt;/span&gt; wrote:&lt;br&gt;&lt;blockquote class=&quot;gmail_quote&quot; style=&quot;border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;&quot;&gt;
&lt;div&gt;
&lt;p&gt;&lt;tt&gt;Hi Benson,&lt;/tt&gt;&lt;br&gt;
&lt;br&gt;
&lt;tt&gt;We&amp;#39;re talking about two different implementations of the DOM Level 3 LSSerializer, the more recently developed one in Xalan (serializer.jar which Xerces now ships and shares with Xalan) and the much older deprecated one in Xerces. If you&amp;#39;re curious about the history on that, there&amp;#39;s an FAQ [1] on the website.&lt;/tt&gt;&lt;br&gt;

&lt;br&gt;
&lt;tt&gt;Some users have decided to keep using Xerces&amp;#39; deprecated serializer due to some quirks and issues with the currently available one from Xalan. Folks really should be opening JIRA issues [2] against Xalan, so those problems get addressed there. There&amp;#39;s no intention to do any further development or fixes to the one in Xerces.&lt;/tt&gt;&lt;br&gt;

&lt;br&gt;
&lt;tt&gt;Thanks.&lt;/tt&gt;&lt;br&gt;
&lt;br&gt;
&lt;tt&gt;[1] &lt;a href=&quot;http://xerces.apache.org/xerces2-j/faq-general.html#faq-6&quot; target=&quot;_blank&quot; rel=&quot;nofollow&quot;&gt;http://xerces.apache.org/xerces2-j/faq-general.html#faq-6&lt;/a&gt;&lt;/tt&gt;&lt;br&gt;
&lt;tt&gt;[2] &lt;/tt&gt;&lt;tt&gt;&lt;a href=&quot;https://issues.apache.org/jira/browse/XALANJ&quot; target=&quot;_blank&quot; rel=&quot;nofollow&quot;&gt;https://issues.apache.org/jira/browse/XALANJ&lt;/a&gt;&lt;/tt&gt;&lt;/p&gt;&lt;div class=&quot;im&quot;&gt;&lt;br&gt;
&lt;br&gt;
&lt;tt&gt;Michael Glavassevich&lt;br&gt;
XML Parser Development&lt;br&gt;
IBM Toronto Lab&lt;br&gt;
E-mail: &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26469379&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;mrglavas@...&lt;/a&gt;&lt;/tt&gt;&lt;br&gt;
&lt;tt&gt;E-mail: &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26469379&amp;i=2&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;mrglavas@...&lt;/a&gt;&lt;/tt&gt;&lt;br&gt;
&lt;br&gt;
&lt;/div&gt;&lt;tt&gt;Benson Margulies &amp;lt;&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26469379&amp;i=3&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;bimargulies@...&lt;/a&gt;&amp;gt; wrote on 11/21/2009 02:17:49 PM:&lt;div&gt;&lt;div&gt;&lt;/div&gt;&lt;div class=&quot;h5&quot;&gt;&lt;br&gt;
&lt;br&gt;
&amp;gt; Could I please ask for a bit of clarification? The only LSSerializer&lt;br&gt;
&amp;gt; I&amp;#39;m aware of is the DOM level 3 stuff, which, I thought, was the &lt;br&gt;
&amp;gt; opposite of obsolete. As someone pointed out here, unlike TraX, it &lt;br&gt;
&amp;gt; will serialize doctypes and do other handy things. In general, I&amp;#39;m &lt;br&gt;
&amp;gt; beginning to prefer the DOMImplementationLS to JAXP and TraX.&lt;br&gt;
&lt;/div&gt;&lt;/div&gt;&lt;/tt&gt;&lt;div&gt;&lt;div&gt;&lt;/div&gt;&lt;div class=&quot;h5&quot;&gt;&lt;br&gt;
&lt;tt&gt;&amp;gt; On Sat, Nov 21, 2009 at 2:07 PM, Michael Glavassevich &amp;lt;&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26469379&amp;i=4&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;mrglavas@...&lt;/a&gt;&lt;br&gt;
&amp;gt; &amp;gt; wrote:&lt;/tt&gt;&lt;br&gt;
&lt;tt&gt;&amp;gt; You should also be able to control whether spaces are preserved by &lt;br&gt;
&amp;gt; registering an LSSerializerFilter.&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; When I added one to your test program:&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt;         if (useXerces)&lt;br&gt;
&amp;gt;         {&lt;br&gt;
&amp;gt;             domWriter = new DOMSerializerImpl();&lt;br&gt;
&amp;gt;             domWriter.setFilter(new LSSerializerFilter() {&lt;br&gt;
&amp;gt;                 public int getWhatToShow() {&lt;br&gt;
&amp;gt;                     return LSSerializerFilter.SHOW_ALL;&lt;br&gt;
&amp;gt;                 }&lt;br&gt;
&amp;gt;                 public short acceptNode(Node n) {&lt;br&gt;
&amp;gt;                     return LSSerializerFilter.FILTER_ACCEPT;&lt;br&gt;
&amp;gt;                 }});&lt;br&gt;
&amp;gt;         }&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; the output I get is:&lt;/tt&gt;&lt;br&gt;
&lt;tt&gt;&amp;gt; &lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; Program started&lt;br&gt;
&amp;gt; Xerces serializer will be used&lt;br&gt;
&amp;gt; &amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;UTF-16&amp;quot;?&amp;gt;&lt;br&gt;
&amp;gt; &amp;lt;root&amp;gt;&lt;br&gt;
&amp;gt; &amp;lt;child1&amp;gt;text&amp;lt;/child1&amp;gt;&lt;/tt&gt;&lt;br&gt;
&lt;tt&gt;&amp;gt; &amp;lt;child2&amp;gt; &amp;lt;/child2&amp;gt;&lt;/tt&gt;&lt;br&gt;
&lt;tt&gt;&amp;gt; &lt;br&gt;
&amp;gt; &amp;lt;/root&amp;gt;&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; Xalan serializer will be used&lt;br&gt;
&amp;gt; &amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;UTF-16&amp;quot;?&amp;gt;&amp;lt;root&amp;gt;&lt;br&gt;
&amp;gt; &amp;lt;child1&amp;gt;text&amp;lt;/child1&amp;gt;&lt;br&gt;
&amp;gt; &amp;lt;child2&amp;gt; &amp;lt;/child2&amp;gt;&lt;br&gt;
&amp;gt; &amp;lt;/root&amp;gt;&lt;br&gt;
&lt;/tt&gt;&lt;br&gt;
&lt;tt&gt;&amp;gt; which I believe is what you were expecting.&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; Thanks.&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; Michael Glavassevich&lt;br&gt;
&amp;gt; XML Parser Development&lt;br&gt;
&amp;gt; IBM Toronto Lab&lt;br&gt;
&amp;gt; E-mail: &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26469379&amp;i=5&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;mrglavas@...&lt;/a&gt;&lt;br&gt;
&amp;gt; E-mail: &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26469379&amp;i=6&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;mrglavas@...&lt;/a&gt;&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; Dick Deneer &amp;lt;&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26469379&amp;i=7&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;dick.deneer@...&lt;/a&gt;&amp;gt; wrote on 11/21/2009 &lt;br&gt;
&amp;gt; 01:19:27 PM:&lt;/tt&gt;&lt;br&gt;
&lt;tt&gt;&amp;gt; &lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; Hi Jake,&lt;br&gt;
&amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; I just tried your suggestion and the spaces are indeed preserved.&lt;br&gt;
&amp;gt; &amp;gt; But still, I woud prefer another solution. I do not have any clue  &lt;br&gt;
&amp;gt; &amp;gt; about the xml (I use xerces in a xml editor) and I do not want to  &lt;br&gt;
&amp;gt; &amp;gt; change the xml.&lt;br&gt;
&amp;gt; &amp;gt; And also I would like to stay with the LSSerializer (it also  &lt;br&gt;
&amp;gt; &amp;gt; serilalizes doctype nodes).&lt;br&gt;
&amp;gt; &amp;gt; If there is another way please let me know.&lt;br&gt;
&amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; Thanks&lt;br&gt;
&amp;gt; &amp;gt; Dick Deneer&lt;br&gt;
&amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; Op 21-nov-2009, om 19:03 heeft Jacob Kjome het volgende geschreven:&lt;br&gt;
&amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; Have you tried xml:space=&amp;quot;preserve&amp;quot;?&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; Jake&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; On 11/20/2009 4:36 PM, Dick Deneer wrote:&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt;&amp;gt; I am still using the deprecated LSSerializer because the xalan&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt;&amp;gt; serializer has issues with the pretty print.&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt;&amp;gt; But when I have simple elements with only space, the serializer  &lt;br&gt;
&amp;gt; &amp;gt; &amp;gt;&amp;gt; produces&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt;&amp;gt; empty elements. Is there a tweak to keep the spaces in this elements?&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt;&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt;&amp;gt; Sample xml:&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt;&amp;gt; &amp;lt;root&amp;gt;&amp;lt;child1&amp;gt;text&amp;lt;/child1&amp;gt;&amp;lt;child2&amp;gt; &amp;lt;/child2&amp;gt;&amp;lt;/root&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt;&amp;gt; I attached a simple test program, that you can just run to see the  &lt;br&gt;
&amp;gt; &amp;gt; &amp;gt;&amp;gt; results:&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt;&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt;&amp;gt; Program started&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt;&amp;gt; Xerces serializer will be used&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt;&amp;gt; &amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;UTF-16&amp;quot;?&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt;&amp;gt; &amp;lt;root&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt;&amp;gt; &amp;lt;child1&amp;gt;text&amp;lt;/child1&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt;&amp;gt; &amp;lt;child2/&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt;&amp;gt; &amp;lt;/root&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt;&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt;&amp;gt; Xalan serializer will be used&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt;&amp;gt; &amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;UTF-16&amp;quot;?&amp;gt;&amp;lt;root&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt;&amp;gt; &amp;lt;child1&amp;gt;text&amp;lt;/child1&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt;&amp;gt; &amp;lt;child2&amp;gt; &amp;lt;/child2&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt;&amp;gt; &amp;lt;/root&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt;&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt;&amp;gt; Regards&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt;&amp;gt; Dick Deneer&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt;&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt;&amp;gt; --------------------------------------------------------------------- &lt;br&gt;
&amp;gt; &amp;gt; &amp;gt;&amp;gt; ---&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt;&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; ---------------------------------------------------------------------&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; To unsubscribe, e-mail: &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26469379&amp;i=8&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;j-users-unsubscribe@...&lt;/a&gt;&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt; For additional commands, e-mail: &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26469379&amp;i=9&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;j-users-help@...&lt;/a&gt;&lt;br&gt;
&amp;gt; &amp;gt; &amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; ---------------------------------------------------------------------&lt;br&gt;
&amp;gt; &amp;gt; To unsubscribe, e-mail: &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26469379&amp;i=10&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;j-users-unsubscribe@...&lt;/a&gt;&lt;br&gt;
&amp;gt; &amp;gt; For additional commands, e-mail: &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26469379&amp;i=11&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;j-users-help@...&lt;/a&gt;&lt;/tt&gt;&lt;/div&gt;&lt;/div&gt;&lt;/div&gt;&lt;/blockquote&gt;&lt;/div&gt;&lt;br&gt;
&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Xalan---J---Users-f275.html&quot; embed=&quot;fixTarget[275]&quot; target=&quot;_top&quot; &gt;Xalan - J - Users&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/Re%3A-Loosing-significant-space-in-LSSerializer-tp26466277p26469379.html" />
</entry>

<entry>
	<id>tag:old.nabble.com,2006:post-26466277</id>
	<title>Re: Loosing significant space in LSSerializer</title>
	<published>2009-11-22T07:35:25Z</published>
	<updated>2009-11-22T07:35:25Z</updated>
	<author>
		<name>Michael Glavassevich-3</name>
	</author>
	<content type="html">&lt;html&gt;&lt;body&gt;
&lt;p&gt;&lt;tt&gt;(Copying xalan-j-users to this thread.)&lt;/tt&gt;&lt;br&gt;
&lt;br&gt;
&lt;tt&gt;Michael Glavassevich&lt;br&gt;
XML Parser Development&lt;br&gt;
IBM Toronto Lab&lt;br&gt;
E-mail: &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26466277&amp;i=0&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;mrglavas@...&lt;/a&gt;&lt;/tt&gt;&lt;br&gt;
&lt;tt&gt;E-mail: &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26466277&amp;i=1&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;mrglavas@...&lt;/a&gt;&lt;/tt&gt;&lt;br&gt;
&lt;br&gt;
&lt;tt&gt;Michael Glavassevich &amp;lt;&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26466277&amp;i=2&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;mrglavas@...&lt;/a&gt;&amp;gt; wrote on 11/22/2009 10:30:49 AM:&lt;br&gt;
 &lt;br&gt;
&amp;gt; Dick Deneer &amp;lt;&lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26466277&amp;i=3&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;dick.deneer@...&lt;/a&gt;&amp;gt; wrote on 11/22/2009 &lt;br&gt;
&amp;gt; 06:33:28 AM:&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; Michael,&lt;br&gt;
&amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; Thank you for this suggestion.&lt;br&gt;
&amp;gt; &amp;gt; I can use this. Before I call the serializer I will strip off all &lt;br&gt;
&amp;gt; &amp;gt; whitespace in &amp;quot;whitespace-only&amp;quot; complex nodes because otherwise I do&lt;br&gt;
&amp;gt; &amp;gt; not get a pretty-print:&lt;br&gt;
&amp;gt; &amp;gt; For example:&lt;br&gt;
&amp;gt; &amp;gt; String xml = &amp;quot;&amp;lt;root&amp;gt;&amp;quot; +&lt;br&gt;
&amp;gt; &amp;gt; &amp;quot; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&amp;lt;child1&amp;gt;text&amp;lt;/child1&amp;gt;&amp;lt;child2&amp;gt; &amp;nbsp; &lt;br&gt;
&amp;gt; &amp;gt; &amp;lt;/child2&amp;gt;&amp;lt;/root&amp;gt;&amp;quot;;&lt;br&gt;
&amp;gt; &amp;gt; results in :&lt;br&gt;
&amp;gt; &amp;gt; &amp;lt;?xml version=&amp;quot;1.0&amp;quot; encoding=&amp;quot;UTF-16&amp;quot;?&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; &amp;lt;root&amp;gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&amp;lt;child1&amp;gt;text&amp;lt;/child1&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; &amp;nbsp; &amp;nbsp; &amp;lt;child2&amp;gt; &amp;nbsp; &amp;lt;/child2&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; &amp;lt;/root&amp;gt;&lt;br&gt;
&amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; But stripping of this whitespace before will not be too difficult.&lt;br&gt;
&amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; I feel it is a pitty that the LSSerializer will not be maintained &lt;br&gt;
&amp;gt; &amp;gt; anymore, because we do not have alternatives that supply the same &lt;br&gt;
&amp;gt; &amp;gt; functionality.&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; It is in Xalan. Their serializer started as a copy of the Xerces one&lt;br&gt;
&amp;gt; (even has similar package names: org.apache.xml.serialize vs. &lt;br&gt;
&amp;gt; org.apache.xml.serializer). We didn't want to duplicate the effort &lt;br&gt;
&amp;gt; anymore and decided to combine forces and the Xalan one was chosen &lt;br&gt;
&amp;gt; as the common codebase because it was better maintained and was &lt;br&gt;
&amp;gt; making significant improvements to performance. Its LSSerializer &lt;br&gt;
&amp;gt; implementation was written by a Xerces committer and I have made &lt;br&gt;
&amp;gt; improvements and fixes to it too where I've found issues, so it's &lt;br&gt;
&amp;gt; being jointly maintained, though in a different project. This is the&lt;br&gt;
&amp;gt; alternative. It *is* an LSSerializer and there is no reason that it &lt;br&gt;
&amp;gt; can't be updated / fixed to have similar behaviour, but that's only &lt;br&gt;
&amp;gt; likely to happen if users report the problems they're having &lt;br&gt;
&amp;gt; (patches are welcome), preferably in JIRA.&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; I am afraid that maybe in the future there may be new xml (or DOM) &lt;br&gt;
&amp;gt; &amp;gt; feautures that have effects on the serialization. Then we are &lt;br&gt;
&amp;gt; &amp;gt; totally dependent on other libraries to implement that functionality.&lt;br&gt;
&amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; But I understand you have to make choices where to spent the effort.&lt;br&gt;
&amp;gt; &amp;gt; &lt;br&gt;
&amp;gt; &amp;gt; Thanks&lt;br&gt;
&amp;gt; &amp;gt; Dick Deneer&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; Thanks.&lt;br&gt;
&amp;gt; &lt;br&gt;
&amp;gt; Michael Glavassevich&lt;br&gt;
&amp;gt; XML Parser Development&lt;br&gt;
&amp;gt; IBM Toronto Lab&lt;br&gt;
&amp;gt; E-mail: &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26466277&amp;i=4&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;mrglavas@...&lt;/a&gt;&lt;br&gt;
&amp;gt; E-mail: &lt;a href=&quot;http://old.nabble.com/user/SendEmail.jtp?type=post&amp;post=26466277&amp;i=5&quot; target=&quot;_top&quot; rel=&quot;nofollow&quot;&gt;mrglavas@...&lt;/a&gt;&lt;/tt&gt;&lt;/body&gt;&lt;/html&gt;&lt;p&gt;From forum: &lt;a href=&quot;http://old.nabble.com/Xalan---J---Users-f275.html&quot; embed=&quot;fixTarget[275]&quot; target=&quot;_top&quot; &gt;Xalan - J - Users&lt;/a&gt;&lt;/p&gt;</content>
	<link rel="alternate" type="text/html" href="http://old.nabble.com/Re%3A-Loosing-significant-space-in-LSSerializer-tp26466277p26466277.html" />
</entry>

</feed>
