2012年9月21日金曜日

struts2 アクションクラスの中、リクエストの取得

struts2 アクションクラスの中、リクエストの取得


HttpServletRequest request = ServletActionContext.getRequest();
もしくは

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

0 件のコメント:

コメントを投稿