Multiple choice technology programming languages

From which of the following methods can’t a stateful session bean access the methods of another bean?

  1. ejbRemove()

  2. ejbPassivate()

  3. setSessionContext()

  4. ejbCreate()

  5. None of the above

Reveal answer Fill a bubble to check yourself
C Correct answer
Explanation

During setSessionContext(), the bean is still being initialized and doesn't have access to other beans or their methods. The security context and environment resources are not yet fully available. In ejbCreate(), ejbRemove(), and ejbPassivate(), the bean is fully initialized and can interact with other beans. This restriction applies specifically to the context initialization phase.