Class MaterialOptionHelper

    • Constructor Detail

      • MaterialOptionHelper

        public MaterialOptionHelper​(Chart chart)
    • Method Detail

      • addTitle

        public ChartOptions addTitle​(ChartOptions parent,
                                     String title)
        Description copied from interface: OptionHelper
        Add a title of the chart to the root of ChartOptions.
        Parameters:
        parent - Root ChartOptions to add title to.
        title - String to use for the title.
        Returns:
        Parent for fluent calling.
      • addTitle

        public ChartOptions addTitle​(ChartOptions parent,
                                     IModel<String> titleModel)
        Description copied from interface: OptionHelper
        Add a title of the chart to the root of ChartOptions.
        Parameters:
        parent - Root ChartOptions to add title to.
        titleModel - Model to use for the title.
        Returns:
        Parent for fluent calling.
      • addSubTitle

        public ChartOptions addSubTitle​(ChartOptions parent,
                                        String subTitle)
        Description copied from interface: OptionHelper
        Add a subTitle of the chart to the root of ChartOptions.
        Parameters:
        parent - Root ChartOptions to add subTitle to.
        subTitle - String to use for the subTitle.
        Returns:
        Parent for fluent calling.
      • addSubTitle

        public ChartOptions addSubTitle​(ChartOptions parent,
                                        IModel<String> subTitleModel)
        Description copied from interface: OptionHelper
        Add a subTitle of the chart to the root of ChartOptions.
        Parameters:
        parent - Root ChartOptions to add subTitle to.
        subTitleModel - Model to use for the subTitle.
        Returns:
        Parent for fluent calling.
      • addDualAxisOptions

        public ChartOptions addDualAxisOptions​(ChartOptions parent,
                                               String[] axisNames,
                                               String[] seriesMapping,
                                               String[] axisTitles,
                                               OptionModifier[] axisModifiers,
                                               OptionModifier[] seriesModifiers)
        Description copied from interface: OptionHelper
        Add a definition of dual axis to the root of ChartOptions. Use explicit axis titles for labeling axis.
        Parameters:
        parent - Root ChartOptions to add title to.
        axisNames - Names of the axis.
        seriesMapping - Map each serie in order to an axis by the axis name.
        axisTitles - Display titles (labels) used for the titles axis. Must have same order and count as axisNames.
        axisModifiers - Modifiers for the axis definitions. Can be used to add options to each axis. Set to null if no modification is necessary at all. Set position in array to null if to modification is needed for the particular axis.
        seriesModifiers - Modifiers for the series definitions. Can be used to add options to each series. Set to null if no modification is necessary at all. Set position in array to null if to modification is needed for the particular series. Set to null if no modification needed.
        Returns:
        Parent for fluent calling.