org.jfree.chart.plot

Class PiePlotState

public class PiePlotState extends RendererState

A renderer state.
Constructor Summary
PiePlotState(PlotRenderingInfo info)
Creates a new object for recording temporary state information for a renderer.
Method Summary
Rectangle2DgetExplodedPieArea()
Returns the exploded pie area.
doublegetLatestAngle()
Returns the latest angle.
Rectangle2DgetLinkArea()
Returns the link area.
intgetPassesRequired()
Returns the number of passes required by the renderer.
Rectangle2DgetPieArea()
Returns the pie area.
doublegetPieCenterX()
Returns the x-coordinate of the center of the pie chart.
doublegetPieCenterY()
Returns the y-coordinate (in Java2D space) of the center of the pie chart.
doublegetPieHRadius()
Returns the vertical pie radius.
doublegetPieWRadius()
Returns the horizontal pie radius.
doublegetTotal()
Returns the total of the values in the dataset.
voidsetExplodedPieArea(Rectangle2D area)
Sets the exploded pie area.
voidsetLatestAngle(double angle)
Sets the latest angle.
voidsetLinkArea(Rectangle2D area)
Sets the label link area.
voidsetPassesRequired(int passes)
Sets the number of passes required by the renderer.
voidsetPieArea(Rectangle2D area)
Sets the pie area.
voidsetPieCenterX(double x)
Sets the x-coordinate of the center of the pie chart.
voidsetPieCenterY(double y)
Sets the y-coordinate of the center of the pie chart.
voidsetPieHRadius(double radius)
Sets the vertical pie radius.
voidsetPieWRadius(double radius)
Sets the horizontal pie radius.
voidsetTotal(double total)
Sets the total.

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

getExplodedPieArea

public Rectangle2D getExplodedPieArea()
Returns the exploded pie area.

Returns: The exploded pie area.

getLatestAngle

public double getLatestAngle()
Returns the latest angle.

Returns: The latest angle.

getLinkArea

public Rectangle2D getLinkArea()
Returns the link area. This defines the "dog-leg" point for the label linking lines.

Returns: The link area.

getPassesRequired

public int getPassesRequired()
Returns the number of passes required by the renderer.

Returns: The number of passes.

getPieArea

public Rectangle2D getPieArea()
Returns the pie area.

Returns: The pie area.

getPieCenterX

public double getPieCenterX()
Returns the x-coordinate of the center of the pie chart.

Returns: The x-coordinate (in Java2D space).

getPieCenterY

public double getPieCenterY()
Returns the y-coordinate (in Java2D space) of the center of the pie chart. For the PiePlot3D class, we derive this from the top of the pie.

Returns: The y-coordinate (in Java2D space).

getPieHRadius

public double getPieHRadius()
Returns the vertical pie radius.

Returns: The radius.

getPieWRadius

public double getPieWRadius()
Returns the horizontal pie radius.

Returns: The radius.

getTotal

public double getTotal()
Returns the total of the values in the dataset.

Returns: The total.

setExplodedPieArea

public void setExplodedPieArea(Rectangle2D area)
Sets the exploded pie area.

Parameters: area the area.

setLatestAngle

public void setLatestAngle(double angle)
Sets the latest angle.

Parameters: angle the angle.

setLinkArea

public void setLinkArea(Rectangle2D area)
Sets the label link area. This defines the "dog-leg" point for the label linking lines.

Parameters: area the area.

setPassesRequired

public void setPassesRequired(int passes)
Sets the number of passes required by the renderer.

Parameters: passes the passes.

setPieArea

public void setPieArea(Rectangle2D area)
Sets the pie area.

Parameters: area the area.

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).

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).

setPieHRadius

public void setPieHRadius(double radius)
Sets the vertical pie radius.

Parameters: radius the radius.

setPieWRadius

public void setPieWRadius(double radius)
Sets the horizontal pie radius.

Parameters: radius the radius.

setTotal

public void setTotal(double total)
Sets the total.

Parameters: total the total.