Forums Register Login

Help...Static items in session beans

+Pie Number of slices to send: Send
Hypothetical situation,
I have a java bean accessible from a JSP page using the <jsp:usebean> tag. The bean is declared to have "session" scope. This means that the bean's associated properties, etc. remain constant over the duration of the user's session and are "local" to that user.
Question:
If there are methods or variables defined inside the bean as "static", do those methods and variables retain the same values across different bean instances with "session" scope?
Example: User A and User B are each using a different instance of the bean mentioned above with session scope. If User A changes a property of the bean which internally is defined as static, will User B see the change?
Any help would greatly appreciated..
T
Does anyone know if a "static" method or variable declared in a java bean defined as having a "session" scope in JSP
+Pie Number of slices to send: Send

"trevor"
your name doesn't agree with the javaranch guidelines.
please take a moment and re-register after reviewing the
guidelines at http://www.javaranch.com/name.jsp
thanks for your cooperation.

- satya
That new kid is a freak. Show him this tiny ad:
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com


reply
reply
This thread has been viewed 686 times.
Similar Threads
How to get the bean object in servlet from jsp?
Help...Static items in session beans
long post IBM.158
Access a session scope bean in another bean
static class attibutes vs. application objects
More...

All times above are in ranch (not your local) time.
The current ranch time is
Mar 28, 2024 14:00:46.