|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectlt.monarch.chart.chart2D.series.PieChartSlice
public class PieChartSlice extends java.lang.Object implements java.io.Serializable
Pie class representing single pie segment.
| Modifier and Type | Field and Description |
|---|---|
protected double |
endAngle
|
protected double |
entireValues
|
protected double |
explodeRadius
|
protected double |
innerRadius
|
protected boolean |
isCloseOutside
|
protected double |
overallAngle
|
protected double |
percents
|
protected double |
sliceAngle
|
protected double |
sliceHalfAngle
|
protected PieSliceLabelEntry |
sliceLabelEntry
|
protected double |
sliceRadius
|
protected double |
startAngle
|
protected double |
value
|
| Constructor and Description |
|---|
PieChartSlice()
Constructs PieChartSegment |
| Modifier and Type | Method and Description |
|---|---|
protected void |
calculateAngles()
Calculates slice, half slice, end slices angles and percent values |
Point2D |
calculateHalfSlicePoint(double radius)
Return calculated point of specify radius |
java.util.List<java.awt.Shape> |
draw(AbstractGraphics g,
int index,
Style style,
Projector projector,
PaintMode paintMode)
Draws the slice of pie |
Point2D |
getCenterPoint()
Returns the center of pie |
double |
getEndAngle()
Returns end angle of pie chart segment |
double |
getEntireValue()
Returns entire value of pie chart segment |
double |
getExplodeRadius()
Returns pie slice explode radius. |
double |
getInnerRadius()
Returns inner radius |
double |
getOuterAngle()
Returns outer angle of pie chart segment |
boolean |
getOutlineClose()
Return true if outline of slices is true, otherwise false |
double |
getOverallAngle()
Returns the pie angle, how much angle the pie should occupy |
double |
getPercentage()
Returns percent value of pie chart segment |
PieSlice2D |
getSlice()
Returns PieSlice2D primitive |
ChartElementEntity |
getSliceEntity(AbstractChartSeries<?,?> series,
Rectangle2D bounds,
PaintStyle<?> paintStyle)
|
double |
getSliceHalfAngle()
Returns the half slice angles |
PieSliceLabelEntry |
getSliceLabelEntry(java.lang.String s,
double radius,
double explode,
double inner,
double startAngle,
double sliceAngle,
Point2D center,
java.awt.FontMetrics fm,
double margin,
java.awt.Image image)
|
double |
getSliceRadius()
Returns section radius |
double |
getStartAngle()
Returns slice start angle of pie chart segment |
double |
getValue()
Returns value of pie chart segment |
void |
setCenterPoint(Point2D centerPoint)
Set center of pie chart |
void |
setEntireValue(double entireValue)
Sets entire value to pie chart segment |
void |
setExplodeRadius(double radius)
Sets pie slice explode radius. |
void |
setInnerRadius(double radius)
Sets inner radius |
void |
setOutlineClose(boolean isClose)
Set close outline of slices |
void |
setOverallAngle(double angle)
Specifies the pie angle, how much angle the pie should occupy. |
void |
setSliceRadius(double radius)
Sets slice radius |
void |
setStartAngle(double angle)
Sets start angle of pie chart segment. |
void |
setValue(double value)
Sets value to pie chart segment |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected double sliceAngle
protected double sliceHalfAngle
protected double startAngle
protected double endAngle
protected double overallAngle
protected double sliceRadius
protected double innerRadius
protected double value
protected double percents
protected double entireValues
protected double explodeRadius
protected boolean isCloseOutside
protected PieSliceLabelEntry sliceLabelEntry
| Constructor Detail |
|---|
public PieChartSlice()
| Method Detail |
|---|
public void setSliceRadius(double radius)
radius - slice radiuspublic double getSliceRadius()
public void setInnerRadius(double radius)
radius - inner radiuspublic double getInnerRadius()
public void setStartAngle(double angle)
angle - Section start anglepublic double getStartAngle()
public void setOverallAngle(double angle)
ssAngle - Section start anglepublic double getOverallAngle()
public double getOuterAngle()
public double getEndAngle()
public double getPercentage()
public void setValue(double value)
value - public double getValue()
public void setEntireValue(double entireValue)
value - public double getEntireValue()
public void setExplodeRadius(double radius)
radius - explode radius of pie slice in range [0,0.5]public double getExplodeRadius()
public void setCenterPoint(Point2D centerPoint)
centerPoint - point of the center the piepublic Point2D getCenterPoint()
public double getSliceHalfAngle()
public void setOutlineClose(boolean isClose)
isClose - true, if closepublic boolean getOutlineClose()
protected void calculateAngles()
public Point2D calculateHalfSlicePoint(double radius)
radius - radius of calculated pointpublic PieSlice2D getSlice()
public java.util.List<java.awt.Shape> draw(AbstractGraphics g,
int index,
Style style,
Projector projector,
PaintMode paintMode)
g - graphics contextindex - slice indexstyle - style objectprojector - projector instancepaintMode - paint mode of slice
public ChartElementEntity getSliceEntity(AbstractChartSeries<?,?> series,
Rectangle2D bounds,
PaintStyle<?> paintStyle)
public PieSliceLabelEntry getSliceLabelEntry(java.lang.String s,
double radius,
double explode,
double inner,
double startAngle,
double sliceAngle,
Point2D center,
java.awt.FontMetrics fm,
double margin,
java.awt.Image image)
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||