Question: JAVA multiple choice questions 1. Which of the following is false ? a. Once an event listener has been removed from a component, it can

JAVA multiple choice questions

1. Which of the following is false?

a. Once an event listener has been removed from a component, it can be added to the component again.

b. In order to remove an event listener from a component, the component must be instantiated inside an anonymous inner class.

c. When removing an event listener using the required method, the method doesn't throw an exception even if the event listener is not found.

d. Once a listener is removed from a component, the listener no longer receives component events from this component.

2. Consider the following line of code

fileChooser.showOpenDialog(...);

where fileChooser is a JFileChooser. If the parameter ... is a component, where would the dialog be positioned?

a. relative to the screen.

b. relative to the component.

c. relative to the current visible window.

d. relative to the JFrame.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!