Granny's Programming Pearls
"inside of every large program is a small program struggling to get out"
JavaRanch.com/granny.jsp
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

a question from sun's assessment test.

 
mallika shah
Ranch Hand
Posts: 164
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hello all,
here is a question,

A non-transient String field in an interceptor associated with a stateful session bean is set to "Hello" when the stateful session bean is passivated.

What will the state of the field be after the bean is again activated?

The specification states that the value will be undefined.
It will be set to null.
It is set to "Hello".
The bean will be associated with an arbitrary interceptor instance after activation, and so can have whatever value the field is set to in that interceptor instance.

my ans: it is set to hello
is that correct?

mallika
 
tiger lee
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Yes. you are right for this. "Hello" is a correct answer.
 
Hey, sticks and stones baby. And maybe a wee mention of my stuff:
the new thread boost feature brings a LOT of attention to your favorite threads
https://coderanch.com/t/674455/Thread-Boost-feature
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!