1 2 17 20 package com.sun.org.apache.xml.internal.dtm.ref; 21 22 import com.sun.org.apache.xml.internal.dtm.DTMAxisIterator; 23 import com.sun.org.apache.xml.internal.dtm.DTM; 24 25 26 29 public final class EmptyIterator implements DTMAxisIterator 30 { 31 private static final EmptyIterator INSTANCE = new EmptyIterator(); 32 33 public static DTMAxisIterator getInstance() {return INSTANCE;} 34 35 private EmptyIterator(){} 36 37 public final int next(){ return END; } 38 39 public final DTMAxisIterator reset(){ return this; } 40 41 public final int getLast(){ return 0; } 42 43 public final int getPosition(){ return 1; } 44 45 public final void setMark(){} 46 47 public final void gotoMark(){} 48 49 public final DTMAxisIterator setStartNode(int node){ return this; } 50 51 public final int getStartNode(){ return END; } 52 53 public final boolean isReverse(){return false;} 54 55 public final DTMAxisIterator cloneIterator(){ return this; } 56 57 public final void setRestartable(boolean isRestartable) {} 58 59 public final int getNodeByPosition(int position){ return END; } 60 } 61 | Popular Tags |