what is the diff between Servletcontext and servletconfig?
Answer Posted / srinu
servletcontext:
1) servletcontext object one for webapplication
2)it used global init parameters
3)with help servletcontext object we find our webserver
ingformation(public java.lang.String getServerInfo())
servletConfig:
1)servletConfig object will be created every servlet suppose
in my webapplication 10 servlets are their 10 servletConfig
object will be created but only one SwervletContext object
will be created
2) it is the righthand object of servlet
3)it used local init parameters
4)with help of servletConfig object we find out logical name
of servlet(public java.lang.String getServletName())
| Is This Answer Correct ? | 4 Yes | 0 No |
Post New Answer View All Answers
What is a war file?
What do you understand by access specifiers in Java?
How can we achieve thread safety in java?
What is annotation in java?
Can you inherit from an abstract class java?
Why does it take so much time to access an applet having swing components the first time?
Why java applets are more useful for intranets as compared to internet?
Can you make a constructor final?
What's the default access specifier for variables and methods of a class?
What is the same as procedures?
Is null false in java?
Can classes declared using the abstract keyword cab be instantiated?
How to find the given number is a prime number or not by getting input from the user
Convert a BST into a DLL and DLL to BST in place.
What is collection sort in java?