Well,as far as i know, the event object passed as an argument to the event handler function in Java, holds the additional information about the event. So, that means it might not be important at times to pass that argument until we require it.
But then, that's not the case...since it throws an error if the object parameter is missing. For example, this would throw an error..
public void actionPerformed() { //since the event object parameter is missing
button.setText("Clicked");
}
why is it so? It's just a waste at times to pass the parameter, so why is there no method in the Swing/AWT Java API that allows event handlers consisting of no parameters at all? That would really comfort a lot. NO?