Class FacetSequence
- Namespace
- NetTopologySuite.Operation.Distance
- Assembly
- NetTopologySuite.dll
Represents a sequence of facets (points or line segments) of a Geometry specified by a subsequence of a CoordinateSequence.
public class FacetSequence
- Inheritance
-
FacetSequence
- Inherited Members
Constructors
FacetSequence(CoordinateSequence, int)
Creates a new sequence for a single point from a CoordinateSequence.
public FacetSequence(CoordinateSequence pts, int index)
Parameters
ptsCoordinateSequenceThe sequence containing the facet point.
indexintthe index of the point
FacetSequence(CoordinateSequence, int, int)
Creates a new sequence of facets based on a CoordinateSequence.
public FacetSequence(CoordinateSequence pts, int start, int end)
Parameters
ptsCoordinateSequenceThe sequence containing facet points.
startintThe index of the start point
endintThe index of the end point + 1
FacetSequence(Geometry, CoordinateSequence, int, int)
Creates a new sequence of facets based on a CoordinateSequence contained in the given Geometry.
public FacetSequence(Geometry geom, CoordinateSequence pts, int start, int end)
Parameters
geomGeometryThe geometry containing the facets.
ptsCoordinateSequenceThe sequence containing the facet points.
startintThe index of the start point.
endintThe index of the end point.
Properties
Count
Gets the number of coordinates in this facet sequence
public int Count { get; }
Property Value
Envelope
Gets the envelope of this facet sequence
public Envelope Envelope { get; }
Property Value
IsPoint
Tests if this facet sequence consists of only one point
public bool IsPoint { get; }
Property Value
Methods
Distance(FacetSequence)
Computes the distance between this and another FacetSequence.
public double Distance(FacetSequence facetSeq)
Parameters
facetSeqFacetSequenceThe sequence to compute the distance to.
Returns
- double
The minimum distance between the sequences.
GetCoordinate(int)
Gets the coordinate at the given index
public Coordinate GetCoordinate(int index)
Parameters
indexintThe index
Returns
- Coordinate
The coordinate at the given index
NearestLocations(FacetSequence)
Computes the locations of the nearest points between this sequence and another sequence. The locations are presented in the same order as the input sequences.
public GeometryLocation[] NearestLocations(FacetSequence facetSeq)
Parameters
facetSeqFacetSequence
Returns
- GeometryLocation[]
A pair of GeometryLocations for the nearest points.
ToString()
public override string ToString()