contains

Tests if a given Point2D is inside the boundary of this Line2D. This method is required to implement the {@link Shape} interface, but in the case of Line2D objects it always returns false since a line contains no area.

Return

false because a Line2D contains no area.

Since

1.2

Parameters

p

the specified Point2D to be tested


Tests if the interior of this Line2D entirely contains the specified Rectangle2D. This method is required to implement the Shape interface, but in the case of Line2D objects it always returns false since a line contains no area.

Return

false because a Line2D contains no area.

Since

1.2

Parameters

r

the specified Rectangle2D to be tested


Tests if a specified coordinate is inside the boundary of this Line2D. This method is required to implement the {@link Shape} interface, but in the case of Line2D objects it always returns false since a line contains no area.

Return

false because a Line2D contains no area.

Since

1.2

Parameters

x

the X coordinate of the specified point to be tested

y

the Y coordinate of the specified point to be tested


fun contains(x: double, y: double, w: double, h: double): Boolean

Tests if the interior of this Line2D entirely contains the specified set of rectangular coordinates. This method is required to implement the Shape interface, but in the case of Line2D objects it always returns false since a line contains no area.

Return

false because a Line2D contains no area.

Since

1.2

Parameters

x

the X coordinate of the upper-left corner of the specified rectangular area

y

the Y coordinate of the upper-left corner of the specified rectangular area

w

the width of the specified rectangular area

h

the height of the specified rectangular area