GeeCON Prague 2014*
The moose likes Servlets and the fly likes removeAttribute Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


JavaRanch » Java Forums » Java » Servlets
Bookmark "removeAttribute" Watch "removeAttribute" New topic
Author

removeAttribute

friso jonge
Ranch Hand

Joined: Aug 06, 2002
Posts: 41
The above method in httpsession, does it clear its resources as well, (bascally setting the removed object to null) or is the attribute itself still available ?
thanks,
friso
William Brogden
Author and all-around good cowpoke
Rancher

Joined: Mar 22, 2000
Posts: 12792
    
    5
You don't set an object to null, you set a reference to null. The reference in the session is set to null, whether or not the object you attached to a session is GCed when you remove it depends on if other references exist.
Bill
 
GeeCON Prague 2014
 
subject: removeAttribute