Objects that implement the KeyListener interface can receive KeyEvent objects. Listeners must first register themselves with objects that produce events. When events occur, they are then automatically propagated to all registered listeners.
public abstract interface java.awt.event.KeyListener extends java.util.EventListener { // Instance Methods public abstract void keyPressed (KeyEvent e); public abstract void keyReleased (KeyEvent e); public abstract void keyTyped (KeyEvent e); }
The key event that occurred.
Notifies the KeyListener that a key was pressed.
The key event that occurred.
Notifies the KeyListener that a key was released.
The key event that occurred.
Notifies the KeyListener that a key was typed (pressed and released).
AWTEventMulticaster, EventListener, KeyEvent, KeyListener