开发者社区 问答 正文

对拦截环绕通知的说明是什么呀?

对拦截环绕通知的说明是什么呀?

展开
收起
去校区学技术 2022-03-31 19:30:33 332 分享 版权
1 条回答
写回答
取消 提交回答
  • 在Spring中最基础的通知类型是据截环统通知(interceptionaround advice)。

    Spring里使用方法拦截的环绕通知兼容AOP联盟接口。实现环绕通知的MethodInterceptor应当实现下面的接口:

    public interface MethodInterceptor extends Interceptor{
    
    Object invoke(MethodInvocation invocation) throws Throwable;
    
    }
    
    2022-03-31 19:32:40
    赞同 展开评论
问答地址: