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

## com.fasterxml.aalto.util
Class EmptyIterator<T>

    java.lang.Object
      com.fasterxml.aalto.util.EmptyIterator<T>

All Implemented Interfaces:
  Iterator<T>

    public final class EmptyIterator<T>

extends Object
implements Iterator<T>

Simple implementation of "null iterator", iterator that has nothing to iterate over.

Method Summary
`static
`<T> EmptyIterator<T>`
` | `getInstance()` Since the actual type has no effect (as this iterator never returns any value objects), we can just cast away here: bit unclean, but safe.
`boolean` | `hasNext()`
`T` | `next()`
`void` | `remove()`

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

Method Detail

### getInstance

    public static <T> EmptyIterator<T> getInstance()

  Since the actual type has no effect (as this iterator never returns any value objects), we can just cast away here: bit unclean, but safe.

### hasNext

    public boolean hasNext()

  Specified by:
    `hasNext` in interface `Iterator<T>`

### next

    public T next()

  Specified by:
    `next` in interface `Iterator<T>`

### remove

    public void remove()

  Specified by:
    `remove` in interface `Iterator<T>`

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

Copyright © 2012 Fasterxml.com. All Rights Reserved.