MCQ of Unit 3 AJP
MCQ of Unit 3 AJP
MCQ of Unit 3 AJP
Q9. Which of these package contains all the event handling interfaces?
a) Java.lang
b) Java.awt
c) Java.awt.event
d) Java.event
Q13. Which of these constant value will change when the button at the end of scrollbar was
clicked to increase its value?
a) BLOCK_DECREMENT
b) BLOCK_INCREMENT
c) UNIT_DECREMENT
d) UNIT_INCREMENT
Q16. Which of these events is generated when the size of component is changed?
a) ComponentEvent
b) ContainerEvent
c) FocusEvent
d) InputEvent
Q17. Which of these events is generated when the component is added or removed?
a) ComponentEvent
b) ContainerEvent
c) FocusEvent
d) InputEvent
Q19. Which of these events is generated when computer gains or losses input focus?
a) ComponentEvent
b) ContainerEvent
c) FocusEvent
d) InputEvent
Q26. ____ is the abstract super class of all component input event class
a) KeyEvent
b) ItemEvent
c) ActionEvent
d) InputEvent
Q30. Which of these method are used to register a keyboard event listener?
a) KeyListener()
b) ADDKeyListener()
c) addKeyListener()
d) eventKeyboardListener()
Q32. Which of these methods can be used to know which key is pressed?
a) getKey()
b) getModifier()
c) getActionKey()
d) getActionEvent()
Q33. Which of these methods can be used to obtain the coordinates of a mouse?
a) getPoint()
b) getCoordinates()
c) GetMouseXY()
d) getMouseCoordinates()
a) Applet
b) ComponentEvent
c) Event
d) InputEvent
Q40. Which of these packages contains all the classes and methods required for even handling in
Java?
a) java.applet
b) java.awt
c) java.event
d) java.awt.event
Q42. Which of these packages contains all the event handling interfaces?
a) java.lang
b) java.awt
c) java.awt.event
d) java.event