Class EdgeIntersection
- Namespace
- NetTopologySuite.GeometriesGraph
- Assembly
- NetTopologySuite.dll
An EdgeIntersection represents a point on an edge which intersects with another edge. The intersection may either be a single point, or a line segment (in which case this point is the start of the line segment) The label attached to this intersection point applies to the edge from this point forwards, until the next intersection or the end of the edge. The intersection point must be precise.
public class EdgeIntersection : IComparable
- Inheritance
-
EdgeIntersection
- Implements
- Inherited Members
Constructors
EdgeIntersection(Coordinate, int, double)
Creates an instance of this class
public EdgeIntersection(Coordinate coord, int segmentIndex, double dist)
Parameters
coord
CoordinateThe point of intersection
segmentIndex
intThe index of the containing line segment in the parent edge
dist
doubleThe edge distance or this point along the containing line segment
Properties
Coordinate
The point of intersection.
public Coordinate Coordinate { get; }
Property Value
Distance
The edge distance of this point along the containing line segment.
public double Distance { get; }
Property Value
SegmentIndex
The index of the containing line segment in the parent edge.
public int SegmentIndex { get; }
Property Value
Methods
Compare(int, double)
Comparison with segment and distance.
public int Compare(int segmentIndex, double dist)
Parameters
segmentIndex
intThe index of the containing line segment
dist
doubleThe distance of this point along the containing line segment
Returns
- int
-1
this EdgeIntersection is located before the argument location,0
this EdgeIntersection is at the argument location,1
this EdgeIntersection is located after the argument location.
CompareTo(object)
public int CompareTo(object obj)
Parameters
obj
object
Returns
IsEndPoint(int)
public bool IsEndPoint(int maxSegmentIndex)
Parameters
maxSegmentIndex
int
Returns
ToString()
public override string ToString()
Returns
Write(StreamWriter)
public void Write(StreamWriter outstream)
Parameters
outstream
StreamWriter