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
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
    Check flag to see if generators will execute JavaScript functions when using a Configuration with JS functions.
    Get the height the resulting chart will have.
    com.vaadin.flow.component.charts.model.Lang
    Get the Lang object used to add i18n features to the chart.
    com.vaadin.flow.component.charts.model.style.Theme
    Get the Theme used to style the chart.
    Check flag to see if the generated chart will be in timeline mode.
    Get the width the resulting chart will have.
    void
    setExecuteFunctions(Boolean executeFunctions)
    Set flag to execute JS functions when exporting charts.
    void
    setHeight(Number height)
    Get the height the resulting chart will have.
    void
    setLang(com.vaadin.flow.component.charts.model.Lang lang)
    Set the Lang object used to add i18n features to the chart.
    void
    setTheme(com.vaadin.flow.component.charts.model.style.Theme theme)
    Set the Theme used to style the chart.
    void
    setTimeline(Boolean timeline)
    Set flag to mark the generated chart in timeline mode.
    void
    Set the width the resulting chart will have.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • ExportOptions

      public ExportOptions()
  • Method Details

    • getTheme

      public com.vaadin.flow.component.charts.model.style.Theme getTheme()
      Get the Theme used to style the chart.
      Returns:
      the Theme used to style the chart.
    • setTheme

      public void setTheme(com.vaadin.flow.component.charts.model.style.Theme theme)
      Set the Theme used to style the chart.
      Parameters:
      theme - the theme to use when styling the chart.
      See Also:
      • LumoLightTheme
      • LumoDarkTheme
    • getLang

      public com.vaadin.flow.component.charts.model.Lang getLang()
      Get the Lang object 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 the Lang object used to add i18n features to the chart.
      Parameters:
      lang - the Lang object used to provide the i18n features of the chart.
    • getWidth

      public Number getWidth()
      Get the width the resulting chart will have.
      Returns:
      the width the resulting chart will have.
    • setWidth

      public void setWidth(Number width)
      Set the width the resulting chart will have.
      Parameters:
      width - the width the resulting chart will have.
    • getHeight

      public Number getHeight()
      Get the height the resulting chart will have.
      Returns:
      the height the resulting chart will have.
    • setHeight

      public void setHeight(Number height)
      Get the height the resulting chart will have.
      Parameters:
      height - the height the resulting chart will have.
    • getTimeline

      public Boolean getTimeline()
      Check flag to see if the generated chart will be in timeline mode.
      Returns:
      true if generated chart will be in timeline mode, false otherwise.
    • setTimeline

      public void setTimeline(Boolean timeline)
      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 a Configuration with JS functions.
      Returns:
      true if the generator will execute JavaScript functions, false otherwise.
    • setExecuteFunctions

      public void setExecuteFunctions(Boolean executeFunctions)
      Set flag to execute JS functions when exporting charts.
      Parameters:
      executeFunctions - if the generator should execute JS functions.