ActionEvent
ActionEvent is a type of event in Java's AWT/Swing event model that signals a user action on a component, such as pressing a button, selecting a menu item, or pressing Enter in a text field. It is generated by components capable of triggering actions, including JButton, JMenuItem, and other AbstractButton descendants, as well as certain text components.
An ActionEvent is delivered to listeners that implement the ActionListener interface (java.awt.event.ActionListener). The listener method actionPerformed(ActionEvent
Typical usage involves registering a listener with addActionListener on the component. If multiple controls share a
ActionEvent forms part of the broader event-handling model in Java GUI programming and is used for discrete