Class ExportOptions
java.lang.Object
com.vaadin.flow.component.charts.model.AbstractConfigurationObject
com.vaadin.flow.component.charts.export.ExportOptions
- All Implemented Interfaces:
Serializable
public class ExportOptions
extends com.vaadin.flow.component.charts.model.AbstractConfigurationObject
Optional settings for exporting charts in the server.
Options include:
- width: Width of the exported image.
- height: Height of the exported image.
- theme: Theme used to style the chart. For example:
LumoDarkTheme - lang: Lang specifications for internationalization purposes.
- timeline: Determines if the generated chart is in timeline mode.
- executeFunctions: execute JavaScript functions (for example: formatter functions)
- Since:
- 21.0
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanCheck flag to see if generators will execute JavaScript functions when using aConfigurationwith JS functions.Get the height the resulting chart will have.com.vaadin.flow.component.charts.model.LanggetLang()Get theLangobject used to add i18n features to the chart.com.vaadin.flow.component.charts.model.style.ThemegetTheme()Get theThemeused to style the chart.Check flag to see if the generated chart will be in timeline mode.getWidth()Get the width the resulting chart will have.voidsetExecuteFunctions(Boolean executeFunctions) Set flag to execute JS functions when exporting charts.voidGet the height the resulting chart will have.voidsetLang(com.vaadin.flow.component.charts.model.Lang lang) Set theLangobject used to add i18n features to the chart.voidsetTheme(com.vaadin.flow.component.charts.model.style.Theme theme) Set theThemeused to style the chart.voidsetTimeline(Boolean timeline) Set flag to mark the generated chart in timeline mode.voidSet the width the resulting chart will have.
-
Constructor Details
-
ExportOptions
public ExportOptions()
-
-
Method Details
-
getTheme
public com.vaadin.flow.component.charts.model.style.Theme getTheme()Get theThemeused to style the chart.- Returns:
- the
Themeused to style the chart.
-
setTheme
public void setTheme(com.vaadin.flow.component.charts.model.style.Theme theme) Set theThemeused to style the chart.- Parameters:
theme- the theme to use when styling the chart.- See Also:
-
LumoLightThemeLumoDarkTheme
-
getLang
public com.vaadin.flow.component.charts.model.Lang getLang()Get theLangobject used to add i18n features to the chart.- Returns:
- the lang object used to provide i18n to the chart.
-
setLang
public void setLang(com.vaadin.flow.component.charts.model.Lang lang) Set theLangobject used to add i18n features to the chart.- Parameters:
lang- theLangobject used to provide the i18n features of the chart.
-
getWidth
Get the width the resulting chart will have.- Returns:
- the width the resulting chart will have.
-
setWidth
Set the width the resulting chart will have.- Parameters:
width- the width the resulting chart will have.
-
getHeight
Get the height the resulting chart will have.- Returns:
- the height the resulting chart will have.
-
setHeight
Get the height the resulting chart will have.- Parameters:
height- the height the resulting chart will have.
-
getTimeline
Check flag to see if the generated chart will be in timeline mode.- Returns:
trueif generated chart will be in timeline mode,falseotherwise.
-
setTimeline
Set flag to mark the generated chart in timeline mode.- Parameters:
timeline- if the generated chart should be in timeline mode.
-
getExecuteFunctions
public boolean getExecuteFunctions()Check flag to see if generators will execute JavaScript functions when using aConfigurationwith JS functions.- Returns:
trueif the generator will execute JavaScript functions,falseotherwise.
-
setExecuteFunctions
Set flag to execute JS functions when exporting charts.- Parameters:
executeFunctions- if the generator should execute JS functions.
-