Hi friends, am newbie to servlet. My interviewer asked why
used servlet in your application.
i used servlet for controller logic and business logic .
is it correct ?

Answer Posted / madan

yes, servlets is used for purely for Controller.i think do u know MVC layer( Model View Control),control for Servlet,View for Jsp,Model for business logic..

based on the technology we used, the model will be changed
for example, if u use jsf,ejb
jsf is view and ejb is for model(business)
in struts, jsp is view, beans for model

Different persons are approaching different ways..
but are not used for business logic because we have these many technologies which maintain the B.logic

ok

Is This Answer Correct ?    1 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Can we get PrintWriter and ServletOutputStream both in a servlet?

909


What is the disadvantage of cookies?

784


Where do you define dispatcherservlet?

759


Explain servlet events?

764


Whether thread can be used in servlets?

957


What is the difference between Difference between doGet() and doPost()?

986


How do we call one servlet from another servlet?

768


Why do we use sendredirect() method?

752


What do you mean by cgi?

718


What is servlet container. how it works?

891


What do you mean by filter in servlet?

745


Explain web application directory arrangement?

803


what is the different between a servlet and a cgi? Why do you go for servlet rather than cgi?

785


hi actully i hav form columns with origin and destination names .as like as i need to create one more column with name amount. my requirement is when i select origin and destination columns automatically i need to get amount from database.how can i. please tel me with relative code

2525


Describe the phases of servlet lifecycle?

831