A friendly place for programming greenhorns!
Big Moose Saloon
Register / Login
Win a copy of
Refactoring for Software Design Smells: Managing Technical Debt
this week in the
OO, Patterns, UML and Refactoring
Joined: Jun 28, 2005
Jun 29, 2005 01:25:00
How does the application object(
context) is accessed from any where
in the web application? what is the role of application.getAttribute(" ") method in this?
Joined: May 31, 2004
Jun 29, 2005 02:28:00
Application container can be accessed in this fashion
javax.servlet.ServletContext context = getServletContext();
is your application object.
You can use the following line of code to store any object at the application level:
Now if you want to retrieve the object from the application scope you can use the following line of code:
MyApplicationObject myApplicationObject = (MyApplicationObject) context.getAttribute("myObject");
I’ve looked at a lot of different solutions, and in my humble opinion Aspose is the way to go. Here’s the link:
Deploy Java Application On Customer Side?
single threaded or multi threaded
adding tomcat 6.0 error
Tech Word Game
All times are in JavaRanch time: GMT-6 in summer, GMT-7 in winter
| Powered by
Copyright © 1998-2015