
aspectj
文章平均质量分 73
gaojian881
这个作者很懒,什么都没留下…
展开
专栏收录文章
- 默认排序
- 最新发布
- 最早发布
- 最多阅读
- 最少阅读
-
cflow的使用
cflow(pointcut):表示在执行连接点pointcut所匹配的函数时进行匹配,如下例所示: aj中的代码: package com.gaojian.aspectj.test; public aspect MyAspectj { pointcut callF(): execution(* f(..)) && cflow(call(* com.gaojian...原创 2011-10-23 17:00:28 · 439 阅读 · 0 评论 -
pointcut的定义
一:一个典型的aspect类的形式如下: public aspect MyAspectj { //定义连接点函数 pointcut callF(): execution(* f(..)) && cflow(call(* Test.foo(..))); //定义通知函数 before() : ca...原创 2011-10-24 15:25:13 · 981 阅读 · 0 评论 -
aspectj中call和execution的区别
call 和 execution 的指示符分别为 call ( Method-Signature )、 execution ( Method-Signature ),匹配方法签名的方法或构造函数的执行。 对于 call 来说,调用的连接点位于方法调用点的调用代码处;对于 execution 来说,执行的连接点位...原创 2011-10-24 15:26:08 · 1370 阅读 · 0 评论 -
aj通知函数
MyAspectj中的代码: package com.gaojian.aspectj.test; public aspect MyAspectj { /*调用某个文件夹下面所有的class*/ // pointcut callF(): execution(* com.gaojian..*.*(..)); /** * 1) before...原创 2011-10-25 13:36:44 · 174 阅读 · 0 评论