com.extjs.gxt.charts.client.model.charts
Class PieChart

java.lang.Object
  extended by com.extjs.gxt.ui.client.data.BaseModelData
      extended by com.extjs.gxt.ui.client.data.BaseModel
          extended by com.extjs.gxt.charts.client.model.charts.ChartConfig
              extended by com.extjs.gxt.charts.client.model.charts.PieChart
All Implemented Interfaces:
ChangeEventSource, Model, ModelData, java.io.Serializable

public class PieChart
extends ChartConfig

OFC Pie Chart.

See Also:
Serialized Form

Nested Class Summary
static class PieChart.Slice
           
 
Field Summary
 
Fields inherited from class com.extjs.gxt.charts.client.model.charts.ChartConfig
dataProvider, model
 
Fields inherited from class com.extjs.gxt.ui.client.data.BaseModel
changeEventSupport
 
Fields inherited from class com.extjs.gxt.ui.client.data.BaseModelData
allowNestedValues, map
 
Fields inherited from interface com.extjs.gxt.ui.client.data.ChangeEventSource
Add, Remove, Update
 
Constructor Summary
PieChart()
          Creates a new pie chart.
 
Method Summary
 void addSlice(java.lang.Number value, java.lang.String text)
          Adds a slice.
 void addSlices(java.util.List<PieChart.Slice> slices)
          Adds slices.
 void addSlices(PieChart.Slice... slice)
          Adds slices.
 void addValues(java.util.List<java.lang.Number> values)
          Adds the values.
 void addValues(java.lang.Number... values)
          Adds the values.
 float getAlpha()
          Returns the alpha.
 int getBorder()
          Returns the border.
 java.util.Collection<java.lang.String> getColours()
          Returns the colours.
 java.lang.Integer getRadius()
          Returns the radius.
 java.lang.Integer getStartAngle()
          Returns the start angle.
 boolean isAlphaHighlightEnabled()
          Returns true if slice alpha highlighting is enabled, otherwise slice animates.
 boolean isAnimationEnabled()
          Returns true if the pie has animation enabled
 boolean isGradientFillEnabled()
          Returns true if pie slices are to be gradient filled.
 boolean isNoLabelsEnabled()
          Returns true if pie slices are not to have labels.
 void setAlpha(java.lang.Float alpha)
          Sets the alpha.
 void setAlphaHighlight(boolean alphaHighlight)
          Sets alpha colour toggle as the highlight, or slice slide out animation.
 void setAnimate(boolean animate)
          Sets if animation of slice rotation build is enabled.
 void setBorder(int border)
          Sets the border.
 void setColours(java.util.Collection<java.lang.String> colours)
          Sets colours in HTML hex format (#ffffff)
 void setColours(java.lang.String... list)
          Sets colours in HTML hex format (#ffffff)
 void setDataProvider(PieDataProvider dataProvider)
          Sets the charts data provider.
 void setGradientFill(boolean gradientFill)
          Sets the gradient fill.
 void setNoLabels(boolean nolabels)
          True to hide labels.
 void setRadius(java.lang.Integer radius)
          Sets the radius.
 void setStartAngle(java.lang.Integer startAngle)
          Sets the start angle.
 
Methods inherited from class com.extjs.gxt.charts.client.model.charts.ChartConfig
addChartListener, addNullValue, getChartListeners, getDataProvider, getFontSize, getModel, getText, getTooltip, getType, getValues, isEnableEvents, removeChartListener, setAnimateOnShow, setDataProvider, setEnableEvents, setFontSize, setKeys, setKeys, setModel, setText, setTooltip, setValues
 
Methods inherited from class com.extjs.gxt.ui.client.data.BaseModel
addChangeListener, addChangeListener, fireEvent, fireEvent, isSilent, notify, notifyPropertyChanged, remove, removeChangeListener, removeChangeListeners, set, setSilent
 
Methods inherited from class com.extjs.gxt.ui.client.data.BaseModelData
get, get, getProperties, getPropertyNames, isAllowNestedValues, setAllowNestedValues, setProperties
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface com.extjs.gxt.ui.client.data.ModelData
get, getProperties, getPropertyNames
 

Constructor Detail

PieChart

public PieChart()
Creates a new pie chart.

Method Detail

addSlice

public void addSlice(java.lang.Number value,
                     java.lang.String text)
Adds a slice.

Parameters:
value - the value
text - the text

addSlices

public void addSlices(java.util.List<PieChart.Slice> slices)
Adds slices.

Parameters:
slices - the slices

addSlices

public void addSlices(PieChart.Slice... slice)
Adds slices.

Parameters:
slice - the slice

addValues

public void addValues(java.util.List<java.lang.Number> values)
Adds the values.

Parameters:
values - the values

addValues

public void addValues(java.lang.Number... values)
Adds the values.

Parameters:
values - the values

getAlpha

public float getAlpha()
Returns the alpha.

Returns:
the alpha

getBorder

public int getBorder()
Returns the border.

Returns:
the border

getColours

public java.util.Collection<java.lang.String> getColours()
Returns the colours.

Returns:
the colours

getRadius

public java.lang.Integer getRadius()
Returns the radius.

Returns:
the radius

getStartAngle

public java.lang.Integer getStartAngle()
Returns the start angle.

Returns:
the start angle

isAlphaHighlightEnabled

public boolean isAlphaHighlightEnabled()
Returns true if slice alpha highlighting is enabled, otherwise slice animates.

Returns:
true if alpha highlight is enabled

isAnimationEnabled

public boolean isAnimationEnabled()
Returns true if the pie has animation enabled

Returns:
true if animations are enabled.

isGradientFillEnabled

public boolean isGradientFillEnabled()
Returns true if pie slices are to be gradient filled.

Returns:
true if gradient fill is enabled

isNoLabelsEnabled

public boolean isNoLabelsEnabled()
Returns true if pie slices are not to have labels.

Returns:
true if no labels is enabled

setAlpha

public void setAlpha(java.lang.Float alpha)
Sets the alpha.

Parameters:
alpha - the alpha

setAlphaHighlight

public void setAlphaHighlight(boolean alphaHighlight)
Sets alpha colour toggle as the highlight, or slice slide out animation.

Parameters:
alphaHighlight - true or false

setAnimate

public void setAnimate(boolean animate)
Sets if animation of slice rotation build is enabled.

Parameters:
animate - true or false

setBorder

public void setBorder(int border)
Sets the border.

Parameters:
border - the new border

setColours

public void setColours(java.util.Collection<java.lang.String> colours)
Sets colours in HTML hex format (#ffffff)

Parameters:
colours - the new colours

setColours

public void setColours(java.lang.String... list)
Sets colours in HTML hex format (#ffffff)

Parameters:
list - the new colours

setDataProvider

public void setDataProvider(PieDataProvider dataProvider)
Sets the charts data provider.

Parameters:
dataProvider - the data provider

setGradientFill

public void setGradientFill(boolean gradientFill)
Sets the gradient fill.

Parameters:
gradientFill - true or false

setNoLabels

public void setNoLabels(boolean nolabels)
True to hide labels.

Parameters:
nolabels - true to hide labels

setRadius

public void setRadius(java.lang.Integer radius)
Sets the radius.

Parameters:
radius - the radius to set

setStartAngle

public void setStartAngle(java.lang.Integer startAngle)
Sets the start angle.

Parameters:
startAngle - the new start angle