Line2D

constructor()

Constructs and initializes a Line with coordinates (0, 0) -> (0, 0).

Since

1.2


constructor(p1: Point2D, p2: Point2D)

Constructs and initializes a Line2D from the specified Point2D objects.

Since

1.2

Parameters

p1

the start Point2D of this line segment

p2

the end Point2D of this line segment


constructor(x1: double, y1: double, x2: double, y2: double)

Constructs and initializes a Line2D from the specified coordinates.

Since

1.2

Parameters

x1

the X coordinate of the start point

y1

the Y coordinate of the start point

x2

the X coordinate of the end point

y2

the Y coordinate of the end point