The LineSegment type exposes the following members.

Constructors

  NameDescription
LineSegment
Initializes a new instance of the LineSegment class.

Methods

  NameDescription
DistanceToPoint
Calculate Euclidean distance between a point and a finite line segment.
Equals
Check if this instance of LineSegment equals to the specified one.
(Overrides Object..::.Equals(Object).)
GetHashCode
Get hash code for this instance.
(Overrides Object..::.GetHashCode()()().)
GetIntersectionWithOverloaded.
ToString
Get string representation of the class.
(Overrides Object..::.ToString()()().)

Operators

  NameDescription
Equality
Equality operator - checks if two line segments have equal parameters.
Explicit
Converts this LineSegment to a Line by discarding its endpoints and extending it infinitely in both directions.
Inequality
Inequality operator - checks if two lines have different parameters.

Properties

  NameDescription
End
End point of the line segment.
Length
Get segment's length - Euclidean distance between its Start and End points.
Start
Start point of the line segment.

See Also