org.jfree.chart.plot
Class PieLabelRecord
java.lang.Object
org.jfree.chart.plot.PieLabelRecord
- Comparable
extends java.lang.Object
implements Comparable
A structure that retains information about the label for a section in a pie
chart.
PieLabelRecord(Comparable key, double angle, double baseY, TextBox label, double labelHeight, double gap, double linkPercent) - Creates a new record.
|
int | compareTo(Object obj) - Compares this object to an arbitrary object.
|
double | getAllocatedY() - Returns the allocated y-coordinate.
|
double | getAngle() - Returns the angle.
|
double | getBaseY() - Returns the base y-coordinate.
|
double | getGap() - Returns the gap.
|
Comparable | getKey() - Returns the key for the section that the label applies to.
|
TextBox | getLabel() - Returns the label.
|
double | getLabelHeight() - Returns the label height.
|
double | getLinkPercent() - Returns the link percent.
|
double | getLowerY() - Returns the lower bound of the label.
|
double | getUpperY() - Returns the upper bound of the label.
|
void | setAllocatedY(double y) - Sets the allocated y-coordinate.
|
void | setBaseY(double base) - Sets the base y-coordinate.
|
String | toString() - Returns a string describing the object.
|
PieLabelRecord
public PieLabelRecord(Comparable key,
double angle,
double baseY,
TextBox label,
double labelHeight,
double gap,
double linkPercent)
Creates a new record.
key
- the key.angle
- the angle.baseY
- the base y-coordinate.label
- the label.labelHeight
- the label height (in Java2D units).gap
- the gap.linkPercent
- the link percent.
compareTo
public int compareTo(Object obj)
Compares this object to an arbitrary object.
obj
- the object to compare against.
- An integer that specifies the relative order of the two objects.
getAllocatedY
public double getAllocatedY()
Returns the allocated y-coordinate.
- The allocated y-coordinate.
getAngle
public double getAngle()
Returns the angle.
getBaseY
public double getBaseY()
Returns the base y-coordinate. This is where the label will appear if
there is no overlapping of labels.
getGap
public double getGap()
Returns the gap.
getKey
public Comparable getKey()
Returns the key for the section that the label applies to.
getLabel
public TextBox getLabel()
Returns the label.
getLabelHeight
public double getLabelHeight()
Returns the label height.
- The label height (in Java2D units).
getLinkPercent
public double getLinkPercent()
Returns the link percent.
getLowerY
public double getLowerY()
Returns the lower bound of the label.
getUpperY
public double getUpperY()
Returns the upper bound of the label.
setAllocatedY
public void setAllocatedY(double y)
Sets the allocated y-coordinate.
setBaseY
public void setBaseY(double base)
Sets the base y-coordinate.
base
- the base y-coordinate.
toString
public String toString()
Returns a string describing the object. This is used for debugging only.