public int next () { if (!hasNext) throw new NoSuchElementException(); int key = nextIndex == INDEX_ZERO ? 0 : map.keyTable[nextIndex]; currentIndex = nextIndex; findNextIndex(); return key; }
/** Returns an iterator for the keys in the map. Remove is supported. Note that the same iterator instance is returned each * time this method is called. Use the {@link Entries} constructor for nested or multithreaded iteration. */ public Keys keys () { return new Keys(this); }
public int next () { if (!hasNext) throw new NoSuchElementException(); int key = nextIndex == INDEX_ZERO ? 0 : map.keyTable[nextIndex]; currentIndex = nextIndex; findNextIndex(); return key; }
public int next () { if (!hasNext) throw new NoSuchElementException(); int key = nextIndex == INDEX_ZERO ? 0 : map.keyTable[nextIndex]; currentIndex = nextIndex; findNextIndex(); return key; }
/** Returns an iterator for the keys in the map. Remove is supported. Note that the same iterator instance is returned each * time this method is called. Use the {@link Entries} constructor for nested or multithreaded iteration. */ public Keys keys () { return new Keys(this); }
/** Returns a new array containing the remaining keys. */ public IntArray toArray () { IntArray array = new IntArray(true, map.size); while (hasNext) array.add(next()); return array; } }
/** Returns a new array containing the remaining keys. */ public IntArray toArray () { IntArray array = new IntArray(true, map.size); while (hasNext) array.add(next()); return array; } }
/** Returns a new array containing the remaining keys. */ public IntArray toArray () { IntArray array = new IntArray(true, map.size); while (hasNext) array.add(next()); return array; } }
/** Returns an iterator for the keys in the map. Remove is supported. Note that the same iterator instance is returned each time * this method is called. Use the {@link Entries} constructor for nested or multithreaded iteration. */ public Keys keys () { return new Keys(this); }