首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > 软件管理 > 软件架构设计 >

struts2 Action中获取request, response对象的步骤

2012-09-05 
struts2 Action中获取request, response对象的方法struts2 Action中获取request,?response对象的方法?Acti

struts2 Action中获取request, response对象的方法

struts2 Action中获取request,?response对象的方法?

 ActionContext ctx = ActionContext.getContext();                 HttpServletRequest request = (HttpServletRequest)ctx.get(ServletActionContext.HTTP_REQUEST);                 HttpServletResponse response = (HttpServletResponse)ctx.get(ServletActionContext.HTTP_RESPONSE);                  //ServletActionContext.APPLICATION;          //ServletActionContext.SESSION;          //ServletActionContext.PAGE_CONTEXT;    
?

热点排行