Interface Shape
- All Known Implementing Classes:
Circle, Line, Polygon, Rect, SegmentedLine
public interface Shape
Shared interface for all two-dimensional shapes. Shapes use coordinates
with float precision, and instances are immutable.
-
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptionbooleanReturns whether this shape contains the specified point.Returns the smallest possible rectangular bounding box that can fit this shape.default Shapereposition(float offsetX, float offsetY) Returns a newShapeinstance that is repositioned by the specified X and Y offset.reposition(Point2D offset) Returns a newShapeinstance that is repositioned by the specified offset.
-
Field Details
-
EPSILON
static final float EPSILON- See Also:
-
-
Method Details