Interface OnlineCalculatable.DataCoordinateMarker

Enclosing interface:
OnlineCalculatable

public static interface OnlineCalculatable.DataCoordinateMarker
Marker bound to data coordinates. Useful for, say, bars.
  • Method Details

    • getMinY

      double getMinY()
      Y coordinate of the lower edge. Used to adjust the range of bottom panel. Doesn't have to be strictly equal to the actual icons edge coordinate, since it's only used for range adjustments. If you are OK with part of the icon being out of range, you can specify only the critical part boundaries.
    • getMaxY

      double getMaxY()
      Similar to getMinY(), but for the upper edge.
    • getValueY

      double getValueY()
      Value used for the widget/line
    • makeMarker

      OnlineCalculatable.Marker makeMarker(Function<Double,Integer> yDataCoordinateToPixelFunction)
      Creates a visual representation of the marker.
      Parameters:
      yDataCoordinateToPixelFunction - function that converts y data coordinate to pixel coordinate mapped to the chart pixels range. Pixel coordinates should be used to calculate OnlineCalculatable.Marker height and pixels offset. If data coordinate is out of chart limits, it is mapped to the pixels outside the chart pixels.
      Returns:
      marker that is drawn on the chart or null if no marker should be drawn.