Interface HasBarDatasetOptions

    • Method Summary

      All Methods Instance Methods Abstract Methods Default Methods 
      Modifier and Type Method Description
      default double getBarPercentage()
      Returns the percent (0-1) of the available width each bar should be within the category width.
      default int getBarThickness()
      Returns the width of each bar in pixels.
      default double getCategoryPercentage()
      Returns the percent (0-1) of the available width each category should be within the sample width.
      BarDatasetOptionsHandler getDatasetOptionsHandler()
      Returns the instance of bar dataset options handler.
      default int getMaxBarThickness()
      Returns the maximum bar thickness.
      default int getMinBarLength()
      Returns a minimum length in pixels.
      default boolean isGrouped()
      When true, all the data sets at same index value will be placed next to each other centering on that index value.
      When false, each bar is placed on its actual index-axis value.
      default void setBarPercentage​(double barPercentage)
      Sets the percent (0-1) of the available width each bar should be within the category width.
      default void setBarThickness​(int barThickness)
      Sets the width of each bar in pixels.
      default void setCategoryPercentage​(double categoryPercentage)
      Sets the percent (0-1) of the available width each category should be within the sample width.
      default void setGrouped​(boolean grouped)
      When true, all the data sets at same index value will be placed next to each other centering on that index value.
      When false, each bar is placed on its actual index-axis value.
      default void setMaxBarThickness​(int maxBarThickness)
      Sets the maximum bar thickness, to ensure that bars are not sized thicker than this
      default void setMinBarLength​(int minBarLength)
      Set this to ensure that bars have a minimum length in pixels.
    • Method Detail

      • getDatasetOptionsHandler

        BarDatasetOptionsHandler getDatasetOptionsHandler()
        Returns the instance of bar dataset options handler.
        Returns:
        the instance of bar dataset options handler
      • setBarPercentage

        default void setBarPercentage​(double barPercentage)
        Sets the percent (0-1) of the available width each bar should be within the category width. 1.0 will take the whole category width and put the bars right next to each other.
        Parameters:
        barPercentage - percent (0-1) of the available width each bar should be within the category width. 1.0 will take the whole category width and put the bars right next to each other.
      • getBarPercentage

        default double getBarPercentage()
        Returns the percent (0-1) of the available width each bar should be within the category width. 1.0 will take the whole category width and put the bars right next to each other.
        Specified by:
        getBarPercentage in interface IsDefaultBarDatasets
        Returns:
        percent (0-1) of the available width each bar should be within the category width. 1.0 will take the whole category width and put the bars right next to each other.
      • setCategoryPercentage

        default void setCategoryPercentage​(double categoryPercentage)
        Sets the percent (0-1) of the available width each category should be within the sample width.
        Parameters:
        categoryPercentage - percent (0-1) of the available width each category should be within the sample width.
      • getCategoryPercentage

        default double getCategoryPercentage()
        Returns the percent (0-1) of the available width each category should be within the sample width.
        Specified by:
        getCategoryPercentage in interface IsDefaultBarDatasets
        Returns:
        the percent (0-1) of the available width each category should be within the sample width.
      • setBarThickness

        default void setBarThickness​(int barThickness)
        Sets the width of each bar in pixels. If set to 'flex', it computes "optimal" sample widths that globally arrange bars side by side. If not set, the base sample widths are calculated automatically so that they take the full available widths without overlap. Then, the bars are sized using barPercentage and categoryPercentage.
        Parameters:
        barThickness - width of each bar in pixels. If not set, the base sample widths are calculated automatically so that they take the full available widths without overlap. Then, the bars are sized using barPercentage and categoryPercentage.
      • getBarThickness

        default int getBarThickness()
        Returns the width of each bar in pixels. If set to 'flex', it computes "optimal" sample widths that globally arrange bars side by side. If not set, the base sample widths are calculated automatically so that they take the full available widths without overlap. Then, the bars are sized using barPercentage and categoryPercentage.
        Specified by:
        getBarThickness in interface IsDefaultBarDatasets
        Returns:
        width of each bar in pixels. If not set, the base sample widths are calculated automatically so that they take the full available widths without overlap. Then, the bars are sized using barPercentage and categoryPercentage.
      • setMaxBarThickness

        default void setMaxBarThickness​(int maxBarThickness)
        Sets the maximum bar thickness, to ensure that bars are not sized thicker than this
        Parameters:
        maxBarThickness - the maximum bar thickness.
      • getMaxBarThickness

        default int getMaxBarThickness()
        Returns the maximum bar thickness.
        Specified by:
        getMaxBarThickness in interface IsDefaultBarDatasets
        Returns:
        the maximum bar thickness.
      • setMinBarLength

        default void setMinBarLength​(int minBarLength)
        Set this to ensure that bars have a minimum length in pixels.
        Parameters:
        minBarLength - a minimum length in pixels.
      • getMinBarLength

        default int getMinBarLength()
        Returns a minimum length in pixels.
        Specified by:
        getMinBarLength in interface IsDefaultBarDatasets
        Returns:
        a minimum length in pixels.
      • setGrouped

        default void setGrouped​(boolean grouped)
        When true, all the data sets at same index value will be placed next to each other centering on that index value.
        When false, each bar is placed on its actual index-axis value.
        Parameters:
        grouped - if true, all the data sets at same index value will be placed next to each other centering on that index value
      • isGrouped

        default boolean isGrouped()
        When true, all the data sets at same index value will be placed next to each other centering on that index value.
        When false, each bar is placed on its actual index-axis value.
        Specified by:
        isGrouped in interface IsDefaultBarDatasets
        Returns:
        if true, all the data sets at same index value will be placed next to each other centering on that index value