1 19 package org.netbeans.lib.jmi.query; 20 21 import java.util.Iterator ; 22 23 24 28 abstract class QueryIterator implements Iterator { 29 30 abstract public boolean hasNext(); 31 32 abstract public Object next(); 33 34 37 public void remove() { 38 throw new UnsupportedOperationException ( "MDR queries cannot be modified" ); 39 } 40 41 43 45 static class Delegate extends QueryIterator { 46 47 49 protected final Iterator ITERATOR; 50 51 public Delegate(Iterator iterator) { 52 super(); 53 this.ITERATOR = iterator; 54 } 55 56 public boolean hasNext() { 57 return ITERATOR.hasNext(); 58 } 59 60 public Object next() { 61 return ITERATOR.next(); 62 } 63 64 } 65 66 } 67 | Popular Tags |