1 16 19 20 package com.sun.org.apache.xalan.internal.xsltc.dom; 21 22 import com.sun.org.apache.xml.internal.dtm.DTMAxisIterator; 23 import com.sun.org.apache.xml.internal.dtm.ref.DTMAxisIteratorBase; 24 25 30 public final class ClonedNodeListIterator extends DTMAxisIteratorBase { 31 32 35 private CachedNodeListIterator _source; 36 private int _index = 0; 37 38 public ClonedNodeListIterator(CachedNodeListIterator source) { 39 _source = source; 40 } 41 42 public void setRestartable(boolean isRestartable) { 43 } 46 47 public DTMAxisIterator setStartNode(int node) { 48 return this; 49 } 50 51 public int next() { 52 return _source.getNode(_index++); 53 } 54 55 public int getPosition() { 56 return _index == 0 ? 1 : _index; 57 } 58 59 public int getNodeByPosition(int pos) { 60 return _source.getNode(pos); 61 } 62 63 public DTMAxisIterator cloneIterator() { 64 return _source.cloneIterator(); 65 } 66 67 public DTMAxisIterator reset() { 68 _index = 0; 69 return this; 70 } 71 72 public void setMark() { 73 _source.setMark(); 74 } 75 76 public void gotoMark() { 77 _source.gotoMark(); 78 } 79 } 80 | Popular Tags |