crystalized
Programmer
Hello All,
I know this was always a hot topic of discussion on the asp forum but I could not find any threads discussing it in this forum.
So here is my question. What is the better route to take, I have a user object. I could either just have properties in the object that get and set individual session variable values, or I could instantiate the user object and keep it in the session.
The user object does not have a huge number of properties and some of them may be blank or null. It does not contain any arrays or other complex data structures all the properties are strings, bytes or boolean values.
So part of me thinks that it is more understandable to create the user object and keep it in the session as a complete entity, but the other part of me sees that as a potential memory hog, especially since some of the properties will be blank or unused in a number of the user instances.
Any thoughts or words from experience on this topic would be greatly appreciated.
Crystal
crystalized_s@yahoo.com
--------------------------------------------------
Experience is one thing you can't get for nothing.
-Oscar Wilde
I know this was always a hot topic of discussion on the asp forum but I could not find any threads discussing it in this forum.
So here is my question. What is the better route to take, I have a user object. I could either just have properties in the object that get and set individual session variable values, or I could instantiate the user object and keep it in the session.
The user object does not have a huge number of properties and some of them may be blank or null. It does not contain any arrays or other complex data structures all the properties are strings, bytes or boolean values.
So part of me thinks that it is more understandable to create the user object and keep it in the session as a complete entity, but the other part of me sees that as a potential memory hog, especially since some of the properties will be blank or unused in a number of the user instances.
Any thoughts or words from experience on this topic would be greatly appreciated.
Crystal
crystalized_s@yahoo.com
--------------------------------------------------
Experience is one thing you can't get for nothing.
-Oscar Wilde