Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.apache.commons.math.util
Class OpenIntToFieldHashMap.Iterator

    java.lang.Object
      org.apache.commons.math.util.OpenIntToFieldHashMap.Iterator

Enclosing class:
  OpenIntToFieldHashMap<T extends FieldElement<T>>

    public class OpenIntToFieldHashMap.Iterator

extends java.lang.Object

Iterator class for the map.

Field Summary
`private int` | `current` Index of current element.
`private int` | `next` Index of next element.
`private int` | `referenceCount` Reference modification count.

Constructor Summary
`private` | `OpenIntToFieldHashMap.Iterator()` Simple constructor.

Method Summary
`void` | `advance()` Advance iterator one step further.
`boolean` | `hasNext()` Check if there is a next element in the map.
`int` | `key()` Get the key of current entry.
`T` | `value()` Get the value of current entry.

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### referenceCount

    private final int referenceCount

  Reference modification count.

### current

    private int current

  Index of current element.

### next

    private int next

  Index of next element.

Constructor Detail

### OpenIntToFieldHashMap.Iterator

    private OpenIntToFieldHashMap.Iterator()

  Simple constructor.

Method Detail

### hasNext

    public boolean hasNext()

  Check if there is a next element in the map.

  Returns:
    true if there is a next element

### key

    public int key()
            throws java.util.ConcurrentModificationException,
                   java.util.NoSuchElementException

  Get the key of current entry.

  Returns:
    key of current entry
  Throws:
    `java.util.ConcurrentModificationException` - if the map is modified during iteration
    `java.util.NoSuchElementException` - if there is no element left in the map

### value

    public T value()
                                    throws java.util.ConcurrentModificationException,
                                           java.util.NoSuchElementException

  Get the value of current entry.

  Returns:
    value of current entry
  Throws:
    `java.util.ConcurrentModificationException` - if the map is modified during iteration
    `java.util.NoSuchElementException` - if there is no element left in the map

### advance

    public void advance()
                 throws java.util.ConcurrentModificationException,
                        java.util.NoSuchElementException

  Advance iterator one step further.

  Throws:
    `java.util.ConcurrentModificationException` - if the map is modified during iteration
    `java.util.NoSuchElementException` - if there is no element left in the map

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright (c) 2003-2011 Apache Software Foundation