Interface CustomHighchartBuilder

All Superinterfaces:
CommonHighchartBuilder, GenericHcObject

public interface CustomHighchartBuilder extends CommonHighchartBuilder
Builder which uses custom chart options to build a chart.
Since:
3.10.2
  • Method Details

    • useRelativeWidth

      @NotNull CustomHighchartBuilder useRelativeWidth(@Nullable Double width)
      Description copied from interface: CommonHighchartBuilder
      Specifies relative width of the chart. It is applicable only for case when chart is rendered in a browser.
      Should be called before CommonHighchartBuilder.render(HtmlContentBuilder, Integer, Integer) or CommonHighchartBuilder.render(Integer, Integer)
      Specified by:
      useRelativeWidth in interface CommonHighchartBuilder
      Parameters:
      width - width in percentages, null means that relative width will not be used
      Returns:
      this
    • options

      @NotNull CustomHighchartBuilder options(@NotNull String options)
      Sets custom chart options. Example:
       {
            chart: {
                type: 'areaspline'
            },
            title: {
                text: 'Example title'
            }
       }
       
      Parameters:
      options - chart options
      Returns:
      this CustomHighchartBuilder instance
    • defaultOptions

      @NotNull CustomHighchartBuilder defaultOptions(@NotNull String options)
      Uses JavaScript Highcharts.setOptions(...) method to set user defined options before chart creation. Method can be called multiple times and will use all parameters defined earlier. Example: { 'credits': {'enabled': false, 'href':null}, 'exporting': {'enabled': false}, 'tooltip': {'backgroundColor': 'rgba(247, 247, 247, 0.9)'}, 'yAxis': {'gridLineWidth': 0}, 'title': {'useHTML': true}, 'plotOptions': {'series': {'animation': false}} }
      Returns:
      this
    • checkJavaScriptExceptions

      @NotNull CustomHighchartBuilder checkJavaScriptExceptions(@NotNull String errorMessage)
      Creates additional JavaScript block which will check if there are some errors occurred while chart creation. This block will add an errorMessage to chart div with some explanations to the user.
      Returns:
      this