home *** CD-ROM | disk | FTP | other *** search
- package java.util;
-
- import java.lang.ref.Reference;
-
- class WeakHashMap$1 implements Iterator {
- Iterator hashIterator;
- WeakHashMap.Entry next;
- // $FF: synthetic field
- private final WeakHashMap.EntrySet this$1;
-
- WeakHashMap$1(WeakHashMap.EntrySet var1) {
- this.this$1 = var1;
- this.hashIterator = this.this$1.hashEntrySet.iterator();
- this.next = null;
- }
-
- public boolean hasNext() {
- while(this.hashIterator.hasNext()) {
- Map.Entry var1 = (Map.Entry)this.hashIterator.next();
- WeakHashMap.WeakKey var2 = (WeakHashMap.WeakKey)var1.getKey();
- Object var3 = null;
- if (var2 == null || (var3 = ((Reference)var2).get()) != null) {
- this.next = new WeakHashMap.Entry(var1, var3);
- return true;
- }
- }
-
- return false;
- }
-
- public Object next() {
- if (this.next == null && !this.hasNext()) {
- throw new NoSuchElementException();
- } else {
- WeakHashMap.Entry var1 = this.next;
- this.next = null;
- return var1;
- }
- }
-
- public void remove() {
- this.hashIterator.remove();
- }
- }
-