Advanced Java - Interview Questions and Answers


  1. What class is the top of the AWT event hierarchy?
    The java.awt.AWTEvent class is the highest-level class in the AWT event-class hierarchy.
  2. When a thread is created and started, what is its initial state?
    A thread is in the ready state after it has been created and started.
  3. Can an anonymous class be declared as implementing an interface and extending a class?
    An anonymous class may implement an interface or extend a superclass, but may not be declared to do both.
  4. What is the immediate superclass of Menu?
    MenuItem.
  5. What is the purpose of finalization?
    The purpose of finalization is to give an unreachable object the opportunity to perform any cleanup processing before the object is garbage collected.
  6. Which class is the immediate superclass of the MenuComponent class?
    Object.

« Prev   [ Page 8 of 31  Jump... Next »

Jump to page : 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 |