GIAC
GSSP-JAVA · Question #93
Which of the following methods of the HttpSession interface can be called upon an invalidated session without throwing the IllegalStateException?
The correct answer is B. getServletContext(). See the full explanation below for the reasoning.
Question
Which of the following methods of the HttpSession interface can be called upon an invalidated session without throwing the IllegalStateException?
Options
- AgetAttribute()
- BgetServletContext()
- CgetAttributesNames()
- Dinvalidate()
- EgetLastAccessedTime()
How the community answered
(24 responses)- A4% (1)
- B71% (17)
- C17% (4)
- E8% (2)
Community Discussion
No community discussion yet for this question.