ActionForm 与 Action 中的验证
来源:互联网 发布:营销书籍推荐知乎 编辑:程序博客网 时间:2024/05/03 17:17
ActionForm:
public ActionErrors validate(
ActionMapping mapping,
HttpServletRequest request) ...{
ActionErrors errors=new ActionErrors();
errors.add("userId",new ActionMessage("error.userid.exists"));
return errors;
}
ActionMapping mapping,
HttpServletRequest request) ...{
ActionErrors errors=new ActionErrors();
errors.add("userId",new ActionMessage("error.userid.exists"));
return errors;
}
Action:
public ActionForward execute(
ActionMapping mapping,
ActionForm form,
HttpServletRequest request,
HttpServletResponse response)
...{
ActionMessages errors=new ActionMessages();
errors.add( ActionMessages.GLOBAL_MESSAGE,
new ActionMessage("error.sort.havetopic"));
this.saveErrors(request,errors);
return mapping.findForward("fail");
}
return mapping.findForward("other");
}
ActionMapping mapping,
ActionForm form,
HttpServletRequest request,
HttpServletResponse response)
...{
ActionMessages errors=new ActionMessages();
errors.add( ActionMessages.GLOBAL_MESSAGE,
new ActionMessage("error.sort.havetopic"));
this.saveErrors(request,errors);
return mapping.findForward("fail");
}
return mapping.findForward("other");
}
- ActionForm 与 Action 中的验证
- action -- actionform
- Action和ActionForm组合
- 结合验证在struts中减少Action和ActionForm的数量 选择自 fancyerII 的 Blog
- 结合验证在struts中减少Action和ActionForm的数量
- Action 3 ActionForm(未整理)
- 转帖:Struts Action and ActionForm
- Struts Action and ActionForm (转)
- 简略Struts构架 Action/ActionForm
- VO,DAO,BO,ActionForm,Action
- Struts 中的ActionForm
- Struts中的动态ActionForm
- struts中的ActionForm原理
- struts1.2中的ActionForm
- Struts的ActionForm表单验证
- Struts的ActionForm表单验证
- ActionForm与VO
- struts2.3.20的action中的validate验证
- volatile用法
- [xfire] 配置XFireClientFactoryBean时 设置 lookupServiceOnStartup = false
- 转贴:mplayer在ARM9(s3c2410)上的移植
- 教师资格考试之高等教育学模拟试题(A卷)
- 转贴:ARM MPlayer移植过程
- ActionForm 与 Action 中的验证
- 最令PHP初学者头痛的问题
- Linux下配置功能完善的Web服务器
- Access “不能更新 数据库或对象为只读”的解决方法
- CSS样式-li
- Web 2.0 中AJAX技术应用详解
- C语言嵌入式系统编程修炼
- 坚定的跟着盖茨大哥走,只用.NET,不用java!
- 透过防火墙访问internet上的sde server