org.jfree.chart.renderer.category

Class CategoryItemRendererState

public class CategoryItemRendererState extends RendererState

An object that retains temporary state information for a CategoryItemRenderer.
Constructor Summary
CategoryItemRendererState(PlotRenderingInfo info)
Creates a new object for recording temporary state information for a renderer.
Method Summary
doublegetBarWidth()
Returns the bar width.
CategoryCrosshairStategetCrosshairState()
Returns the crosshair state, if any.
doublegetSeriesRunningTotal()
Returns the series running total.
int[]getVisibleSeriesArray()
Returns a copy of the visible series array.
intgetVisibleSeriesCount()
Returns the number of visible series or -1 if no visible series have been specified.
intgetVisibleSeriesIndex(int rowIndex)
Returns the index of the row relative to the visible rows.
voidsetBarWidth(double width)
Sets the bar width.
voidsetCrosshairState(CategoryCrosshairState state)
Sets the crosshair state.
voidsetVisibleSeriesArray(int[] visibleSeries)
Sets an array with the indices of the visible rows.

Constructor Detail

CategoryItemRendererState

public CategoryItemRendererState(PlotRenderingInfo info)
Creates a new object for recording temporary state information for a renderer.

Parameters: info the plot rendering info (null permitted).

Method Detail

getBarWidth

public double getBarWidth()
Returns the bar width.

Returns: The bar width.

See Also: CategoryItemRendererState

getCrosshairState

public CategoryCrosshairState getCrosshairState()
Returns the crosshair state, if any.

Returns: The crosshair state (possibly null).

Since: 1.0.11

See Also: setCrosshairState

getSeriesRunningTotal

public double getSeriesRunningTotal()
Returns the series running total.

Returns: The running total.

See Also: CategoryItemRendererState

getVisibleSeriesArray

public int[] getVisibleSeriesArray()
Returns a copy of the visible series array.

Returns: The visible series array (possibly null).

Since: 1.0.13

getVisibleSeriesCount

public int getVisibleSeriesCount()
Returns the number of visible series or -1 if no visible series have been specified.

Returns: The number or -1.

Since: 1.0.13

getVisibleSeriesIndex

public int getVisibleSeriesIndex(int rowIndex)
Returns the index of the row relative to the visible rows. If no visible rows have been specified, the original row index is returned. If the row index is not included in the array of visible rows, -1 is returned.

Parameters: rowIndex the row index.

Returns: The new row index or -1.

Since: 1.0.13

setBarWidth

public void setBarWidth(double width)
Sets the bar width. The renderer calculates this value and stores it here - it is not intended that users can manually set the bar width.

Parameters: width the width.

See Also: getBarWidth

setCrosshairState

public void setCrosshairState(CategoryCrosshairState state)
Sets the crosshair state.

Parameters: state the new state (null permitted).

Since: 1.0.11

See Also: getCrosshairState

setVisibleSeriesArray

public void setVisibleSeriesArray(int[] visibleSeries)
Sets an array with the indices of the visible rows.

Parameters: visibleSeries the array (null permitted).

Since: 1.0.13

Copyright © 2000-2009 by Object Refinery Limited. All Rights Reserved.