Class EmptyIterable<T>

java.lang.Object
de.renebergelt.quiterables.iterators.EmptyIterable<T>
Type Parameters:
T - Type of the elements in this Iterable
All Implemented Interfaces:
Iterable<T>

public class EmptyIterable<T> extends Object implements Iterable<T>
An iterable implementation which cotnains no elements
Author:
René Bergelt
  • Method Details

    • getInstance

      public static EmptyIterable getInstance()
      Return an instance of the EmptyIterable class (Internally always uses the same instance)
      Returns:
      The default EmptyIterable
    • iterator

      public Iterator<T> iterator()
      Specified by:
      iterator in interface Iterable<T>