org.apache.jmeter.testelement
Class LineChart
java.lang.Object
org.apache.jmeter.testelement.AbstractTestElement
org.apache.jmeter.testelement.AbstractChart
org.apache.jmeter.testelement.LineChart
- All Implemented Interfaces:
- java.io.Serializable, java.lang.Cloneable, ReportChart, TestElement
public class LineChart
- extends AbstractChart
- See Also:
- Serialized Form
Fields inherited from class org.apache.jmeter.testelement.AbstractChart |
DEFAULT_HEIGHT, DEFAULT_WIDTH, image, REPORT_CHART_CAPTION, REPORT_CHART_HEIGHT, REPORT_CHART_TITLE, REPORT_CHART_WIDTH, REPORT_CHART_X_AXIS, REPORT_CHART_X_LABEL, REPORT_CHART_Y_AXIS, REPORT_CHART_Y_LABEL, X_DATA_DATE_LABEL, X_DATA_FILENAME_LABEL, X_LABELS |
Method Summary |
double[][] |
convertToDouble(java.util.List data)
|
java.awt.Shape[] |
createShapes(int count)
Since we only have 4 shapes, the method will start with the
first shape and keep cycling through the shapes in order. |
java.awt.Stroke[] |
createStrokes(int count)
|
java.lang.String |
getURLs()
|
java.awt.Shape |
nextShape()
Return the next shape |
java.awt.Stroke |
nextStroke()
|
javax.swing.JComponent |
renderChart(java.util.List dataset)
Subclasses will need to implement the method by doing the following:
1. get the x and y axis
2. filter the table data
3. pass the data to the chart library
4. return the generated chart |
javax.swing.JComponent |
renderGraphics(double[][] data,
java.lang.String[] xAxisLabels)
|
void |
setURLs(java.lang.String urls)
|
Methods inherited from class org.apache.jmeter.testelement.AbstractChart |
getBufferedImage, getCaption, getFormattedXAxis, getHeight, getTitle, getValue, getWidth, getXAxis, getXLabel, getYAxis, getYLabel, setBufferedImage, setCaption, setHeight, setTitle, setWidth, setXAxis, setXLabel, setYAxis, setYLabel |
Methods inherited from class org.apache.jmeter.testelement.AbstractTestElement |
addProperty, addTestElement, canRemove, clear, clearTemporary, clone, emptyTemporary, equals, getComment, getName, getProperty, getPropertyAsBoolean, getPropertyAsBoolean, getPropertyAsDouble, getPropertyAsFloat, getPropertyAsInt, getPropertyAsInt, getPropertyAsLong, getPropertyAsString, getPropertyAsString, getThreadContext, getThreadName, hashCode, isEnabled, isRunningVersion, isTemporary, logProperties, mergeIn, propertyIterator, recoverRunningVersion, removeProperty, setComment, setName, setProperty, setProperty, setProperty, setProperty, setProperty, setProperty, setProperty, setRunningVersion, setTemporary, setThreadContext, setThreadName, traverse, traverseCollection, traverseMap, traverseProperty |
Methods inherited from class java.lang.Object |
finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
width
protected int width
height
protected int height
shape_counter
protected int shape_counter
LineChart
public LineChart()
getURLs
public java.lang.String getURLs()
setURLs
public void setURLs(java.lang.String urls)
convertToDouble
public double[][] convertToDouble(java.util.List data)
renderChart
public javax.swing.JComponent renderChart(java.util.List dataset)
- Description copied from class:
AbstractChart
- Subclasses will need to implement the method by doing the following:
1. get the x and y axis
2. filter the table data
3. pass the data to the chart library
4. return the generated chart
- Specified by:
renderChart
in interface ReportChart
- Specified by:
renderChart
in class AbstractChart
- Parameters:
dataset
- list of DataSet
- Returns:
- the component
renderGraphics
public javax.swing.JComponent renderGraphics(double[][] data,
java.lang.String[] xAxisLabels)
createShapes
public java.awt.Shape[] createShapes(int count)
- Since we only have 4 shapes, the method will start with the
first shape and keep cycling through the shapes in order.
- Parameters:
count
-
- Returns:
- array of shapes
nextShape
public java.awt.Shape nextShape()
- Return the next shape
- Returns:
- the shape
createStrokes
public java.awt.Stroke[] createStrokes(int count)
- Parameters:
count
-
- Returns:
- array of strokes
nextStroke
public java.awt.Stroke nextStroke()
Copyright © 1998-2010 Apache Software Foundation. All Rights Reserved.