morten 01/10/18 09:53:09
Modified: java/src/org/apache/xalan/xsltc/dom MultiDOM.java
Log:
Fix for variables and parameters containing node sets in stylesheets that
use the document() function. This fix completes the cloneIterator() method
of the axis iterators returned by the DOM multiplexer.
PR: bugzilla 3501
Obtained from: n/a
Submitted by: [EMAIL PROTECTED]
Reviewed by: [EMAIL PROTECTED]
Revision Changes Path
1.10 +6 -9
xml-xalan/java/src/org/apache/xalan/xsltc/dom/MultiDOM.java
Index: MultiDOM.java
===================================================================
RCS file:
/home/cvs/xml-xalan/java/src/org/apache/xalan/xsltc/dom/MultiDOM.java,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -r1.9 -r1.10
--- MultiDOM.java 2001/10/18 12:40:44 1.9
+++ MultiDOM.java 2001/10/18 16:53:09 1.10
@@ -1,5 +1,5 @@
/*
- * @(#)$Id: MultiDOM.java,v 1.9 2001/10/18 12:40:44 morten Exp $
+ * @(#)$Id: MultiDOM.java,v 1.10 2001/10/18 16:53:09 morten Exp $
*
* The Apache Software License, Version 1.1
*
@@ -87,8 +87,6 @@
private Hashtable _documents = new Hashtable();
- private int _currentDOM = 0;
-
private final class AxisIterator implements NodeIterator {
// constitutive data
private final int _axis;
@@ -111,7 +109,7 @@
public NodeIterator setStartNode(final int node) {
_mask = node & SET;
- int dom = _currentDOM = node >>> 24;
+ int dom = node >>> 24;
// consider caching these
if ((_type == NO_TYPE) || (_type == DOM.ELEMENT)) {
_source = _adapters[dom].getAxisIterator(_axis);
@@ -155,13 +153,12 @@
}
public NodeIterator cloneIterator() {
- //!! not entirely good
- //!! not clear when cloning is performed
- // and what's the desired state of the new clone
- final NodeIterator clone = new AxisIterator(_axis, _type);
- //return clone.reset();
+ final AxisIterator clone = new AxisIterator(_axis, _type);
+ clone._source = _source.cloneIterator();
+ clone._mask = _mask;
return clone;
}
+
} // end of AxisIterator
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]