Example usage for org.jfree.data.xy XIntervalSeries getXHighValue

List of usage examples for org.jfree.data.xy XIntervalSeries getXHighValue

Introduction

In this page you can find the example usage for org.jfree.data.xy XIntervalSeries getXHighValue.

Prototype

public double getXHighValue(int index) 

Source Link

Document

Returns the upper bound of the x-interval for the specified item.

Usage

From source file:org.jfree.data.xy.XIntervalSeriesTest.java

/**
 * A simple check for getXHighValue()./*from  w  ww .  j  av a2 s. c o m*/
 */
@Test
public void testGetXHighValue() {
    XIntervalSeries s1 = new XIntervalSeries("S1");
    s1.add(1.0, 2.0, 3.0, 4.0);
    assertEquals(3.0, s1.getXHighValue(0), EPSILON);
    s1.add(2.0, 1.0, 4.0, 2.5);
    assertEquals(4.0, s1.getXHighValue(1), EPSILON);
}

From source file:org.jfree.data.xy.XIntervalSeriesCollection.java

/**
 * Returns the end x-value (as a double primitive) for an item within a
 * series./*from w w  w. j a va 2 s .c o  m*/
 *
 * @param series  the series (zero-based index).
 * @param item  the item (zero-based index).
 *
 * @return The value.
 */
@Override
public double getEndXValue(int series, int item) {
    XIntervalSeries s = (XIntervalSeries) this.data.get(series);
    return s.getXHighValue(item);
}