example where transient is used
1 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   Anonymous
Posted On:   Friday, August 20, 2004 04:08 AM

what is the use of transient variable. Give an example of the situation where it is used.

Re: example where transient is used

Posted By:   Christopher_Koenigsberg  
Posted On:   Monday, August 30, 2004 04:28 PM

All of our classes in web applications implement Serializable. So we also start each one of them off, with "private static transient Log logger = LogFactory.getLog(blah.class)" (that's org.apache.commons.logging.Log). That way if they are serialized in session scope on a clustered app server, there will not be a problem with the Log, which is not serializable.

About | Sitemap | Contact