| Author |
Interview questions
|
sanjana narayanan
Ranch Hand
Joined: Nov 25, 2003
Posts: 142
|
|
Hi, I went through some interview questions in this forum just to refresh my knowledge on the concepts. I might also appear for an interview in the near future. can someone confirm this answers for the questions mentioned. 1.What are the type of protocols used in HttpServlet ? HTTP is the widely used protocol. we can also use SMTP,POP,FTP 2.Is there any heavy weight component in Swings ? no. Swings are light weight components. AWT has heavy weight components 3.what are the different types of multithreading? No idea. I referred a couple of books on threads but couldn't get what i wanted. Any explanation would be appreciated. -sanjana
|
 |
Eric Lemaitre
Ranch Hand
Joined: Jul 03, 2004
Posts: 538
|
|
Hi ! I would say (IMHO) : 1) Not OK, HTTP only. 2) Totally OK. 3) green threads and native threads, former are a Threads mechanism controlled by JVM itself so platform independant, latter are as their name states calls to native platform system multithreading features so relies on platform when available (much more efficient of course). Beast regards.
|
Eric LEMAITRE
CNAM IT Engineer, MS/CS (RHCE, RHCX, SCJA, SCJP, SCJD, SCWCD, SCBCD, SCEA, Net+)
Free Online Tutorials: http://www.free-tutorials-online.net/
|
 |
danny liu
Ranch Hand
Joined: Jan 22, 2004
Posts: 185
|
|
sanjana, I recall that Swing components are built above AWT. So, Swing components are heavy-weight compared to AWT. Dan [ August 13, 2004: Message edited by: danny liu ]
|
 |
peter wooster
Ranch Hand
Joined: Jun 13, 2004
Posts: 1033
|
|
Originally posted by danny liu: sanjana, I recall that Swing components are built above AWT. So, Swing components are heavy-weight compared to AWT. Dan [ August 13, 2004: Message edited by: danny liu ]
Danny Liu Your answer is incorrect. Please read this for details on the weight of Swing components. [ November 04, 2004: Message edited by: peter wooster ] [ November 04, 2004: Message edited by: peter wooster ]
|
 |
Grishma Dube
Ranch Hand
Joined: Jul 01, 2003
Posts: 273
|
|
2.Is there any heavy weight component in Swings ? no. Swings are light weight components. AWT has heavy weight components
No Eric, You're wrong. Swings are based on AWT. Though swing components are light weight components, there are still 4 components which are heavy weight in swings viz JWindow, JApplet, JFrame and JDialog. Grishma
|
 |
Mark Herschberg
Sheriff
Joined: Dec 04, 2000
Posts: 6037
|
|
Originally posted by danny liu: peter wooster When you KNOW NOTHING about a topic, please refrain from dumping your ignorance on those who ask for assistance. You obviously know NOTHING about Java Swing, have you ever been there?
This type of posting is very inappropriate. Feel free to correct other people if you think they are wrong, but personal attacks have no place on this site. I strongly encourage you to edit your message ASAP. --Mark
|
 |
Alvin chew
Ranch Hand
Joined: Jan 08, 2004
Posts: 834
|
|
|
i would agree with peter, swing is light weight component
|
 |
peter wooster
Ranch Hand
Joined: Jun 13, 2004
Posts: 1033
|
|
Originally posted by Alvin chew: i would agree with peter, swing is light weight component
Actually, Grishma is correct on this, the top level components are heavyweight and all the rest are lightweight. That's what makes that interview question interesting. Its explained in the Sun document I linked to, under the heading "Heavy vs light: the differences".
|
 |
Eric Lemaitre
Ranch Hand
Joined: Jul 03, 2004
Posts: 538
|
|
Hi all ! I believe we should stop quarelling/arguing about this point, we almost all learned main difference between AWT and Swing was Heavyweight against Lightweight, so I consider as a slight minor fault only believing all Swing is Lightweight. We have too such "traps" in our job interviews about IT culture such as "who leads Microsoft", but we don't eliminate people who answer "Bill Gates" instead of "Steve Balmer", avoiding this trap is a simple nice bonus. The article was interesting, thanks for the link, I will know more about this subject for next time. Best regards.
|
 |
Mark Herschberg
Sheriff
Joined: Dec 04, 2000
Posts: 6037
|
|
Peter, I appreciate that you edited your message once, but it's still unncessarily hostile. Consider the following phrasing, for example, "That is incorrect, as explained in the reference here." --Mark
|
 |
 |
|
|
subject: Interview questions
|
|
|