Class RelationUtil.RelationObjectIterator<O>

  • All Implemented Interfaces:
    java.util.Iterator<O>
    Enclosing class:
    RelationUtil

    public static class RelationUtil.RelationObjectIterator<O>
    extends java.lang.Object
    implements java.util.Iterator<O>
    Iterator class that retrieves the given objects from the database.
    Author:
    Erich Schubert
    • Field Summary

      Fields 
      Modifier and Type Field Description
      (package private) Relation<? extends O> database
      The database we use.
      (package private) DBIDIter iter
      The real iterator.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      boolean hasNext()  
      O next()  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
      • Methods inherited from interface java.util.Iterator

        forEachRemaining, remove
    • Field Detail

      • iter

        final DBIDIter iter
        The real iterator.
      • database

        final Relation<? extends O> database
        The database we use.
    • Constructor Detail

      • RelationObjectIterator

        public RelationObjectIterator​(DBIDIter iter,
                                      Relation<? extends O> database)
        Full Constructor.
        Parameters:
        iter - Original iterator.
        database - Database
      • RelationObjectIterator

        public RelationObjectIterator​(Relation<? extends O> database)
        Simplified constructor.
        Parameters:
        database - Database
    • Method Detail

      • hasNext

        public boolean hasNext()
        Specified by:
        hasNext in interface java.util.Iterator<O>
      • next

        public O next()
        Specified by:
        next in interface java.util.Iterator<O>