Class LinearRing

java.lang.Object
uk.ac.starlink.tfcat.LinearRing

public class LinearRing extends Object
Represents a linear ring as defined in the TFCat specification (from the GeoJSON specification).
Since:
9 Feb 2022
Author:
Mark Taylor
  • Constructor Details

    • LinearRing

      protected LinearRing(Position[] distinctPositions)
      Constructor.
      Parameters:
      distinctPositions - positions defining the ring; the last one is not a duplicate of the first
  • Method Details

    • getDistinctPositions

      public Position[] getDistinctPositions()
      Returns an array of the positions defining this ring; the last one is not a duplicate of the first.
      Returns:
      array of distinct positions, length of the number of vertices
    • isClockwise

      public boolean isClockwise()
      Indicates the winding direction for this ring.
      Returns:
      true for clockwise winding direction, false for anticlockwise