Package org.jfree.chart
Class ChartMouseEvent
java.lang.Object
java.util.EventObject
org.jfree.chart.ChartMouseEvent
- All Implemented Interfaces:
Serializable
A mouse event for a chart that is displayed in a
ChartPanel.- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final JFreeChartThe chart that the mouse event relates to.private final ChartEntityThe chart entity (if any).private static final longFor serialization.private final MouseEventThe Java mouse event that triggered this event.Fields inherited from class java.util.EventObject
source -
Constructor Summary
ConstructorsConstructorDescriptionChartMouseEvent(JFreeChart chart, MouseEvent trigger, ChartEntity entity) Constructs a new event. -
Method Summary
Modifier and TypeMethodDescriptiongetChart()Returns the chart that the mouse event relates to.Returns the chart entity (if any) under the mouse point.Returns the mouse event that triggered this event.Methods inherited from class java.util.EventObject
getSource, toString
-
Field Details
-
serialVersionUID
private static final long serialVersionUIDFor serialization.- See Also:
-
chart
The chart that the mouse event relates to. -
trigger
The Java mouse event that triggered this event. -
entity
The chart entity (if any).
-
-
Constructor Details
-
ChartMouseEvent
Constructs a new event.- Parameters:
chart- the source chart (nullnot permitted).trigger- the mouse event that triggered this event (nullnot permitted).entity- the chart entity (if any) under the mouse point (nullpermitted).
-
-
Method Details
-
getChart
Returns the chart that the mouse event relates to.- Returns:
- The chart (never
null).
-
getTrigger
Returns the mouse event that triggered this event.- Returns:
- The event (never
null).
-
getEntity
Returns the chart entity (if any) under the mouse point.- Returns:
- The chart entity (possibly
null).
-