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

struts 拦截器 施用

2012-11-01 
struts 拦截器 使用在action上加拦截器的时候,一定要先加@Scope(prototype)@Controller@Results( { @Res

struts 拦截器 使用
在action上加拦截器的时候,一定要先加

@Scope("prototype")@Controller@Results( { @Result(name = Constants.SHOW_ERROR, location = "/errorMessage.jsp"),@Result(name = Constants.INVALIDTOKEN, location = "/tokenErrMsg.jsp")})@ParentPackage("default")@InterceptorRefs(value = {@InterceptorRef("defaultStack"), @InterceptorRef("sessionTimeoutInterceptor") })@ExceptionMappings( {@ExceptionMapping(exception = "java.lang.Exception", result = Constants.SHOW_ERROR),@ExceptionMapping(exception = "com.community.exception.DataAccessException", result = Constants.SHOW_ERROR) })

热点排行