阿摩線上測驗
登入
首頁
>
OCE
>
無年度 - Java EE 6 Web Component Developer Certified Expert Exam:1z0-899(51-100)#84004
> 申論題
64 Which EL expression evaluates to the request URI? (A) ${requestURI} (B) ${request.URI} (C) ${request.getURI} (D) ${request.requestURI} (E) ${requestScope.requestURI} F. ${pageContext.request.requestURI} G. ${requestScope.request.requestDRI}
相關申論題
69 As a convenience feature, your web pages include an Ajax request every five minutes to a special servlet that monitors the age of the user's session. The client-side JavaScript that handles the Ajax callback displays a message on the screen as the session ages. The Ajax call does NOT pass any cookies, but it passes the session ID in a request parameter called sessionI(D) In addition, assume that your webapp keeps a hasmap of session objects by the I(D) Here is a partial implementation of this servlet: 10. public class SessionAgeServlet extends HttpServlet { 11. public void service(HttpServletRequest request, HttpServletResponse) throws IOException { 12. String sessionID = request.getParameter("sessionID"); 13. HttpSession session = getSession(sessionID); 14. long age = // your code here 15. response.getWriter().print(age); 16. } ... // more code here 47. } Which code snippet on line 14, will determine the age of the session? (A) session.getMaxInactiveInterval(); (B) session.getLastAccessed().getTime() - session.getCreationTime().getTime(); (C) session.getLastAccessedTime().getTime() - session.getCreationTime().getTime(); (D) session.getLastAccessed() - session.getCreationTime(); (E) session.getMaxInactiveInterval() - session.getCreationTime(); F. session.getLastAccessedTime() - session.getCreationTime();
#340622
相關試卷
無年度 - Java EE 6 Web Component Developer Certified Expert Exam:1z0-899 (101-132)#84682
#84682
無年度 - Java EE 6 Web Component Developer Certified Expert Exam:1z0-899(1-50)#84202
#84202
無年度 - Java EE 6 Web Component Developer Certified Expert Exam:1z0-899(51-100)#84004
#84004