Hi There
Basially speaking there is no difference between Servlets and JSP atleast
from the processing point of view.JSPs get compiled to servlets n so on n so
forth
When you need to include more processing like a login page do it in a
servlet
There is no hard n fast rule, depends on ur needs
If u have HTML programmers who know nothing of Java and you have to use JSPs
since thatll be
easier for them to design the page and then for u to include the Java
scriptlets
Aternatively u can also include all the functionality in ur JSPs. I usually
prefer that
since it is easier going thro ur JSPs while debugging than Servlets.
Here are a couple of links where u can find comparisons
http://javaboutique.internet.com/tutorials/JSP/part01/page04.html
http://wdvl.internet.com/Authoring/Java/Servlets/intro.html
Hope it helps
Regards
sanjay
-----Original Message-----
From: Anthony Mak [mailto:[EMAIL PROTECTED]]
Sent: 17 November 2000 01:37
To: [EMAIL PROTECTED]
Subject: Re: Difference between Servlet and Bean?
Dear Sanjay,
If I have Bean handling all the business logic and JSP pages for
presentation, do I still need to use Servlet? It seems a JSP (presentation)
+ Bean (business logic) combination will suffice at least for small
application. Can you think of a situation where I might need to use Servlet
as well?
Anthony Mak
----- Original Message -----
From: "Sanjay Gomes" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Thursday, November 16, 2000 8:11 PM
Subject: Re: Difference between Servlet and Bean?
> Hi Phil
> You are right about the beans, as used in the JSP/s or servlets,are used
to
> contain Business logic.
> They are similar in the fact that they contain the set/get methods and
dont
> contain the bean structure.They are not 'pure beans' as we run them in a
BDK
> BeanBox
> Regards
> Sanjay
>
>
>
> -----Original Message-----
> From: Phil Hedley [mailto:[EMAIL PROTECTED]]
> Sent: 16 November 2000 09:27
> To: [EMAIL PROTECTED]
> Subject: Re: Difference between Servlet and Bean?
>
>
> From: Phil Hedley@MITEL on 11/16/2000 09:27 AM GMT
>
> Checkout thisdocument as an idea of how to approach the problem
> http://www.javaworld.com/javaworld/jw-12-1999/jw-12-ssj-jspmvc.html
>
> The example is not perfect, but the model states that the recommended
> approach
> is to have a single servlet to handle all requests. The requests are
passed
> on
> to the the appropriate classes(or beans) to perform the business logic.
> I found the term 'beans' rather confusing in that the classes that handle
> the
> business logic do not have to be Java beans, they can be just ordinary
Java
> classes with no special structure. The bean structure is only required for
> introspection if you use for example the set/get property directives in
the
> jsp
> page.
>
> cheers,
> Phil Hedley
>
>
>
>
>
> Anthony Mak <[EMAIL PROTECTED]> on 16/11/2000 01:41:09
>
> Please respond to A mailing list about Java Server Pages specification and
> reference <[EMAIL PROTECTED]>
>
> To: [EMAIL PROTECTED]
> cc: (bcc: Phil Hedley/Cal/Mitel)
>
> Subject: Difference between Servlet and Bean?
>
>
>
> Dear all,
>
> I heard it is good idea to seperate business logic out of JSP by using
> Servlet or Bean.
>
> The logical question I have now in mind is what is the difference between
> Servlet and Bean? Should I implement my business logic in Bean or Servlet?
>
> Anthony Mak
>
>
===========================================================================
> To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff
> JSP-INTEREST".
> Some relevant FAQs on JSP/Servlets can be found at:
>
> http://java.sun.com/products/jsp/faq.html
> http://www.esperanto.org.nz/jsp/jspfaq.html
> http://www.jguru.com/jguru/faq/faqpage.jsp?name=JSP
> http://www.jguru.com/jguru/faq/faqpage.jsp?name=Servlets
>
>
===========================================================================
> To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff
> JSP-INTEREST".
> Some relevant FAQs on JSP/Servlets can be found at:
>
> http://java.sun.com/products/jsp/faq.html
> http://www.esperanto.org.nz/jsp/jspfaq.html
> http://www.jguru.com/jguru/faq/faqpage.jsp?name=JSP
> http://www.jguru.com/jguru/faq/faqpage.jsp?name=Servlets
>
>
===========================================================================
> To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff
JSP-INTEREST".
> Some relevant FAQs on JSP/Servlets can be found at:
>
> http://java.sun.com/products/jsp/faq.html
> http://www.esperanto.org.nz/jsp/jspfaq.html
> http://www.jguru.com/jguru/faq/faqpage.jsp?name=JSP
> http://www.jguru.com/jguru/faq/faqpage.jsp?name=Servlets
>
===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff
JSP-INTEREST".
Some relevant FAQs on JSP/Servlets can be found at:
http://java.sun.com/products/jsp/faq.html
http://www.esperanto.org.nz/jsp/jspfaq.html
http://www.jguru.com/jguru/faq/faqpage.jsp?name=JSP
http://www.jguru.com/jguru/faq/faqpage.jsp?name=Servlets
===========================================================================
To unsubscribe: mailto [EMAIL PROTECTED] with body: "signoff JSP-INTEREST".
Some relevant FAQs on JSP/Servlets can be found at:
http://java.sun.com/products/jsp/faq.html
http://www.esperanto.org.nz/jsp/jspfaq.html
http://www.jguru.com/jguru/faq/faqpage.jsp?name=JSP
http://www.jguru.com/jguru/faq/faqpage.jsp?name=Servlets