Prepare Interview

Mock Exams

Make Homepage

Bookmark this page

Subscribe Email Address

Core Java Interview Questions and Answers

Test your skills through the online practice test: Core Java Quiz Online Practice Test

Ques 246. What is skeleton and stub? what is the purpose of those?

Stub is a client side representation of the server, which takes care of communicating with the remote server. Skeleton is the server side representation. But that is no more in use' it is deprecated long before in JDK.

Is it helpful? Add Comment View Comments
 

Ques 247. What is the SwingUtilities.invokeLater(Runnable) method for?

The static utility method invokeLater(Runnable) is intended to execute a new runnable thread from a Swing application without disturbing the normal sequence of event dispatching from the Graphical User Interface (GUI). The method places the runnable object in the queue of Abstract Windowing Toolkit (AWT) events that are due to be processed and returns immediately. The runnable object run() method is only called when it reaches the front of the queue. The deferred effect of the invokeLater(Runnable) method ensures that any necessary updates to the user interface can occur immediately, and the runnable work will begin as soon as those high priority events are dealt with. The invoke later method might be used to start work in response to a button click that also requires a significant change to the user interface, perhaps to restrict other activities, while the runnable thread executes.

Is it helpful? Add Comment View Comments
 

Ques 248. What is a lightweight component?

Lightweight components are the one which doesn't go with the native call to obtain the graphical units. They share their parent component graphical units to render them. Example, Swing components

Is it helpful? Add Comment View Comments
 

Ques 249. What is a heavyweight component?

For every paint call, there will be a native call to get the graphical units. Example, AWT.

Is it helpful? Add Comment View Comments
 

Ques 250. What is the difference between lightweight and heavyweight component?

Lightweight components reuses its parents graphical units. Heavyweight components goes with the native graphical unit for every component. Lightweight components are faster than the heavyweight components.

Is it helpful? Add Comment View Comments
 

Most helpful rated by users:

©2024 WithoutBook