下面哪个方法不属于session对象()。A、getAttributeNames()B、getServletContext()C、invalidate()D、addCookie(Cookie cook)
下面哪个方法不属于session对象()。
- A、getAttributeNames()
- B、getServletContext()
- C、invalidate()
- D、addCookie(Cookie cook)
相关考题:
Jsp内嵌对象session的类型为javax.servlet.http.HttpSession,下述语句会使该对象失效的是() A.session.dispose()B.session.clear()C.session.invalidate()D.session.removeAll()
以下方法,哪个可使session无效?( )A.session.removeAttribute(String key)B.session.invalidate()C.session.setAttribute(String key)D.session.getAttribute(String key)
下面哪项不是session对象的方法()A、getAttribute(Stringname)B、invalidate()C、getServletInfo()D、setAttribute(Stringname,Objectvalue)
下面哪个方法不属于session对象()。A、getAttributeNames()B、getServletContext()C、invalidate()D、addCookie(Cookiecook)
ASP提供的两个可用来存储变量的内建对象是______。A.Request对象和Application对象B.Session对象和Request对象C.Session对象和Application对象D.Session对象和Cookie对象
下面哪个方法设置MIME类型?()A、setHeader(String headerName,String headerValue)B、setContentType(String mimeType)C、setContentLength(int length)D、addCookie(Cookie c)E、addHeader(String name,String value)
在下列选项中,正确创建并实现写入cookie的语句分别是()。 A、 Cookie cookie = new Cookie( String key, Object value );B、 Cookie cookie = new Cookie();C、 response.add(cookie );D、 response.addCookie(cookie);
如果不希望JSP网页支持Session,应该如何办?()A、调用HttpSession的invalidate()方法B、〈%@ page session="false" /〉C、〈%@ page session 〉D、〈jsp:useBean id= "user" class= "UserData" scope= "session" /〉
写入和读取cookie的方法是()A、request.addCookies()和response.getCookies()B、response.addcookie()和request.getCookies()C、request.addCookies()和request.getCookies()D、response.addcookie()和response.getCookies()
下面哪个方法可使session无效() A、session.setAttribute()B、session.getAttribute()C、session.invalidate()D、session.removeAttribute()
下面哪句代码能获得硬盘上所有的Cookie?()A、Cookie cookie[]=request.getCookies()B、Cookie cookie[]=request.addCookies()C、response.addCookie(cookie)D、Cookie c=new cookie(“name”,“value”)E、以上选项都不能
Given an HttpServletRequest request and HttpServletResponse response,which sets a cookie "username"with the value "joe" in a servlet?()A、request.addCookie("username", "joe")B、request.setCookie("username", "joe")C、response.addCookie("username", "joe")D、request.addHeader(new Cookie("username", "joe"))E、request.addCookie(new Cookie("username", "joe"))F、response.addCookie(new Cookie("username", "joe"))
单选题下面哪个方法不属于session对象()。AgetAttributeNames()BgetServletContext()Cinvalidate()DaddCookie(Cookie cook)
单选题下面哪个方法可使session无效()Asession.setAttribute()Bsession.getAttribute()Csession.invalidate()Dsession.removeAttribute()
单选题Given an HttpServletRequest request and HttpServletResponse response,which sets a cookie "username"with the value "joe" in a servlet?()Arequest.addCookie(username, joe)Brequest.setCookie(username, joe)Cresponse.addCookie(username, joe)Drequest.addHeader(new Cookie(username, joe))Erequest.addCookie(new Cookie(username, joe))Fresponse.addCookie(new Cookie(username, joe))
单选题下面哪句代码能获得硬盘上所有的Cookie?()ACookie cookie[]=request.getCookies()BCookie cookie[]=request.addCookies()Cresponse.addCookie(cookie)DCookie c=new cookie(“name”,“value”)E以上选项都不能