public class PieDataSet extends DataSet<PieEntry> implements IPieDataSet
| Modifier and Type | Class and Description |
|---|---|
static class |
PieDataSet.ValuePosition |
DataSet.RoundingmEntries, mXMax, mXMin, mYMax, mYMinmAxisDependency, mColors, mDrawIcons, mDrawValues, mGradientColor, mGradientColors, mHighlightEnabled, mIconsOffset, mValueColors, mValueFormatter, mValueTextSize, mValueTypeface, mVisible| Constructor and Description |
|---|
PieDataSet(java.util.List<PieEntry> yVals,
java.lang.String label) |
| Modifier and Type | Method and Description |
|---|---|
protected void |
calcMinMax(PieEntry e)
Updates the min and max x and y value of this DataSet based on the given Entry.
|
DataSet<PieEntry> |
copy()
Provides an exact copy of the DataSet this method is used on.
|
protected void |
copy(PieDataSet pieDataSet) |
java.lang.Integer |
getHighlightColor()
Gets the color for the highlighted sector
|
float |
getSelectionShift()
Returns the distance a highlighted piechart slice is "shifted" away from
the chart-center in dp.
|
float |
getSliceSpace()
Returns the space that is set to be between the piechart-slices of this
DataSet, in pixels.
|
int |
getValueLineColor()
When valuePosition is OutsideSlice, indicates line color
|
float |
getValueLinePart1Length()
When valuePosition is OutsideSlice, indicates length of first half of the line
|
float |
getValueLinePart1OffsetPercentage()
When valuePosition is OutsideSlice, indicates offset as percentage out of the slice size
|
float |
getValueLinePart2Length()
When valuePosition is OutsideSlice, indicates length of second half of the line
|
float |
getValueLineWidth()
When valuePosition is OutsideSlice, indicates line width
|
PieDataSet.ValuePosition |
getXValuePosition() |
PieDataSet.ValuePosition |
getYValuePosition() |
boolean |
isAutomaticallyDisableSliceSpacingEnabled()
When enabled, slice spacing will be 0.0 when the smallest value is going to be
smaller than the slice spacing itself.
|
boolean |
isUseValueColorForLineEnabled()
When valuePosition is OutsideSlice and enabled, line will have the same color as the slice
|
boolean |
isUsingSliceColorAsValueLineColor()
Deprecated.
|
boolean |
isValueLineVariableLength()
When valuePosition is OutsideSlice, this allows variable line length
|
void |
setAutomaticallyDisableSliceSpacing(boolean autoDisable)
When enabled, slice spacing will be 0.0 when the smallest value is going to be
smaller than the slice spacing itself.
|
void |
setHighlightColor(java.lang.Integer color)
Sets the color for the highlighted sector (null for using entry color)
|
void |
setSelectionShift(float shift)
sets the distance the highlighted piechart-slice of this DataSet is
"shifted" away from the center of the chart, default 12f
|
void |
setSliceSpace(float spaceDp)
Sets the space that is left out between the piechart-slices in dp.
|
void |
setUseValueColorForLine(boolean enabled) |
void |
setUsingSliceColorAsValueLineColor(boolean enabled)
Deprecated.
|
void |
setValueLineColor(int valueLineColor) |
void |
setValueLinePart1Length(float valueLinePart1Length) |
void |
setValueLinePart1OffsetPercentage(float valueLinePart1OffsetPercentage) |
void |
setValueLinePart2Length(float valueLinePart2Length) |
void |
setValueLineVariableLength(boolean valueLineVariableLength) |
void |
setValueLineWidth(float valueLineWidth) |
void |
setXValuePosition(PieDataSet.ValuePosition xValuePosition) |
void |
setYValuePosition(PieDataSet.ValuePosition yValuePosition) |
addEntry, addEntryOrdered, calcMinMax, calcMinMaxX, calcMinMaxY, calcMinMaxY, clear, copy, getEntries, getEntriesForXValue, getEntryCount, getEntryForIndex, getEntryForXValue, getEntryForXValue, getEntryIndex, getEntryIndex, getValues, getXMax, getXMin, getYMax, getYMin, removeEntry, setEntries, setValues, toSimpleString, toStringaddColor, contains, copy, getAxisDependency, getColor, getColor, getColors, getForm, getFormLineDashEffect, getFormLineWidth, getFormSize, getGradientColor, getGradientColor, getGradientColors, getIconsOffset, getIndexInEntries, getLabel, getValueColors, getValueFormatter, getValueTextColor, getValueTextColor, getValueTextSize, getValueTypeface, isDrawIconsEnabled, isDrawValuesEnabled, isHighlightEnabled, isVisible, needsFormatter, notifyDataSetChanged, removeEntry, removeEntryByXValue, removeFirst, removeLast, resetColors, setAxisDependency, setColor, setColor, setColors, setColors, setColors, setColors, setDrawIcons, setDrawValues, setForm, setFormLineDashEffect, setFormLineWidth, setFormSize, setGradientColor, setGradientColors, setHighlightEnabled, setIconsOffset, setLabel, setValueFormatter, setValueTextColor, setValueTextColors, setValueTextSize, setValueTypeface, setVisibleclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitaddEntry, addEntryOrdered, calcMinMax, calcMinMaxY, clear, contains, getAxisDependency, getColor, getColor, getColors, getEntriesForXValue, getEntryCount, getEntryForIndex, getEntryForXValue, getEntryForXValue, getEntryIndex, getEntryIndex, getForm, getFormLineDashEffect, getFormLineWidth, getFormSize, getGradientColor, getGradientColor, getGradientColors, getIconsOffset, getIndexInEntries, getLabel, getValueFormatter, getValueTextColor, getValueTextColor, getValueTextSize, getValueTypeface, getXMax, getXMin, getYMax, getYMin, isDrawIconsEnabled, isDrawValuesEnabled, isHighlightEnabled, isVisible, needsFormatter, removeEntry, removeEntry, removeEntryByXValue, removeFirst, removeLast, setAxisDependency, setDrawIcons, setDrawValues, setHighlightEnabled, setIconsOffset, setLabel, setValueFormatter, setValueTextColor, setValueTextColors, setValueTextSize, setValueTypeface, setVisiblepublic PieDataSet(java.util.List<PieEntry> yVals, java.lang.String label)
public DataSet<PieEntry> copy()
DataSetprotected void copy(PieDataSet pieDataSet)
protected void calcMinMax(PieEntry e)
DataSetcalcMinMax in class DataSet<PieEntry>public void setSliceSpace(float spaceDp)
spaceDp - public float getSliceSpace()
IPieDataSetgetSliceSpace in interface IPieDataSetpublic void setAutomaticallyDisableSliceSpacing(boolean autoDisable)
autoDisable - public boolean isAutomaticallyDisableSliceSpacingEnabled()
isAutomaticallyDisableSliceSpacingEnabled in interface IPieDataSetpublic void setSelectionShift(float shift)
shift - public float getSelectionShift()
IPieDataSetgetSelectionShift in interface IPieDataSetpublic PieDataSet.ValuePosition getXValuePosition()
getXValuePosition in interface IPieDataSetpublic void setXValuePosition(PieDataSet.ValuePosition xValuePosition)
public PieDataSet.ValuePosition getYValuePosition()
getYValuePosition in interface IPieDataSetpublic void setYValuePosition(PieDataSet.ValuePosition yValuePosition)
@Deprecated public boolean isUsingSliceColorAsValueLineColor()
@Deprecated public void setUsingSliceColorAsValueLineColor(boolean enabled)
enabled - public int getValueLineColor()
getValueLineColor in interface IPieDataSetpublic void setValueLineColor(int valueLineColor)
public boolean isUseValueColorForLineEnabled()
IPieDataSetisUseValueColorForLineEnabled in interface IPieDataSetpublic void setUseValueColorForLine(boolean enabled)
public float getValueLineWidth()
getValueLineWidth in interface IPieDataSetpublic void setValueLineWidth(float valueLineWidth)
public float getValueLinePart1OffsetPercentage()
getValueLinePart1OffsetPercentage in interface IPieDataSetpublic void setValueLinePart1OffsetPercentage(float valueLinePart1OffsetPercentage)
public float getValueLinePart1Length()
getValueLinePart1Length in interface IPieDataSetpublic void setValueLinePart1Length(float valueLinePart1Length)
public float getValueLinePart2Length()
getValueLinePart2Length in interface IPieDataSetpublic void setValueLinePart2Length(float valueLinePart2Length)
public boolean isValueLineVariableLength()
isValueLineVariableLength in interface IPieDataSetpublic void setValueLineVariableLength(boolean valueLineVariableLength)
public java.lang.Integer getHighlightColor()
getHighlightColor in interface IPieDataSetpublic void setHighlightColor(java.lang.Integer color)