com.fasterxml.aalto.util

## Class SingletonIterator

- java.lang.Object
- - com.fasterxml.aalto.util.SingletonIterator

- All Implemented Interfaces:
    Iterator<String>

      public final class SingletonIterator
      extends Object
      implements Iterator<String>

  Simple read-only iterator that iterators over one specific item, passed in as constructor argument.

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `SingletonIterator(String value)`

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `boolean` | `hasNext()`
    `String` | `next()`
    `void` | `remove()`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### SingletonIterator

          public SingletonIterator(String value)

  - ### Method Detail

    - #### hasNext

          public boolean hasNext()

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

    - #### next

          public String next()

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

    - #### remove

          public void remove()

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

Copyright © 2018 FasterXML. All rights reserved.