Package org.jfree.chart.plot
Class PiePlotState
- java.lang.Object
-
- org.jfree.chart.renderer.RendererState
-
- org.jfree.chart.plot.PiePlotState
-
public class PiePlotState extends RendererState
A renderer state.
-
-
Field Summary
Fields Modifier and Type Field Description private java.awt.geom.Rectangle2D
explodedPieArea
The exploded pie area.private double
latestAngle
The latest angle.private java.awt.geom.Rectangle2D
linkArea
The link area.private int
passesRequired
The number of passes required by the renderer.private java.awt.geom.Rectangle2D
pieArea
The pie area.private double
pieCenterX
The center of the pie in Java 2D coordinates.private double
pieCenterY
The center of the pie in Java 2D coordinates.private double
pieHRadius
The vertical pie radius.private double
pieWRadius
The horizontal pie radius.private double
total
The total of the values in the dataset.
-
Constructor Summary
Constructors Constructor Description PiePlotState(PlotRenderingInfo info)
Creates a new object for recording temporary state information for a renderer.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.awt.geom.Rectangle2D
getExplodedPieArea()
Returns the exploded pie area.double
getLatestAngle()
Returns the latest angle.java.awt.geom.Rectangle2D
getLinkArea()
Returns the link area.int
getPassesRequired()
Returns the number of passes required by the renderer.java.awt.geom.Rectangle2D
getPieArea()
Returns the pie area.double
getPieCenterX()
Returns the x-coordinate of the center of the pie chart.double
getPieCenterY()
Returns the y-coordinate (in Java2D space) of the center of the pie chart.double
getPieHRadius()
Returns the vertical pie radius.double
getPieWRadius()
Returns the horizontal pie radius.double
getTotal()
Returns the total of the values in the dataset.void
setExplodedPieArea(java.awt.geom.Rectangle2D area)
Sets the exploded pie area.void
setLatestAngle(double angle)
Sets the latest angle.void
setLinkArea(java.awt.geom.Rectangle2D area)
Sets the label link area.void
setPassesRequired(int passes)
Sets the number of passes required by the renderer.void
setPieArea(java.awt.geom.Rectangle2D area)
Sets the pie area.void
setPieCenterX(double x)
Sets the x-coordinate of the center of the pie chart.void
setPieCenterY(double y)
Sets the y-coordinate of the center of the pie chart.void
setPieHRadius(double radius)
Sets the vertical pie radius.void
setPieWRadius(double radius)
Sets the horizontal pie radius.void
setTotal(double total)
Sets the total.-
Methods inherited from class org.jfree.chart.renderer.RendererState
getElementHinting, getEntityCollection, getInfo, setElementHinting
-
-
-
-
Field Detail
-
passesRequired
private int passesRequired
The number of passes required by the renderer.
-
total
private double total
The total of the values in the dataset.
-
latestAngle
private double latestAngle
The latest angle.
-
explodedPieArea
private java.awt.geom.Rectangle2D explodedPieArea
The exploded pie area.
-
pieArea
private java.awt.geom.Rectangle2D pieArea
The pie area.
-
pieCenterX
private double pieCenterX
The center of the pie in Java 2D coordinates.
-
pieCenterY
private double pieCenterY
The center of the pie in Java 2D coordinates.
-
pieHRadius
private double pieHRadius
The vertical pie radius.
-
pieWRadius
private double pieWRadius
The horizontal pie radius.
-
linkArea
private java.awt.geom.Rectangle2D linkArea
The link area.
-
-
Constructor Detail
-
PiePlotState
public PiePlotState(PlotRenderingInfo info)
Creates a new object for recording temporary state information for a renderer.- Parameters:
info
- the plot rendering info.
-
-
Method Detail
-
getPassesRequired
public int getPassesRequired()
Returns the number of passes required by the renderer.- Returns:
- The number of passes.
-
setPassesRequired
public void setPassesRequired(int passes)
Sets the number of passes required by the renderer.- Parameters:
passes
- the passes.
-
getTotal
public double getTotal()
Returns the total of the values in the dataset.- Returns:
- The total.
-
setTotal
public void setTotal(double total)
Sets the total.- Parameters:
total
- the total.
-
getLatestAngle
public double getLatestAngle()
Returns the latest angle.- Returns:
- The latest angle.
-
setLatestAngle
public void setLatestAngle(double angle)
Sets the latest angle.- Parameters:
angle
- the angle.
-
getPieArea
public java.awt.geom.Rectangle2D getPieArea()
Returns the pie area.- Returns:
- The pie area.
-
setPieArea
public void setPieArea(java.awt.geom.Rectangle2D area)
Sets the pie area.- Parameters:
area
- the area.
-
getExplodedPieArea
public java.awt.geom.Rectangle2D getExplodedPieArea()
Returns the exploded pie area.- Returns:
- The exploded pie area.
-
setExplodedPieArea
public void setExplodedPieArea(java.awt.geom.Rectangle2D area)
Sets the exploded pie area.- Parameters:
area
- the area.
-
getPieCenterX
public double getPieCenterX()
Returns the x-coordinate of the center of the pie chart.- Returns:
- The x-coordinate (in Java2D space).
-
setPieCenterX
public void setPieCenterX(double x)
Sets the x-coordinate of the center of the pie chart.- Parameters:
x
- the x-coordinate (in Java2D space).
-
getPieCenterY
public double getPieCenterY()
Returns the y-coordinate (in Java2D space) of the center of the pie chart.- Returns:
- The y-coordinate (in Java2D space).
-
setPieCenterY
public void setPieCenterY(double y)
Sets the y-coordinate of the center of the pie chart. This method is used by the plot and typically is not called directly by applications.- Parameters:
y
- the y-coordinate (in Java2D space).
-
getLinkArea
public java.awt.geom.Rectangle2D getLinkArea()
Returns the link area. This defines the "dog-leg" point for the label linking lines.- Returns:
- The link area.
-
setLinkArea
public void setLinkArea(java.awt.geom.Rectangle2D area)
Sets the label link area. This defines the "dog-leg" point for the label linking lines.- Parameters:
area
- the area.
-
getPieHRadius
public double getPieHRadius()
Returns the vertical pie radius.- Returns:
- The radius.
-
setPieHRadius
public void setPieHRadius(double radius)
Sets the vertical pie radius.- Parameters:
radius
- the radius.
-
getPieWRadius
public double getPieWRadius()
Returns the horizontal pie radius.- Returns:
- The radius.
-
setPieWRadius
public void setPieWRadius(double radius)
Sets the horizontal pie radius.- Parameters:
radius
- the radius.
-
-