org.geotools.geometry.jts
Class LineIterator2

Object
  extended by LineIterator2
All Implemented Interfaces:
PathIterator

public final class LineIterator2
extends Object
implements PathIterator

A path iterator for the LiteShape class, specialized to iterate over LineString object.

Author:
Andrea Aime, simone giannecchini
Module:

Field Summary
 
Fields inherited from interface PathIterator
SEG_CLOSE, SEG_CUBICTO, SEG_LINETO, SEG_MOVETO, SEG_QUADTO, WIND_EVEN_ODD, WIND_NON_ZERO
 
Constructor Summary
LineIterator2()
           
 
Method Summary
 int currentSegment(double[] coords)
           
 int currentSegment(float[] coords)
           
 int getWindingRule()
          Returns the winding rule for determining the interior of the path.
 void init(LineString ls, AffineTransform at)
           
 boolean isDone()
          Tests if the iteration is complete.
 void next()
          Moves the iterator to the next segment of the path forwards along the primary direction of traversal as long as there are more points in that direction.
 
Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

LineIterator2

public LineIterator2()
Method Detail

currentSegment

public int currentSegment(float[] coords)
Specified by:
currentSegment in interface PathIterator
See Also:
PathIterator.currentSegment(float[])

init

public void init(LineString ls,
                 AffineTransform at)
Parameters:
ls -
at -

getWindingRule

public int getWindingRule()
Returns the winding rule for determining the interior of the path.

Specified by:
getWindingRule in interface PathIterator
Returns:
the winding rule.
See Also:
PathIterator.WIND_EVEN_ODD, PathIterator.WIND_NON_ZERO

isDone

public boolean isDone()
Tests if the iteration is complete.

Specified by:
isDone in interface PathIterator
Returns:
true if all the segments have been read; false otherwise.

next

public void next()
Moves the iterator to the next segment of the path forwards along the primary direction of traversal as long as there are more points in that direction.

Specified by:
next in interface PathIterator

currentSegment

public int currentSegment(double[] coords)
Specified by:
currentSegment in interface PathIterator
See Also:
PathIterator.currentSegment(double[])


Copyright © 1996-2009 Geotools. All Rights Reserved.