|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.googlecode.charts4j.Slice
public class Slice
Slice of pie for a PieChart
. If the number of colors specified is
less than the number of slices, then colors are interpolated. If no colors
are specified, pie segment colors are interpolated from dark orange to pale
yellow.
PieChart
,
GCharts
Method Summary | |
---|---|
Color |
getColor()
Get the color for this slice of the pie. |
String |
getLabel()
Get the pie slice label. |
int |
getPercentage()
Get the percentage for this slice of the pie. |
static Slice |
newSlice(int percent,
Color color)
Create a pie slice. |
static Slice |
newSlice(int percent,
Color color,
String sliceLabel)
Create a pie slice. |
static Slice |
newSlice(int percent,
String sliceLabel)
Create a pie slice. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public final int getPercentage()
public final Color getColor()
public final String getLabel()
public static Slice newSlice(int percent, Color color, String sliceLabel)
percent
- percent of pie. Must be between 0 to 100.color
- color of slice. Cannot be nullsliceLabel
- label associated with slice. Cannot be null.
public static Slice newSlice(int percent, Color color)
percent
- percent of pie. Must be between 0 to 100.color
- color of slice. Cannot be null.
public static Slice newSlice(int percent, String sliceLabel)
percent
- percent of pie. Must be between 0 to 100.sliceLabel
- label associated with slice. Cannot be null.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |