use of kg.apc.charting.elements.GraphPanelChartExactElement in project jmeter-plugins by undera.
the class GraphRowExactValues method getElement.
@Override
public AbstractGraphPanelChartElement getElement(long value) {
AbstractGraphPanelChartElement ret = null;
Iterator<Entry<Long, AbstractGraphPanelChartElement>> it = values.entrySet().iterator();
while (it.hasNext() && ret == null) {
GraphPanelChartExactElement el = (GraphPanelChartExactElement) it.next().getValue();
if (el.getX() == value) {
ret = el;
}
}
return ret;
}
use of kg.apc.charting.elements.GraphPanelChartExactElement in project jmeter-plugins by undera.
the class GraphRowExactValuesTest method testGetElement.
/**
* Test of getElement method, of class GraphRowExactValues.
*/
@Test
public void testGetElement() {
System.out.println("getElement");
long value = 100L;
GraphRowExactValues instance = new GraphRowExactValues();
AbstractGraphPanelChartElement expResult = new GraphPanelChartExactElement(value, 2);
instance.add(value, 2);
AbstractGraphPanelChartElement result = instance.getElement(value);
Assert.assertTrue(instance.getElement(value).getValue() == expResult.getValue());
}
use of kg.apc.charting.elements.GraphPanelChartExactElement in project jmeter-plugins by undera.
the class GraphPanelChartExactElementTest method testGetValue.
/**
* Test of getValue method, of class GraphPanelChartExactElement.
*/
@Test
public void testGetValue() {
System.out.println("getValue");
GraphPanelChartExactElement instance = new GraphPanelChartExactElement(1, 1);
double expResult = 1.0;
double result = instance.getValue();
Assert.assertEquals(expResult, result, 0.0);
}
use of kg.apc.charting.elements.GraphPanelChartExactElement in project jmeter-plugins by undera.
the class GraphRowExactValues method add.
/**
* @param xVal
* @param yVal
*/
@Override
public void add(long xVal, double yVal) {
GraphPanelChartExactElement el;
el = new GraphPanelChartExactElement(xVal, yVal);
values.put((long) values.size(), el);
super.add(xVal, yVal);
}
use of kg.apc.charting.elements.GraphPanelChartExactElement in project jmeter-plugins by undera.
the class GraphPanelChartExactElementTest method testAdd.
/**
* Test of add method, of class GraphPanelChartExactElement.
*/
@Test
public void testAdd() {
System.out.println("add");
double val = 0.0;
GraphPanelChartExactElement instance = new GraphPanelChartExactElement(0, 0);
instance.add(val);
}
Aggregations