Package Controller
Class ButtonListener
java.lang.Object
Controller.ButtonListener
- All Implemented Interfaces:
java.awt.event.ActionListener,java.util.EventListener
public class ButtonListener
extends java.lang.Object
implements java.awt.event.ActionListener
This Class contains a listener which reacts when the Run Tests button is
pressed. It is the only Class that knows of the Model and thereby is the
Class that starts the logic process when the button is pressed.
-
Constructor Summary
Constructors Constructor Description ButtonListener(javax.swing.JTextField inputText1, javax.swing.JTextArea outputText1)The constructor of the class which specifies which textField is to be used in the Controller. -
Method Summary
Modifier and Type Method Description voidactionPerformed(java.awt.event.ActionEvent actionEvent)The method that performs if the button is pressed.
-
Constructor Details
-
ButtonListener
public ButtonListener(javax.swing.JTextField inputText1, javax.swing.JTextArea outputText1)The constructor of the class which specifies which textField is to be used in the Controller.- Parameters:
inputText1- the JTextField you want to input to.outputText1- the JTextArea to output text to.
-
-
Method Details
-
actionPerformed
public void actionPerformed(java.awt.event.ActionEvent actionEvent)The method that performs if the button is pressed. It runs any TestClass which is located in the Test package of this program.- Specified by:
actionPerformedin interfacejava.awt.event.ActionListener- Parameters:
actionEvent- the event to be monitored.
-