Class PriceData

java.lang.Object
com.motivewave.platform.sdk.common.PriceData

public class PriceData extends Object
Represents price related information for a price bar. Use this class to provide data for displaying price bars. Optionally a color may be specified. If no color is specified the default colors defined for the chart will be used.
  • Constructor Details

    • PriceData

      public PriceData(float open, float high, float low, float close)
      Constructor. Creates price data for a particular bar.
      Parameters:
      open - - opening price
      high - - high price for the bar
      low - - low price for the bar
      close - - closing price for the bar
    • PriceData

      public PriceData(float open, float high, float low, float close, Color color)
      Constructor. Creates price data for a particular bar.
      Parameters:
      open - - opening price
      high - - high price for the bar
      low - - low price for the bar
      close - - closing price for the bar
      color - - color to paint the bar (null for default bar color)
  • Method Details

    • getOpen

      public float getOpen()
      Gets the opening value for the bar.
      Returns:
      opening price
    • getHigh

      public float getHigh()
      Gets the high value for the bar.
      Returns:
      high price
    • getLow

      public float getLow()
      Gets the low value for the bar.
      Returns:
      low price
    • getClose

      public float getClose()
      Gets the closing value for the bar.
      Returns:
      closing price
    • getColor

      public Color getColor()
      Gets the color for this bar (null for default bar colors).
      Returns:
      bar color
    • getValue

      public float getValue(Enums.BarInput input)