Package weka.gui.beans
Class ChartEvent
java.lang.Object
java.util.EventObject
weka.gui.beans.ChartEvent
- All Implemented Interfaces:
Serializable
Event encapsulating info for plotting a data point on the StripChart
- Version:
- $Revision: 10216 $
- Author:
- Mark Hall
- See Also:
-
Constructor Summary
ConstructorDescriptionChartEvent
(Object source) Creates a newChartEvent
instance.ChartEvent
(Object source, Vector<String> legendText, double min, double max, double[] dataPoint, boolean reset) Creates a newChartEvent
instance. -
Method Summary
Modifier and TypeMethodDescriptiondouble[]
Get the data pointGet the legend text vectordouble
getMax()
Get the max y valuedouble
getMin()
Get the min y valueboolean
getReset()
get the value of the reset flagvoid
setDataPoint
(double[] dp) Set the data pointvoid
setLegendText
(Vector<String> lt) Set the legend text vectorvoid
setMax
(double m) Set the max y valuevoid
setMin
(double m) Set the min y valuevoid
setReset
(boolean reset) Set the reset flagMethods inherited from class java.util.EventObject
getSource, toString
-
Constructor Details
-
ChartEvent
public ChartEvent(Object source, Vector<String> legendText, double min, double max, double[] dataPoint, boolean reset) Creates a newChartEvent
instance.- Parameters:
source
- the source of the eventlegendText
- a vector of strings to display in the legendmin
- minimum y valuemax
- maximum y valuedataPoint
- an array of y values to plotreset
- true if display is to be reset
-
ChartEvent
Creates a newChartEvent
instance.- Parameters:
source
- the source of the event
-
-
Method Details
-
getLegendText
Get the legend text vector- Returns:
- a
Vector
value
-
setLegendText
Set the legend text vector- Parameters:
lt
- aVector
value
-
getMin
public double getMin()Get the min y value- Returns:
- a
double
value
-
setMin
public void setMin(double m) Set the min y value- Parameters:
m
- adouble
value
-
getMax
public double getMax()Get the max y value- Returns:
- a
double
value
-
setMax
public void setMax(double m) Set the max y value- Parameters:
m
- adouble
value
-
getDataPoint
public double[] getDataPoint()Get the data point- Returns:
- a
double[]
value
-
setDataPoint
public void setDataPoint(double[] dp) Set the data point- Parameters:
dp
- adouble[]
value
-
setReset
public void setReset(boolean reset) Set the reset flag- Parameters:
reset
- aboolean
value
-
getReset
public boolean getReset()get the value of the reset flag- Returns:
- a
boolean
value
-