001package headfirst.composite.menuiterator;
002
003import java.util.Iterator;
004
005@SuppressWarnings("rawtypes")
006public class NullIterator implements Iterator {
007
008        public Object next() {
009                return null;
010        }
011
012        public boolean hasNext() {
013                return false;
014        }
015
016        public void remove() {
017                throw new UnsupportedOperationException();
018        }
019}