@Test public void iterator() { final LongLinkedHashSet tested = new LongLinkedHashSet(); for (long i = 0; i < 10000; ++i) { tested.add(i); } long i = 0; for (Long key : tested) { Assert.assertEquals(i++, key.longValue()); tested.remove(key); } Assert.assertEquals(0, tested.size()); }
@Override public @NotNull LongIterator iterator() { return new LinkedHashIterator(); }
LongLinkedHashSet extends AbstractSet<Long> implements LongSet { @Override public @NotNull LongIterator iterator() { return new LinkedHashIterator(); } }
LongLinkedHashSet extends AbstractSet<Long> implements LongSet { @Override public @NotNull LongIterator iterator() { return new LinkedHashIterator(); } LongLinkedHashSet();  LongLinkedHashSet(int capacity);  LongLinkedHashSet(int capacity, float loadFactor); }
LongLinkedHashSet extends AbstractSet<Long> implements LongSet { @Override public @NotNull LongIterator iterator() { return new LinkedHashIterator(); } LongLinkedHashSet();  LongLinkedHashSet(int capacity);  LongLinkedHashSet(int capacity, float loadFactor); @Override int size(); @Override long[] toLongArray(); @Override boolean contains(final long key); @Override boolean contains(final Object key); @Override boolean add(final long key); @Override boolean add(Long key); @Override boolean remove(final long key); @Override boolean remove(Object key); @Override @NotNull LongIterator iterator(); }
LongLinkedHashSet extends AbstractSet<Long> implements LongSet { @Override public @NotNull LongIterator iterator() { return new LinkedHashIterator(); } LongLinkedHashSet();  LongLinkedHashSet(int capacity);  LongLinkedHashSet(int capacity, float loadFactor); @Override int size(); @Override long[] toLongArray(); @Override boolean contains(final long key); @Override boolean contains(final Object key); @Override boolean add(final long key); @Override boolean add(Long key); @Override boolean remove(final long key); @Override boolean remove(Object key); @Override @NotNull LongIterator iterator();  }