Class PathIteratorAdapter.GeomIterator

java.lang.Object
org.apache.sis.internal.feature.jts.PathIteratorAdapter.GeomIterator
All Implemented Interfaces:
Iterator<org.locationtech.jts.geom.CoordinateSequence>
Enclosing class:
PathIteratorAdapter

private static final class PathIteratorAdapter.GeomIterator extends Object implements Iterator<org.locationtech.jts.geom.CoordinateSequence>
An iterator over the coordinate sequences of a geometry collection.
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    private final org.locationtech.jts.geom.GeometryCollection
    The collection for which to return geometries.
    private Iterator<org.locationtech.jts.geom.CoordinateSequence>
    Coordinate sequences of the current geometry.
    private int
    Index of current geometry.
  • Constructor Summary

    Constructors
    Constructor
    Description
    GeomIterator(org.locationtech.jts.geom.GeometryCollection collection)
    Created a new iterator for the given collection.
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
    Returns true if there is more sequences to return.
    org.locationtech.jts.geom.CoordinateSequence
    Returns the coordinate sequence of the next geometry.

    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 Details

    • collection

      private final org.locationtech.jts.geom.GeometryCollection collection
      The collection for which to return geometries.
    • index

      private int index
      Index of current geometry.
    • current

      private Iterator<org.locationtech.jts.geom.CoordinateSequence> current
      Coordinate sequences of the current geometry.
  • Constructor Details

    • GeomIterator

      GeomIterator(org.locationtech.jts.geom.GeometryCollection collection)
      Created a new iterator for the given collection.
  • Method Details

    • hasNext

      public boolean hasNext()
      Returns true if there is more sequences to return.
      Specified by:
      hasNext in interface Iterator<org.locationtech.jts.geom.CoordinateSequence>
    • next

      public org.locationtech.jts.geom.CoordinateSequence next()
      Returns the coordinate sequence of the next geometry.
      Specified by:
      next in interface Iterator<org.locationtech.jts.geom.CoordinateSequence>