Package org.geotools.geometry.jts
Class CircularString
Object
Geometry
LineString
CircularString
- All Implemented Interfaces:
Serializable,Cloneable,Comparable,CurvedGeometry<LineString>,SingleCurvedGeometry<LineString>,Lineal
A CircularString is a sequence of zero or more connected circular arc segments. A circular arc segment is a curved
segment defined by three points in a two-dimensional plane; the first point cannot be the same as the third point.
- Author:
- Andrea Aime - GeoSolutions
- See Also:
-
Field Summary
Fields inherited from class LineString
MINIMUM_VALID_SIZE, pointsFields inherited from class Geometry
envelope, factory, SRID, TYPECODE_GEOMETRYCOLLECTION, TYPECODE_LINEARRING, TYPECODE_LINESTRING, TYPECODE_MULTILINESTRING, TYPECODE_MULTIPOINT, TYPECODE_MULTIPOLYGON, TYPECODE_POINT, TYPECODE_POLYGON, TYPENAME_GEOMETRYCOLLECTION, TYPENAME_LINEARRING, TYPENAME_LINESTRING, TYPENAME_MULTILINESTRING, TYPENAME_MULTIPOINT, TYPENAME_MULTIPOLYGON, TYPENAME_POINT, TYPENAME_POLYGON -
Constructor Summary
ConstructorsConstructorDescriptionCircularString(double[] controlPoints, GeometryFactory factory, double tolerance) CircularString(CoordinateSequence points, GeometryFactory factory, double tolerance) -
Method Summary
Modifier and TypeMethodDescriptionvoidapply(CoordinateFilter filter) voidapply(CoordinateSequenceFilter filter) voidapply(GeometryComponentFilter filter) voidapply(GeometryFilter filter) buffer(double distance) buffer(double distance, int quadrantSegments) buffer(double distance, int quadrantSegments, int endCapStyle) intintcompareTo(Object o, CoordinateSequenceComparator comp) protected Envelopebooleanprotected CircularStringbooleanbooleanbooleandifference(Geometry other) booleandoublebooleanbooleanbooleanequalsExact(Geometry other) booleanequalsExact(Geometry other, double tolerance) booleanbooleanequalsTopo(Geometry other) voidgetArcN(int arcIndex) Returns the n-th circular arc making up the geometrydoublegetArea()intdouble[]Returns the control points for this string/ring.getCoordinateN(int n) intReturns the dimension of the geometry without forcing access to the coordinate sequenceintgetGeometryN(int n) doublegetLinearizedCoordinateSequence(double tolerance) Returns the linearized coordinates at the given toleranceintNumber of arc circlesintintgetPointN(int n) intgetSRID()doubleThe default linearization toleranceinthashCode()intersection(Geometry other) booleanbooleanisClosed()booleanbooleanisEmpty()booleanbooleanisRing()booleanisSimple()booleanisValid()booleanisWithinDistance(Geometry geom, double distance) Linearizes the geometry using the built-in linearization tolerancelinearize(double tolerance) Linearizes the geometry using the provided tolerance, the result is guaranteed to be less than tolerance away from the curved geometry unless the number of points needed to linearize the geometry exceeds the build-in per quadrant maximum, seeCircularArc.MAX_SEGMENTS_QUADRANTnorm()voidbooleanbooleanreverse()protected CircularStringvoidsetSRID(int SRID) voidsetUserData(Object userData) symDifference(Geometry other) Parallel method toGeometry.toText()that will output the geometry as curved instead of as lineartoString()toText()booleanunion()booleanMethods inherited from class LineString
clone, compareToSameClass, compareToSameClass, getTypeCode, isEquivalentClassMethods inherited from class Geometry
compare, copy, equal, geometryChangedAction, hasDimension, hasNonEmptyElements, hasNullElements, isGeometryCollection
-
Constructor Details
-
CircularString
-
CircularString
-
-
Method Details
-
getControlPoints
public double[] getControlPoints()Description copied from interface:SingleCurvedGeometryReturns the control points for this string/ring.- Specified by:
getControlPointsin interfaceSingleCurvedGeometry<LineString>
-
getTolerance
public double getTolerance()Description copied from interface:CurvedGeometryThe default linearization tolerance- Specified by:
getTolerancein interfaceCurvedGeometry<LineString>
-
getNumArcs
public int getNumArcs()Description copied from interface:SingleCurvedGeometryNumber of arc circles- Specified by:
getNumArcsin interfaceSingleCurvedGeometry<LineString>
-
getArcN
Description copied from interface:SingleCurvedGeometryReturns the n-th circular arc making up the geometry- Specified by:
getArcNin interfaceSingleCurvedGeometry<LineString>
-
linearize
Description copied from interface:CurvedGeometryLinearizes the geometry using the built-in linearization tolerance- Specified by:
linearizein interfaceCurvedGeometry<LineString>
-
linearize
Description copied from interface:CurvedGeometryLinearizes the geometry using the provided tolerance, the result is guaranteed to be less than tolerance away from the curved geometry unless the number of points needed to linearize the geometry exceeds the build-in per quadrant maximum, seeCircularArc.MAX_SEGMENTS_QUADRANT- Specified by:
linearizein interfaceCurvedGeometry<LineString>- Parameters:
tolerance- Linearization tolerance, should be zero or positive. When zero is used, the maximum number of allowed linearization points will be used, seeCircularArc.MAX_SEGMENTS_QUADRANT
-
getLinearizedCoordinateSequence
Description copied from interface:SingleCurvedGeometryReturns the linearized coordinates at the given tolerance- Specified by:
getLinearizedCoordinateSequencein interfaceSingleCurvedGeometry<LineString>
-
isClosed
public boolean isClosed()- Overrides:
isClosedin classLineString
-
getDimension
public int getDimension()- Overrides:
getDimensionin classLineString
-
getBoundaryDimension
public int getBoundaryDimension()- Overrides:
getBoundaryDimensionin classLineString
-
isEmpty
public boolean isEmpty()- Overrides:
isEmptyin classLineString
-
getGeometryType
- Overrides:
getGeometryTypein classLineString
-
reverse
- Overrides:
reversein classLineString
-
reverseInternal
- Overrides:
reverseInternalin classLineString
-
getInteriorPoint
- Overrides:
getInteriorPointin classGeometry
-
getEnvelope
- Overrides:
getEnvelopein classGeometry
-
getEnvelopeInternal
- Overrides:
getEnvelopeInternalin classGeometry
-
computeEnvelopeInternal
- Overrides:
computeEnvelopeInternalin classLineString
-
getNumGeometries
public int getNumGeometries()- Overrides:
getNumGeometriesin classGeometry
-
getGeometryN
- Overrides:
getGeometryNin classGeometry
-
setUserData
- Overrides:
setUserDatain classGeometry
-
getSRID
public int getSRID() -
setSRID
public void setSRID(int SRID) -
getFactory
- Overrides:
getFactoryin classGeometry
-
getUserData
- Overrides:
getUserDatain classGeometry
-
getPrecisionModel
- Overrides:
getPrecisionModelin classGeometry
-
isRectangle
public boolean isRectangle()- Overrides:
isRectanglein classGeometry
-
equalsExact
- Overrides:
equalsExactin classGeometry
-
equalsExact
- Overrides:
equalsExactin classLineString
-
equals
-
equalsTopo
- Overrides:
equalsTopoin classGeometry
-
equals
-
hashCode
public int hashCode() -
toString
-
toCurvedText
Description copied from interface:CurvedGeometryParallel method toGeometry.toText()that will output the geometry as curved instead of as linear- Specified by:
toCurvedTextin interfaceCurvedGeometry<LineString>
-
equalsNorm
- Overrides:
equalsNormin classGeometry
-
getPointN
- Overrides:
getPointNin classLineString
-
getStartPoint
- Overrides:
getStartPointin classLineString
-
getEndPoint
- Overrides:
getEndPointin classLineString
-
getCoordinates
- Overrides:
getCoordinatesin classLineString
-
getCoordinateSequence
- Overrides:
getCoordinateSequencein classLineString
-
getCoordinateN
- Overrides:
getCoordinateNin classLineString
-
getCoordinate
- Overrides:
getCoordinatein classLineString
-
getNumPoints
public int getNumPoints()- Overrides:
getNumPointsin classLineString
-
isRing
public boolean isRing()- Overrides:
isRingin classLineString
-
getLength
public double getLength()- Overrides:
getLengthin classLineString
-
getBoundary
- Overrides:
getBoundaryin classLineString
-
isCoordinate
- Overrides:
isCoordinatein classLineString
-
apply
- Overrides:
applyin classLineString
-
apply
- Overrides:
applyin classLineString
-
apply
- Overrides:
applyin classLineString
-
apply
- Overrides:
applyin classLineString
-
copyInternal
- Overrides:
copyInternalin classLineString
-
normalize
public void normalize()- Overrides:
normalizein classLineString
-
isSimple
public boolean isSimple() -
isValid
public boolean isValid() -
distance
-
isWithinDistance
- Overrides:
isWithinDistancein classGeometry
-
getArea
public double getArea() -
getCentroid
- Overrides:
getCentroidin classGeometry
-
geometryChanged
public void geometryChanged()- Overrides:
geometryChangedin classGeometry
-
disjoint
-
touches
-
intersects
- Overrides:
intersectsin classGeometry
-
crosses
-
within
-
contains
-
overlaps
-
covers
-
coveredBy
-
relate
-
relate
-
buffer
-
buffer
-
buffer
-
convexHull
- Overrides:
convexHullin classGeometry
-
intersection
- Overrides:
intersectionin classGeometry
-
union
-
difference
- Overrides:
differencein classGeometry
-
symDifference
- Overrides:
symDifferencein classGeometry
-
union
-
norm
-
compareTo
- Specified by:
compareToin interfaceComparable- Overrides:
compareToin classGeometry
-
compareTo
-
toText
-
getCoordinatesDimension
public int getCoordinatesDimension()Description copied from interface:CurvedGeometryReturns the dimension of the geometry without forcing access to the coordinate sequence- Specified by:
getCoordinatesDimensionin interfaceCurvedGeometry<LineString>
-