-
-
Constructor Summary
Constructors Constructor Description BarEntry(float x, float y)Constructor for normal bars (not stacked). BarEntry(float x, float y, Object data)Constructor for normal bars (not stacked). BarEntry(float x, float y, Drawable icon)Constructor for normal bars (not stacked). BarEntry(float x, float y, Drawable icon, Object data)Constructor for normal bars (not stacked). BarEntry(float x, Array<float> vals)Constructor for stacked bar entries. BarEntry(float x, Array<float> vals, Object data)Constructor for stacked bar entries. BarEntry(float x, Array<float> vals, Drawable icon)Constructor for stacked bar entries. BarEntry(float x, Array<float> vals, Drawable icon, Object data)Constructor for stacked bar entries.
-
Method Summary
Modifier and Type Method Description BarEntrycopy()Returns an exact copy of the BarEntry. Array<float>getYVals()Returns the stacked values this BarEntry represents, or null, if only a single value is represented (then, usegetY()). voidsetVals(Array<float> vals)Set the array of values this BarEntry should represent. floatgetY()Returns the value of this BarEntry. Array<Range>getRanges()Returns the ranges of the individual stack-entries. booleanisStacked()Returns true if this BarEntry is stacked (has a values array), false if not. floatgetBelowSum(int stackIndex)Use `getSumBelow(stackIndex)` instead. floatgetSumBelow(int stackIndex)floatgetPositiveSum()Reuturns the sum of all positive values this entry (if stacked) contains. floatgetNegativeSum()Returns the sum of all negative values this entry (if stacked) contains. -
Methods inherited from class com.github.mikephil.charting.data.Entry
copy, describeContents, equalTo, getX, setX, toString, writeToParcel -
Methods inherited from class com.github.mikephil.charting.data.BaseEntry
getData, getIcon, getY, setData, setIcon, setY -
Methods inherited from class android.os.Parcelable
describeContents, writeToParcel -
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
-
Constructor Detail
-
BarEntry
BarEntry(float x, float y)
Constructor for normal bars (not stacked).
-
BarEntry
BarEntry(float x, float y, Object data)
Constructor for normal bars (not stacked).- Parameters:
data- - Spot for additional data this Entry represents.
-
BarEntry
BarEntry(float x, float y, Drawable icon)
Constructor for normal bars (not stacked).- Parameters:
icon- - icon image
-
BarEntry
BarEntry(float x, float y, Drawable icon, Object data)
Constructor for normal bars (not stacked).- Parameters:
icon- - icon imagedata- - Spot for additional data this Entry represents.
-
BarEntry
BarEntry(float x, Array<float> vals)
Constructor for stacked bar entries.- Parameters:
vals- - the stack values, use at least 2
-
BarEntry
BarEntry(float x, Array<float> vals, Object data)
Constructor for stacked bar entries.- Parameters:
vals- - the stack values, use at least 2data- - Spot for additional data this Entry represents.
-
BarEntry
BarEntry(float x, Array<float> vals, Drawable icon)
Constructor for stacked bar entries.- Parameters:
vals- - the stack values, use at least 2icon- - icon image
-
-
Method Detail
-
getYVals
Array<float> getYVals()
Returns the stacked values this BarEntry represents, or null, if only a single value is represented (then, usegetY()).
-
getY
float getY()
Returns the value of this BarEntry. If the entry is stacked, it returns the positive sum of all values.
-
getRanges
Array<Range> getRanges()
Returns the ranges of the individual stack-entries. Will return null if this entry is not stacked.
-
isStacked
boolean isStacked()
Returns true if this BarEntry is stacked (has a values array), false if not.
-
getBelowSum
@Deprecated() float getBelowSum(int stackIndex)
Use `getSumBelow(stackIndex)` instead.
-
getSumBelow
float getSumBelow(int stackIndex)
-
getPositiveSum
float getPositiveSum()
Reuturns the sum of all positive values this entry (if stacked) contains.
-
getNegativeSum
float getNegativeSum()
Returns the sum of all negative values this entry (if stacked) contains. (this is a positive number)
-
-
-
-