Action得到HttpServletRequestt,HttpServletResponse

 

		ActionContext ctx = ActionContext.getContext();
		HttpServletRequest request = (HttpServletRequest) ctx
				.get(ServletActionContext.HTTP_REQUEST);


		ActionContext ctx = ActionContext.getContext();
		HttpServletReponse response= (HttpServletResponse) ctx
				.get(ServletActionContext.HTTP_RESPONSE);

 在Struts2中得到

HttpServletRequest对象             HttpServletResponse 对象

你可能感兴趣的:(Action得到HttpServletRequestt,HttpServletResponse)