Class ScalesNode


  • public final class ScalesNode
    extends NativeObjectContainer
    Wrapper of scales node of CHART.JS.
    This is a wrapper of scale node of Chart (of CHART.JS).
    Author:
    Andrea "Stock" Stocchero
    • Constructor Detail

      • ScalesNode

        public ScalesNode​(ChartEnvelop<NativeObject> envelop)
        Creates the item using an envelop with the native java script object which contains all properties.
        Parameters:
        envelop - envelop with the native java script object which contains all properties.
    • Method Detail

      • getItems

        public Map<String,​ScaleItem> getItems()
        Returns a map with all defined axis. Key is the scale ID and value is scale item.
        Returns:
        a map with all defined axis. Key is the scale ID and value is scale item.
      • getScaleIsInside

        public ScaleItem getScaleIsInside​(NativeAbstractMouseEvent event)
        Returns the scale item if the chart event is inside of one of scales, otherwise null.
        Parameters:
        event - event to check if inside of one of scales.
        Returns:
        the scale item if the chart event is inside of one of scales, otherwise null
      • isInside

        public boolean isInside​(NativeAbstractMouseEvent event)
        Returns true if the chart event is inside of one of scales, otherwise false.
        Parameters:
        event - event to check if inside of one of scales.
        Returns:
        true if the chart event is inside of one of scales, otherwise false
      • isInside

        public default boolean isInside​(NativeBaseEvent event)
        Returns true if the chart event is inside of a chart element, otherwise false.
        Parameters:
        event - event to check if inside of a chart element.
        Returns:
        true if the chart event is inside a chart element, otherwise false
      • isInside

        public default boolean isInside​(HasNativeEvent container)
        Returns true if the chart event is inside of this box, otherwise false.
        Parameters:
        container - event container to check if inside the box
        Returns:
        true if the chart event is inside of this box, otherwise false