|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface ConstMapIterator
An iterator for a map.
The iterator points to a map entry when it's created so next()
shouldn't be called at the start of the
iteration.
Here's an example on how to iterate over a map:
for (ConstIterator iterator = map.constIterator(); iterator.atEntry(); iterator.next()) {
Object key = iterator.getKey();
Object value = iterator.getValue();
...
}
Method Summary | |
---|---|
boolean |
atEntry()
Returns true if the iterator points to an entry in the map. |
java.lang.Object |
getKey()
Returns the key at the current map entry. |
java.lang.Object |
getValue()
Returns the value at the current map entry. |
void |
next()
Advance the iterator to the next entry. |
Method Detail |
---|
java.lang.Object getKey()
java.lang.Object getValue()
void next()
boolean atEntry()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |