Monday, 20 February 2012
J2EE: SERVLET: SERVLET API
Do you like this Article?
Java Servlet API is that Application Program Interface (API), which defines and describes the contracts between servlets and servers. That means, it contains the set of programs and standard instructions to develop a proper access between a servlet and the server. Servlet API is a part of the official J2EE API. This API contains 2 packages with the extension javax. They are as follows.
· Package javax.servlet
· Package javax.servlet.http
Package javax.servlet:
- Package javax.servlet deals with the contracts between a servlet class and the runtime environment offered for an instance of the class, within the servlet container.
- It contains a set of classes and interfaces. Some important classes and interfaces like, Class GenericServlet which implements Interface Servlet. Apart from that, interfaces like Filter, RequestDispatcher, ServletRequest, ServletResponse, etc. and classes like ServletInputStream, ServletOutputStream, etc are also belong of this package. It also contains 2 exceptions, and they are ServletException and UnavailableException.
Package javax.servlet.http:
- Package javax.servlet.http deals with the contracts between a servlet class, which is running under HTTP protocol and the runtime environment offered for an instance of the class, within the servlet container.
- It also contains some important classes and interfaces. Some of them are, Interfaces like HttpSession, HttpServletResponse, HttpServletRequest, HttpSessionBindingListener, etc and classes like Cookie, HttpServlet (which implements Interface Servlet of javax.servlet package), etc.
Uses of Servlet API:
- Management of Servlet life cycle.
- It provides access to servlet context.
- It also provides some utility classes.
- And last but not least, it also provides classes to handle HTTP protocol.
Subscribe to:
Post Comments
(
Atom
)
Popular Posts
-
public - public means everyone can access it.That means it's in global scope. As, main method is called by JVM [ Java Virtual Machine...
-
throw is used to throw an exception in a program, explicitly . Whereas, throws is included in the method's declaration part, wi...
-
Singleton in one of the most popular yet controversial design pattern, in the world of object oriented programming. It's one of t...
-
Web Container / Servlet Container / Servlet Engine : In J2EE Architecture , a web container (also known as servlet container or ser...
-
Program compiles. But at runtime throws an error “NoSuchMethodError”.
-
Vector : It's synchronized. It's slower than ArrayList. It's generally used in ...
-
doGet(): protected void doGet(HttpServletRequest req, HttpServletResponse resp)throws ServletException, java.io.IOException – is a met...
-
In Java Programming Language , we must declare a variable name and type, before using it. The data type of a variable defines the th...
11 Responses to “ J2EE: SERVLET: SERVLET API ”
12 March 2012 at 15:38
Well experience J2ee stuff. Thanks for this.
Interview Questions
31 October 2014 at 17:57
HI, Friends this very usefull java servlet interview questions
for excellent knowledge on java servlet visit http://www.itsoftpoint.com/?page_id=2425
1 July 2017 at 17:56
I have seen lot blogs and Information on othersites But in this Java Blog Information is very useful thanks for sharing it........
5 October 2017 at 12:50
Thankyou for the information I was handling many java projects As I am a PMP Certified Expert where my PMP Course in Mumbai had a great impact on me with different set of elements Well thankyou for the blog Keep Updating.
9 February 2018 at 18:22
Webtrackker Technology
Webtrackker Technology is an IT company which is providing the Webtrackker Technology - Webtrackker is IT company which is providing the Mean stack, mobile apps,
website development service in India, uk, usa, kanada, new zealand Etc.
Webtrackker , Webtrackker
Webtrackker, Webtrackker, Webtrackker , Webtrackker , Webtrackker review, Webtrackker
review, Webtrackker review, vermeer, Webtrackker
reviews, Webtrackker review, Webtrackker
review, Webtrackker Technology, Webtrackker Technology, Webtrackker Technology, Webtrackker Technology, Webtrackker Technology, Webtrackker Technology, Webtrackker, Webtrackker Technology, Webtrackker Reviews.
17 June 2020 at 11:26
Your good knowledge and kindness in playing with all the pieces were
very useful. I don’t know what I would have done if I had not
encountered such a step like this. very good jobs.
Ai & Artificial Intelligence Course in Chennai
PHP Training in Chennai
Ethical Hacking Course in Chennai Blue Prism Training in Chennai
UiPath Training in Chennai
7 November 2020 at 15:52
I wanted to leave a little comment to support you and wish you a good continuation. Wishing you the best of luck for all your blogging efforts.
Best Digital Marketing Courses in Hyderabad
15 April 2023 at 16:19
This Blog is Nice!
Python full stack Job Oriented Training in Hyderabad
21 July 2023 at 12:29
Thanks for sharing the blog
Python fullstack course in Hyderabad
24 October 2024 at 17:37
insightful and very important blog, thankyou
Data science Courses in Manchester
24 December 2024 at 09:44
Nice Article!
Thanks for sharing with us 🙂
Best software Training Institute in Hyderabad
Post a Comment