File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Servlets and the fly likes about ServletContext and ServletConfig Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Servlets
Bookmark "about ServletContext and ServletConfig" Watch "about ServletContext and ServletConfig" New topic

about ServletContext and ServletConfig

vara prasad
Ranch Hand

Joined: Dec 21, 2004
Posts: 47
what is ServletContext and what is ServletConfig exatly?
and what is the actual differances ?
and what is the uses of both ServletContext and ServletConfig?
Ben Souther

Joined: Dec 11, 2004
Posts: 13410

The javadocs are your friend.

Java API J2EE API Servlet Spec JSP Spec How to ask a question... Simple Servlet Examples jsonf
James Carman
Ranch Hand

Joined: Feb 20, 2001
Posts: 580
The ServletConfig object exposes information specific to your servlet (like initialization parameters). The ServletContext basically represents your webapp.

James Carman, President<br />Carman Consulting, Inc.
I agree. Here's the link:
subject: about ServletContext and ServletConfig
It's not a secret anymore!