java.lang.Object
org.jfree.chart.ui.RectangleEdge
- All Implemented Interfaces:
Serializable
Used to indicate the edge of a rectangle.
- See Also:
-
Field Summary
Modifier and TypeFieldDescriptionstatic final RectangleEdge
Bottom.static final RectangleEdge
Left.static final RectangleEdge
Right.static final RectangleEdge
Top. -
Method Summary
Modifier and TypeMethodDescriptionstatic double
coordinate
(Rectangle2D rectangle, RectangleEdge edge) Returns the x or y coordinate of the specified edge.boolean
Returnstrue
if this object is equal to the specified object, andfalse
otherwise.int
hashCode()
Returns a hash code value for the object.static boolean
isLeftOrRight
(RectangleEdge edge) Returnstrue
if the edge isLEFT
orRIGHT
, andfalse
otherwise.static boolean
isTopOrBottom
(RectangleEdge edge) Returnstrue
if the edge isTOP
orBOTTOM
, andfalse
otherwise.static RectangleEdge
opposite
(RectangleEdge edge) Returns the opposite edge.toString()
Returns a string representing the object.
-
Field Details
-
TOP
Top. -
BOTTOM
Bottom. -
LEFT
Left. -
RIGHT
Right.
-
-
Method Details
-
toString
Returns a string representing the object. -
equals
Returnstrue
if this object is equal to the specified object, andfalse
otherwise. -
hashCode
public int hashCode()Returns a hash code value for the object. -
isTopOrBottom
Returnstrue
if the edge isTOP
orBOTTOM
, andfalse
otherwise.- Parameters:
edge
- the edge.- Returns:
- A boolean.
-
isLeftOrRight
Returnstrue
if the edge isLEFT
orRIGHT
, andfalse
otherwise.- Parameters:
edge
- the edge.- Returns:
- A boolean.
-
opposite
Returns the opposite edge.- Parameters:
edge
- an edge.- Returns:
- The opposite edge.
-
coordinate
Returns the x or y coordinate of the specified edge.- Parameters:
rectangle
- the rectangle.edge
- the edge.- Returns:
- The coordinate.
-