public class DataBindingMethodResolver extends ReflectiveMethodResolver
MethodResolver
variant for data binding
purposes, using reflection to access instance methods on a given target object.
This accessor does not resolve static methods and also no technical methods
on java.lang.Object
or java.lang.Class
.
For unrestricted resolution, choose ReflectiveMethodResolver
instead.
forInstanceMethodInvocation()
,
DataBindingPropertyAccessor
Modifier and Type | Method and Description |
---|---|
static DataBindingMethodResolver |
forInstanceMethodInvocation()
Create a new data-binding method resolver for instance method resolution.
|
protected boolean |
isCandidateForInvocation(java.lang.reflect.Method method,
java.lang.Class<?> targetClass)
Determine whether the given
Method is a candidate for method resolution
on an instance of the given target class. |
MethodExecutor |
resolve(EvaluationContext context,
java.lang.Object targetObject,
java.lang.String name,
java.util.List<TypeDescriptor> argumentTypes)
Locate a method on a type.
|
getMethods, registerMethodFilter
public MethodExecutor resolve(EvaluationContext context, java.lang.Object targetObject, java.lang.String name, java.util.List<TypeDescriptor> argumentTypes) throws AccessException
ReflectiveMethodResolver
resolve
in interface MethodResolver
resolve
in class ReflectiveMethodResolver
context
- the current evaluation contexttargetObject
- the object upon which the method is being calledargumentTypes
- the arguments that the constructor must be able to handleAccessException
protected boolean isCandidateForInvocation(java.lang.reflect.Method method, java.lang.Class<?> targetClass)
ReflectiveMethodResolver
Method
is a candidate for method resolution
on an instance of the given target class.
The default implementation considers any method as a candidate, even for
static methods sand non-user-declared methods on the Object
base class.
isCandidateForInvocation
in class ReflectiveMethodResolver
method
- the Method to evaluatetargetClass
- the concrete target class that is being introspectedpublic static DataBindingMethodResolver forInstanceMethodInvocation()