Java Basic


  1. Which of these methods can be used to obtain the reference to the container that generated a ContainerEvent?











  1. View Hint View Answer Discuss in Forum

    NA

    Correct Option: C

    getContainerEvent()


  1. Which of these events is generated when the component is added or removed?











  1. View Hint View Answer Discuss in Forum

    NA

    Correct Option: D

    A ContainerEvent is generated when a component is added to or removed from a container. It has two integer constants COMPONENT_ADDED & COMPONENT_REMOVED.



  1. Which of these are integer constants of ComponentEvent class?











  1. View Hint View Answer Discuss in Forum

    NA

    Correct Option: D

    The component event class defines 4 constants COMPONENT_HIDDEN, COMPONENT-MOVED, COMPONENT-RESIZE and COMPONENT-SHOWN.


  1. Which of these constant value will change when the button at the end of scroll bar was clicked to increase its value?











  1. View Hint View Answer Discuss in Forum

    NA

    Correct Option: A

    UNIT_INCREMENT VALUE will change when the button at the end of scroll bar was clicked to increase its value.



  1. Which of these methods can be used to know the degree of adjustment made by the user?











  1. View Hint View Answer Discuss in Forum

    NA

    Correct Option: C

    The amount of the adjustment can be obtained from the getvalue() method, it returns an integer value corresponding to the amount of adjustment made.