1.
Your web site has many user-customizable features, for example font and color preferences on web pages. Your IT department has already built a subsystem for user preferences using Java SE's lang.util.prefs package APIs and you have been ordered to reuse this subsystem in your web application.You need to create an event listener that stores the user's Preference object when an HTTP session is created. Also, note that user identification information is stored in an HTTP cookie. Which partial listener class can accomplish this goal?
2.
Which interface must a session attribute implement if it needs to be notified when a web container persists a session?
3.
Given the definition of MyObject and that an instance of MyObject is bound as a session attribute: Which is true?]
4.
Which interface must a class implement so that instances of the class are notified after any object is added to a session?
5.
Given: What code, inserted at line 21, is called prior to a session being migrated to a different JVM assuming the web application containing MyExample is deployed in a container which supports distributed applications?
6.
Your web application requires the adding and deleting of many session attributes during a complex use case. A bug report has come in that indicates that an important session attribute is being deleted too soon and a NullPointerException is being thrown several interactions after the fact. You have decided to create a session event listener that will log when attributes are being deleted so you can track down when the attribute is erroneously being deleted.Which listener class will accomplish this debugging goal?
7.
A developer for the company web site has been told that users may turn off cookie support in their browsers. What must the developer do to ensure that these customers can still use the web application?
8.
Which method must be used to encode a URL passed as an argument to HttpServletResponse.sendRedirect when using URL rewriting for session tracking?
9.
Given: What is the result?
10.
A developer wants to use EL to invoke a function using ${my:bloof("foof")}. Which is always true?