C# Class GeometryClassLibrary.LineListExtensions

ファイルを表示 Open project: ParagonTruss/GeometryClassLibrary

Public Methods

Method Description
AreAllCoplanar ( this passedLineList ) : bool

Returns true if all of the passed lines are in the same plane, false otherwise

AreAllParallel ( this passedLines ) : bool

checks to see whether every line is parallel

AsSegments ( this lineList, Distance lengthOfSegments ) : List
GeneratePolygonFromIntersectingLines ( this passedLines ) : Polygon

Defines a plane region using the given lines and where they intersect as long as the lines are all coplanar ToDo: Needs a unit test

LineWithLargestXInterceptIn2D ( this passedLines ) : Line

Returns the line with the largest x intercept on the 2D xy-plane. If two share the same intercept it returns the first line in the list with that segment

LineWithLargestYInterceptIn2D ( this passedLines ) : Line

Returns the line with the largest y intercept on the 2D xy-plane. If two share the same intercept it returns the first line in the list with that segment

LineWithLowestXInterceptIn2D ( this passedLines ) : Line

Returns the line with the smallest x intercept on the 2D xy-plane. If two share the same intercept it returns the first line in the list with that segment

LineWithSmallestYInterceptIn2D ( this passedLines ) : Line

Returns the line with the smallest y intercept on the 2D xy-plane. If two share the same intercept it returns the first line in the list with that segment

LineWithXInterceptIn2DClosestTo ( this passedLines, Distance pointToFindTheClosestInterceptTo ) : Line

Returns the line whose x intercept on the 2D xy-plane is closest to the given distance on the x-axis. If two share the same intercept it returns the first line in the list

LineWithXInterceptIn2DFarthestFrom ( this passedLines, Distance pointToFindTheFarthestInterceptTo ) : Line

Returns the line whose x intercept on the 2D xy-plane is farthest from the given distance on the x-axis. If two share the same intercept it returns the first line in the list

LineWithYInterceptIn2DClosestTo ( this passedLines, Distance pointToFindTheClosestInterceptTo ) : Line

Returns the line whose y intercept on the 2D xy-plane is closest to the given distance on the y-axis. If two share the same intercept it returns the first line in the list

LineWithYInterceptIn2DFarthestFrom ( this passedLines, Distance pointToFindTheFarthestInterceptTo ) : Line

Returns the line whose y intercept on the 2D xy-plane is farthest from the given distance on the y-axis. If two share the same intercept it returns the first line in the list

OnlyLinesParallelTo ( this passedLines, Line lineToCheckIfParallelTo ) : List

Sorts out and returns only the lines in this list that are parallel to the passed Line

Method Details

AreAllCoplanar() public static method

Returns true if all of the passed lines are in the same plane, false otherwise
public static AreAllCoplanar ( this passedLineList ) : bool
passedLineList this
return bool

AreAllParallel() public static method

checks to see whether every line is parallel
public static AreAllParallel ( this passedLines ) : bool
passedLines this passed List of Lines
return bool

AsSegments() public static method

public static AsSegments ( this lineList, Distance lengthOfSegments ) : List
lineList this
lengthOfSegments UnitClassLibrary.DistanceUnit.Distance
return List

GeneratePolygonFromIntersectingLines() public static method

Defines a plane region using the given lines and where they intersect as long as the lines are all coplanar ToDo: Needs a unit test
public static GeneratePolygonFromIntersectingLines ( this passedLines ) : Polygon
passedLines this
return Polygon

LineWithLargestXInterceptIn2D() public static method

Returns the line with the largest x intercept on the 2D xy-plane. If two share the same intercept it returns the first line in the list with that segment
public static LineWithLargestXInterceptIn2D ( this passedLines ) : Line
passedLines this The list of lines to find the largest x from
return Line

LineWithLargestYInterceptIn2D() public static method

Returns the line with the largest y intercept on the 2D xy-plane. If two share the same intercept it returns the first line in the list with that segment
public static LineWithLargestYInterceptIn2D ( this passedLines ) : Line
passedLines this The list of lines to find the largest y from
return Line

LineWithLowestXInterceptIn2D() public static method

Returns the line with the smallest x intercept on the 2D xy-plane. If two share the same intercept it returns the first line in the list with that segment
public static LineWithLowestXInterceptIn2D ( this passedLines ) : Line
passedLines this
return Line

LineWithSmallestYInterceptIn2D() public static method

Returns the line with the smallest y intercept on the 2D xy-plane. If two share the same intercept it returns the first line in the list with that segment
public static LineWithSmallestYInterceptIn2D ( this passedLines ) : Line
passedLines this The list of lines to find the smallest y from
return Line

LineWithXInterceptIn2DClosestTo() public static method

Returns the line whose x intercept on the 2D xy-plane is closest to the given distance on the x-axis. If two share the same intercept it returns the first line in the list
public static LineWithXInterceptIn2DClosestTo ( this passedLines, Distance pointToFindTheClosestInterceptTo ) : Line
passedLines this The list of lines to find the largest x from
pointToFindTheClosestInterceptTo UnitClassLibrary.DistanceUnit.Distance The value on the x-axis to find the line whose intercept is closest to
return Line

LineWithXInterceptIn2DFarthestFrom() public static method

Returns the line whose x intercept on the 2D xy-plane is farthest from the given distance on the x-axis. If two share the same intercept it returns the first line in the list
public static LineWithXInterceptIn2DFarthestFrom ( this passedLines, Distance pointToFindTheFarthestInterceptTo ) : Line
passedLines this The list of lines to find the farthest in x from
pointToFindTheFarthestInterceptTo UnitClassLibrary.DistanceUnit.Distance The value on the x-axis to find the line whose intercept is farthest from
return Line

LineWithYInterceptIn2DClosestTo() public static method

Returns the line whose y intercept on the 2D xy-plane is closest to the given distance on the y-axis. If two share the same intercept it returns the first line in the list
public static LineWithYInterceptIn2DClosestTo ( this passedLines, Distance pointToFindTheClosestInterceptTo ) : Line
passedLines this The list of lines to find the largest y from
pointToFindTheClosestInterceptTo UnitClassLibrary.DistanceUnit.Distance The value on the y-axis to find the line whose intercept is closest to
return Line

LineWithYInterceptIn2DFarthestFrom() public static method

Returns the line whose y intercept on the 2D xy-plane is farthest from the given distance on the y-axis. If two share the same intercept it returns the first line in the list
public static LineWithYInterceptIn2DFarthestFrom ( this passedLines, Distance pointToFindTheFarthestInterceptTo ) : Line
passedLines this The list of lines to find the fartherst in y from
pointToFindTheFarthestInterceptTo UnitClassLibrary.DistanceUnit.Distance The value on the y-axis to find the line whose intercept is fartherst from
return Line

OnlyLinesParallelTo() public static method

Sorts out and returns only the lines in this list that are parallel to the passed Line
public static OnlyLinesParallelTo ( this passedLines, Line lineToCheckIfParallelTo ) : List
passedLines this passed List of Lines
lineToCheckIfParallelTo Line passed List of Lines
return List