Interface Indicator

All Known Subinterfaces:
IndicatorModifiable

public interface Indicator
Indicator representing a line.
  • Method Summary

    Modifier and Type Method Description
    void addIcon​(double value, java.awt.image.BufferedImage icon, int iconCenterX, int iconCenterY)
    Add icon rendered in a point corresponding to specified value
    void addPoint​(double value)
    Set new line Y coordinate in indicator coordinates space.
    void setAxisRules​(AxisRules axisRules)
    Set rules for selecting indicator range.
    void setColor​(java.awt.Color color)
    Set new line color.
    void setLineStyle​(LineStyle lineStyle)
    Set new line style.
    void setRenderPriority​(int renderPriority)
    Essentially controls Z (depth) coordinate of the line.
    void setWidgetRules​(WidgetRules widgetRules)  
    void setWidth​(int width)
    Set new line width.
  • Method Details

    • addPoint

      void addPoint​(double value)
      Set new line Y coordinate in indicator coordinates space. Double.NaN to stop drawing (can be imagined as switching to invisible color)
      Parameters:
      value - new value
    • addIcon

      void addIcon​(double value, java.awt.image.BufferedImage icon, int iconCenterX, int iconCenterY)
      Add icon rendered in a point corresponding to specified value
      Parameters:
      value - value defining vertical position of an icon
      icon - the icon itself
      iconCenterX - x coordinate on the image that will be matched to event time
      iconCenterY - y coordinate on the image that will be matched to event price
    • setColor

      void setColor​(java.awt.Color color)
      Set new line color. Applied immediately.
      Parameters:
      color - new line color
    • setWidth

      void setWidth​(int width)
      Set new line width. Applied immediately.
      Parameters:
      width - width in pixels
    • setLineStyle

      void setLineStyle​(LineStyle lineStyle)
      Set new line style. Applied immediately.
      Parameters:
      lineStyle - new line style
    • setRenderPriority

      void setRenderPriority​(int renderPriority)
      Essentially controls Z (depth) coordinate of the line. Lines with higher values will be "closer" to the screen (on top of the ones with lower values). See Layer1ApiUserMessageModifyIndicator.LayerRenderPriority for reference values. You should normally specify the position relative to one of the values specified in it.
      Parameters:
      renderPriority - requested render priority of the layer
    • setAxisRules

      void setAxisRules​(AxisRules axisRules)
      Set rules for selecting indicator range. Please keep in mind, that when part of AxisGroup this method should not be called directly, instead call corresponding AxisGroup.setAxisRules(AxisRules)
      Parameters:
      axisRules - object describing the rules
    • setWidgetRules

      void setWidgetRules​(WidgetRules widgetRules)