java.lang.Object | |
↳ | org.springframework.aop.support.AopUtils |
Utility methods for AOP support code. Mainly for internal use within Spring's AOP support.
See AopProxyUtils
for a
collection of framework-specific AOP utility methods which depend
on internals of Spring's AOP framework implementation.
Public Constructors | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
Can the given advisor apply at all on the given class?
This is an important test as it can be used to optimize out a advisor for a class. | |||||||||||
Can the given pointcut apply at all on the given class?
This is an important test as it can be used to optimize out a pointcut for a class. | |||||||||||
Can the given pointcut apply at all on the given class?
This is an important test as it can be used to optimize out a pointcut for a class. | |||||||||||
Can the given advisor apply at all on the given class?
This is an important test as it can be used to optimize
out a advisor for a class.
| |||||||||||
Determine the sublist of the
candidateAdvisors list
that is applicable to the given class. | |||||||||||
Given a method, which may come from an interface, and a target class used
in the current AOP invocation, find the corresponding target method if there
is one.
| |||||||||||
Determine the target class of the given bean instance which might be an AOP proxy.
| |||||||||||
Invoke the given target via reflection, as part of an AOP method invocation.
| |||||||||||
Check whether the given object is a JDK dynamic proxy or a CGLIB proxy.
| |||||||||||
Check whether the given object is a CGLIB proxy.
| |||||||||||
Check whether the specified class is a CGLIB-generated class.
| |||||||||||
Check whether the specified class name is a CGLIB-generated class.
| |||||||||||
Determine whether the given method is an "equals" method.
| |||||||||||
Determine whether the given method is a "finalize" method.
| |||||||||||
Determine whether the given method is a "hashCode" method.
| |||||||||||
Check whether the given object is a JDK dynamic proxy.
| |||||||||||
Determine whether the given method is a "toString" method.
|
[Expand]
Inherited Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
From class
java.lang.Object
|
Can the given advisor apply at all on the given class?
This is an important test as it can be used to optimize out a advisor for a class. This version also takes into account introductions (for IntroductionAwareMethodMatchers).
advisor | the advisor to check |
---|---|
targetClass | class we're testing |
hasIntroductions | whether or not the advisor chain for this bean includes any introductions |
Can the given pointcut apply at all on the given class?
This is an important test as it can be used to optimize out a pointcut for a class.
pc | the static or dynamic pointcut to check |
---|---|
targetClass | the class to test |
Can the given pointcut apply at all on the given class?
This is an important test as it can be used to optimize out a pointcut for a class.
pc | the static or dynamic pointcut to check |
---|---|
targetClass | the class to test |
hasIntroductions | whether or not the advisor chain for this bean includes any introductions |
Can the given advisor apply at all on the given class? This is an important test as it can be used to optimize out a advisor for a class.
advisor | the advisor to check |
---|---|
targetClass | class we're testing |
Determine the sublist of the candidateAdvisors
list
that is applicable to the given class.
candidateAdvisors | the Advisors to evaluate |
---|---|
clazz | the target class |
Given a method, which may come from an interface, and a target class used
in the current AOP invocation, find the corresponding target method if there
is one. E.g. the method may be IFoo.bar()
and the target class
may be DefaultFoo
. In this case, the method may be
DefaultFoo.bar()
. This enables attributes on that method to be found.
NOTE: In contrast to getMostSpecificMethod(Method, Class>)
,
this method resolves Java 5 bridge methods in order to retrieve attributes
from the original method definition.
method | the method to be invoked, which may come from an interface |
---|---|
targetClass | the target class for the current invocation.
May be null or may not even implement the method. |
targetClass
doesn't implement it or is null
Determine the target class of the given bean instance which might be an AOP proxy.
Returns the target class for an AOP proxy and the plain class else.
candidate | the instance to check (might be an AOP proxy) |
---|
null
)Invoke the given target via reflection, as part of an AOP method invocation.
target | the target object |
---|---|
method | the method to invoke |
args | the arguments for the method |
Throwable | if thrown by the target method |
---|---|
AopInvocationException | in case of a reflection error |
Check whether the given object is a JDK dynamic proxy or a CGLIB proxy.
object | the object to check |
---|
Check whether the given object is a CGLIB proxy.
object | the object to check |
---|
Check whether the specified class is a CGLIB-generated class.
clazz | the class to check |
---|
Check whether the specified class name is a CGLIB-generated class.
className | the class name to check |
---|
Determine whether the given method is an "equals" method.
Determine whether the given method is a "finalize" method.
Determine whether the given method is a "hashCode" method.
Check whether the given object is a JDK dynamic proxy.
object | the object to check |
---|
Determine whether the given method is a "toString" method.