ALLInterview.com :: Home Page KalAajKal.com
 Advertise your Business Here     
Browse  |   Placement Papers  |   Company  |   Code Snippets  |   Certifications  |   Visa Questions
Post Question  |   Post Answer  |   My Panel  |   Search  |   Articles  |   Topics  |   ERRORS new
   Refer this Site  Refer This Site to Your Friends  Site Map  Bookmark this Site  Set it as your HomePage  Contact Us     Login  |  Sign Up                      
Do you have a collection of Interview Questions and interested to share with us!!
Please send that collection to along with your userid / name. ThanQ
Google
 
Categories  >>  Software  >>  Java J2EE  >>  Java Related  >>  Servlets
 
 


 

 
 Core Java interview questions  Core Java Interview Questions
 Advanced Java interview questions  Advanced Java Interview Questions
 Swing interview questions  Swing Interview Questions
 EJB interview questions  EJB Interview Questions
 Servlets interview questions  Servlets Interview Questions
 Struts interview questions  Struts Interview Questions
 JDBC interview questions  JDBC Interview Questions
 JMS interview questions  JMS Interview Questions
 SunOne interview questions  SunOne Interview Questions
 J2EE interview questions  J2EE Interview Questions
 Weblogic interview questions  Weblogic Interview Questions
 Websphere interview questions  Websphere Interview Questions
 Java Networking interview questions  Java Networking Interview Questions
 Java J2EE AllOther interview questions  Java J2EE AllOther Interview Questions
Question
can we override service method in my servlet class..?? if 
yes or no why ??
 Question Submitted By :: Raj.polu
I also faced this Question!!     Rank Answer Posted By  
 
  Re: can we override service method in my servlet class..?? if yes or no why ??
Answer
# 1
yes, we can override service() in our servlet, but not 
preferable. if we want use these service from any protocol 
like ftp,telnet, then we have to override.
 
Is This Answer Correct ?    6 Yes 0 No
Sekhar Babu
 
  Re: can we override service method in my servlet class..?? if yes or no why ??
Answer
# 2
we can override service method in my servlet class if the 
request is not protocol dependent.
Bcoz we exdend HttpSrevlet class to handle Http GET and 
POST requests and we have to override some methods like 
doGet,doPost,doHead,doPut,doDelete.

But if u want to override service method then u have to 
extend genricServlet Class.Then only u can implement Service
() method.
 
Is This Answer Correct ?    1 Yes 0 No
Ruchi
 
 
 

 
 
 
Other Servlets Interview Questions
 
  Question Asked @ Answers
 
What advantages do servlets have over CGI programs?  3
how to use servlets with j2ee ? Tech-Mahindra1
Can threads be used in Servelet?  1
What is the difference between an applet and a servlet?  8
What is the protocol used by Server & Client?  2
What are the parameters of the service method ?  2
What is the difference between ExecuteUpdate and ExecuteQuery?  3
How to work with Chinese login page (internationalization).if he enters user name and password in chinese, how is it converted to English and validate in db? And in reverse it should display welcome message in Chinese,if user is valid Bosch3
What are the exceptions thrown by Servlets?  2
How can you maintain servlet chaining?  1
How to maintain security in servlets?  2
In which cases Destroy() is invoked?  2
we cant Override Jsp Service method?Why? Mind-Tree2
What is DSN and System DSN and what is the difference between them?  1
Explain the methods in Generic and HTTP Servlets?  1
What is use of parseQueryString ?  1
what are the CGI Programs?  2
In howmany ways applet-servlet communication can be done?  1
How servlets can be automatically reloaded?  1
How values can be passed from HTML page to servlet? ABC2
 
For more Servlets Interview Questions Click Here 
 
 
 
 
 
   
Copyright Policy  |  Terms of Service  |  Help  |  Site Map 1  |  Articles  |  Site Map  |   Site Map  |  Contact Us interview questions urls   External Links 
   
Copyright © 2007  ALLInterview.com.  All Rights Reserved.

ALLInterview.com   ::  Forum9.com   ::  KalAajKal.com