Package org.jfree.chart.block
Class LineBorder
java.lang.Object
org.jfree.chart.block.LineBorder
- All Implemented Interfaces:
Serializable,BlockFrame
A line border for any
AbstractBlock.- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate RectangleInsetsThe insets.private PaintThe line color.(package private) static final longFor serialization.private StrokeThe line stroke. -
Constructor Summary
ConstructorsConstructorDescriptionCreates a default border.LineBorder(Paint paint, Stroke stroke, RectangleInsets insets) Creates a new border with the specified color. -
Method Summary
Modifier and TypeMethodDescriptionvoiddraw(Graphics2D g2, Rectangle2D area) Draws the border by filling in the reserved space (in black).booleanTests this border for equality with an arbitrary instance.Returns the insets.getPaint()Returns the paint.Returns the stroke.inthashCode()private voidreadObject(ObjectInputStream stream) Provides serialization support.private voidwriteObject(ObjectOutputStream stream) Provides serialization support.
-
Field Details
-
serialVersionUID
static final long serialVersionUIDFor serialization.- See Also:
-
paint
The line color. -
stroke
The line stroke. -
insets
The insets.
-
-
Constructor Details
-
LineBorder
public LineBorder()Creates a default border. -
LineBorder
Creates a new border with the specified color.- Parameters:
paint- the color (nullnot permitted).stroke- the border stroke (nullnot permitted).insets- the insets (nullnot permitted).
-
-
Method Details
-
getPaint
Returns the paint.- Returns:
- The paint (never
null).
-
getInsets
Returns the insets.- Specified by:
getInsetsin interfaceBlockFrame- Returns:
- The insets (never
null).
-
getStroke
Returns the stroke.- Returns:
- The stroke (never
null).
-
draw
Draws the border by filling in the reserved space (in black).- Specified by:
drawin interfaceBlockFrame- Parameters:
g2- the graphics device.area- the area.
-
equals
Tests this border for equality with an arbitrary instance. -
hashCode
public int hashCode() -
writeObject
Provides serialization support.- Parameters:
stream- the output stream.- Throws:
IOException- if there is an I/O error.
-
readObject
Provides serialization support.- Parameters:
stream- the input stream.- Throws:
IOException- if there is an I/O error.ClassNotFoundException- if there is a classpath problem.
-