Package org.aoju.bus.proxy.aspects
Class AspectjTimes
java.lang.Object
org.aoju.bus.proxy.aspects.AspectjSimple
org.aoju.bus.proxy.aspects.AspectjTimes
- All Implemented Interfaces:
Serializable,Aspectj
通过日志打印方法的执行时间的切面
- Since:
- Java 17+
- Author:
- Kimi Liu
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Methods inherited from class org.aoju.bus.proxy.aspects.AspectjSimple
after, afterException
-
Constructor Details
-
AspectjTimes
public AspectjTimes()
-
-
Method Details
-
before
Description copied from interface:Aspectj目标方法执行前的操作- Specified by:
beforein interfaceAspectj- Overrides:
beforein classAspectjSimple- Parameters:
target- 目标对象method- 目标方法args- 参数- Returns:
- 是否继续执行接下来的操作
-
after
Description copied from interface:Aspectj目标方法执行后的操作 如果 target.method 抛出异常且- Specified by:
afterin interfaceAspectj- Overrides:
afterin classAspectjSimple- Parameters:
target- 目标对象method- 目标方法args- 参数returnVal- 目标方法执行返回值- Returns:
- 是否允许返回值(接下来的操作)
- See Also:
-