- java.lang.Object
-
- nl.crashdata.chartjs.data.ChartJsFill
-
public final class ChartJsFill extends Object
A value object to represent the fill-configuration for a chart, ie. how to fill the area under a line or radar graph. Gets serialised to a javascript string value. Corresponds to theconfig.data.datasets[].fillproperty.- Author:
- haster
-
-
Field Summary
Fields Modifier and Type Field Description static ChartJsFillDISABLED
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static ChartJsFillabsoluteIndex(int datasetIndex)Sets the fill property to a value indicating fill to another dataset.static ChartJsFillboundary(ChartJsBoundaryType boundary)Sets the fill property to a value indicating fill to a boundary.static ChartJsFilldisabled()Sets the fill property to a value indicating it is disabled (ie, don't fill)static ChartJsFillrelativeIndex(int datasetIndex)Sets the fill property to a value indicating fill to another dataset.StringtoJsonString()
-
-
-
Field Detail
-
DISABLED
public static final ChartJsFill DISABLED
-
-
Method Detail
-
disabled
public static ChartJsFill disabled()
Sets the fill property to a value indicating it is disabled (ie, don't fill)
-
boundary
public static ChartJsFill boundary(ChartJsBoundaryType boundary)
Sets the fill property to a value indicating fill to a boundary.- Parameters:
boundary- The boundary to which the area needs to be filled.
-
relativeIndex
public static ChartJsFill relativeIndex(int datasetIndex)
Sets the fill property to a value indicating fill to another dataset.- Parameters:
datasetIndex- the relative index of the dataset to which the area should be filled. Must be nonzero.
-
absoluteIndex
public static ChartJsFill absoluteIndex(int datasetIndex)
Sets the fill property to a value indicating fill to another dataset.- Parameters:
datasetIndex- the absolute index of the dataset to which the area should be filled. Must be strictly positive.
-
toJsonString
public String toJsonString()
-
-