public abstract class Rectangle2D extends RectangularShape
Modifier and Type | Class and Description |
---|---|
static class |
Rectangle2D.Double |
static class |
Rectangle2D.Float |
Modifier and Type | Field and Description |
---|---|
static int |
OUT_BOTTOM |
static int |
OUT_LEFT |
static int |
OUT_RIGHT |
static int |
OUT_TOP |
Modifier | Constructor and Description |
---|---|
protected |
Rectangle2D() |
Modifier and Type | Method and Description |
---|---|
void |
add(double x, double y) |
void |
add(Point2D p) |
void |
add(Rectangle2D r) |
boolean |
contains(double x, double y) |
boolean |
contains(double x, double y, double width, double height) |
abstract Rectangle2D |
createIntersection(Rectangle2D r) |
abstract Rectangle2D |
createUnion(Rectangle2D r) |
boolean |
equals(Object obj) |
Rectangle2D |
getBounds2D() |
PathIterator |
getPathIterator(AffineTransform t) |
PathIterator |
getPathIterator(AffineTransform t, double flatness) |
int |
hashCode() |
static void |
intersect(Rectangle2D src1, Rectangle2D src2, Rectangle2D dst) |
boolean |
intersects(double x, double y, double width, double height) |
boolean |
intersectsLine(double x1, double y1, double x2, double y2) |
boolean |
intersectsLine(Line2D l) |
abstract int |
outcode(double x, double y) |
int |
outcode(Point2D p) |
void |
setFrame(double x, double y, double width, double height) |
abstract void |
setRect(double x, double y, double width, double height) |
void |
setRect(Rectangle2D r) |
static void |
union(Rectangle2D src1, Rectangle2D src2, Rectangle2D dst) |
clone, contains, contains, getBounds, getCenterX, getCenterY, getFrame, getHeight, getMaxX, getMaxY, getMinX, getMinY, getWidth, getX, getY, intersects, isEmpty, setFrame, setFrame, setFrameFromCenter, setFrameFromCenter, setFrameFromDiagonal, setFrameFromDiagonal
public static final int OUT_LEFT
public static final int OUT_TOP
public static final int OUT_RIGHT
public static final int OUT_BOTTOM
public abstract void setRect(double x, double y, double width, double height)
public abstract int outcode(double x, double y)
public abstract Rectangle2D createIntersection(Rectangle2D r)
public abstract Rectangle2D createUnion(Rectangle2D r)
public void setRect(Rectangle2D r)
public void setFrame(double x, double y, double width, double height)
setFrame
in class RectangularShape
public Rectangle2D getBounds2D()
public boolean intersectsLine(double x1, double y1, double x2, double y2)
public boolean intersectsLine(Line2D l)
public int outcode(Point2D p)
public boolean contains(double x, double y)
public boolean intersects(double x, double y, double width, double height)
public boolean contains(double x, double y, double width, double height)
public static void intersect(Rectangle2D src1, Rectangle2D src2, Rectangle2D dst)
public static void union(Rectangle2D src1, Rectangle2D src2, Rectangle2D dst)
public void add(double x, double y)
public void add(Point2D p)
public void add(Rectangle2D r)
public PathIterator getPathIterator(AffineTransform t)
public PathIterator getPathIterator(AffineTransform t, double flatness)
getPathIterator
in interface Shape
getPathIterator
in class RectangularShape
Copyright © 1998–2019. All rights reserved.