|
1. What is the List interface? The List interface provides support for ordered collections of objects. 2. Name three Component subclasses that support painting. The Canvas, Frame, Panel, and Applet classes support painting. 3. What restrictions are placed on the location of a package statement within a source code file? A package statement must appear as the first line in a source code file (excluding blank lines and comments). 4. What is the range of the short type? The range of the short type is -(2^15) to 2^15 - 1. 5. What is the GregorianCalendar class? The GregorianCalendar provides support for traditional Western calendars. 6. What is a native method? A native method is a method that is implemented in a language other than Java. 7. 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. 8. Which characters may be used as the second character of an identifier, but not as the first character of an identifier? The digits 0 through 9 may not be used as the first character of an identifier but they may be used after the first character of an identifier. 9. What are wrapped classes? Wrapped classes are classes that allow primitive types to be accessed as objects. 10. What invokes a thread's run() method? After a thread is started, via its start() method or that of the Thread class, the JVM invokes the thread's run() method when the thread is initially executed. 11. 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. 12. What is the difference between preemptive scheduling and time slicing? Under preemptive scheduling, the highest priority task executes until it enters the waiting or dead states or a higher priority task comes into existence. Under time slicing, a task executes for a predefined slice of time and then reenters the pool of ready tasks. The scheduler then determines which task should execute next, based on priority and other factors. 13. What is clipping? Clipping is the process of confining paint operations to a limited area or shape. 14. What is the difference between a MenuItem and a CheckboxMenuItem? The CheckboxMenuItem class extends the MenuItem class to support a menu item that may be checked or unchecked. 15. 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.
|