Class ChartBackgroundColorOptionsBuilder
- java.lang.Object
-
- org.pepstock.charba.client.commons.AbstractBaseBuilder
-
- org.pepstock.charba.client.impl.plugins.ChartBackgroundColorOptionsBuilder
-
- All Implemented Interfaces:
IsBuilder
public final class ChartBackgroundColorOptionsBuilder extends AbstractBaseBuilder
Comfortable object to createChartBackgroundColor.ID
plugin options by a builder.- Author:
- Andrea "Stock" Stocchero
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description ChartBackgroundColorOptions
build()
Returns a configured plugin options.static ChartBackgroundColorOptionsBuilder
create()
Returns new builder instance.static ChartBackgroundColorOptionsBuilder
create(IsChart chart)
Returns new builder instance using the chart global options.ChartBackgroundColorOptionsBuilder
setBackgroundColor(String color)
Sets the background color.ChartBackgroundColorOptionsBuilder
setBackgroundColor(Gradient gradient)
Sets the background gradient.ChartBackgroundColorOptionsBuilder
setBackgroundColor(IsColor color)
Sets the background color.ChartBackgroundColorOptionsBuilder
setBackgroundColor(Pattern pattern)
Sets the background pattern.ChartBackgroundColorOptionsBuilder
setGlobalCompositeOperation(GlobalCompositeOperation globalCompositeOperation)
Sets the type of compositing operation to apply when drawing new shapes.-
Methods inherited from class org.pepstock.charba.client.commons.AbstractBaseBuilder
isBuilt, setBuilt
-
-
-
-
Method Detail
-
create
public static ChartBackgroundColorOptionsBuilder create()
Returns new builder instance.- Returns:
- new builder instance
-
create
public static ChartBackgroundColorOptionsBuilder create(IsChart chart)
Returns new builder instance using the chart global options.- Parameters:
chart
- chart instance related to the plugin options- Returns:
- new builder instance
-
build
public ChartBackgroundColorOptions build()
Returns a configured plugin options.- Returns:
- a configured plugin options.
-
setBackgroundColor
public ChartBackgroundColorOptionsBuilder setBackgroundColor(String color)
Sets the background color.- Parameters:
color
- the background color.- Returns:
- new builder instance
-
setBackgroundColor
public ChartBackgroundColorOptionsBuilder setBackgroundColor(IsColor color)
Sets the background color.- Parameters:
color
- the background color.- Returns:
- new builder instance
-
setBackgroundColor
public ChartBackgroundColorOptionsBuilder setBackgroundColor(Gradient gradient)
Sets the background gradient.- Parameters:
gradient
- the background gradient.- Returns:
- new builder instance
-
setBackgroundColor
public ChartBackgroundColorOptionsBuilder setBackgroundColor(Pattern pattern)
Sets the background pattern.- Parameters:
pattern
- the background pattern.- Returns:
- new builder instance
-
setGlobalCompositeOperation
public ChartBackgroundColorOptionsBuilder setGlobalCompositeOperation(GlobalCompositeOperation globalCompositeOperation)
Sets the type of compositing operation to apply when drawing new shapes.- Parameters:
globalCompositeOperation
- which of the compositing or blending mode operations to use- Returns:
- new builder instance
-
-