Package io.github.sebasbaumh.postgis
Class Curve
- java.lang.Object
-
- io.github.sebasbaumh.postgis.Geometry
-
- io.github.sebasbaumh.postgis.Curve
-
- All Implemented Interfaces:
LineBasedGeometry,java.io.Serializable
- Direct Known Subclasses:
CompoundCurve,LineString
@NonNullByDefault public abstract class Curve extends Geometry implements LineBasedGeometry
Base class for simple curves likeLineStrings and complex classes likeCompoundCurves.- Author:
- Sebastian Baumhekel
- See Also:
- Serialized Form
-
-
Field Summary
-
Fields inherited from class io.github.sebasbaumh.postgis.Geometry
UNKNOWN_SRID
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedCurve(int type)Constructor for subclasses.
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description abstract voidclose()Closes thisCurveif the last coordinate is not already the same as the first coordinate.booleanisClockwise()Checks if this ring is oriented in clockwise direction.booleanisClosed()Checks if this line is closed, so the last coordinate is the same as the first coordinate.abstract voidreverse()Reverses this linestring.-
Methods inherited from class io.github.sebasbaumh.postgis.Geometry
checkConsistency, equals, getCoordinates, getDimension, getNumberOfCoordinates, getSrid, getType, hashCode, hasMeasure, is3d, isEmpty, numPoints, setSrid
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface io.github.sebasbaumh.postgis.LineBasedGeometry
getEndPoint, getStartPoint, length
-
-
-
-
Method Detail
-
close
public abstract void close()
Closes thisCurveif the last coordinate is not already the same as the first coordinate.
-
isClockwise
public boolean isClockwise()
Checks if this ring is oriented in clockwise direction.- Returns:
- true on success, else false
-
isClosed
public boolean isClosed()
Description copied from interface:LineBasedGeometryChecks if this line is closed, so the last coordinate is the same as the first coordinate.- Specified by:
isClosedin interfaceLineBasedGeometry- Returns:
- true on success, else false
-
reverse
public abstract void reverse()
Reverses this linestring.
-
-