Package jakarta.el
Class MethodReference
- java.lang.Object
-
- jakarta.el.MethodReference
-
public class MethodReference extends Object
Provides information about the method to which a method expression resolves. Two MethodReference instances are considered equal if the reference the same method on the same base object.
-
-
Constructor Summary
Constructors Constructor Description MethodReference(Object base, MethodInfo methodInfo, Annotation[] annotations, Object[] evaluatedParameters)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(Object obj)Annotation[]getAnnotations()Obtain the annotations on the method to which the associated expression resolves.ObjectgetBase()Obtain the base object on which the method will be invoked.Object[]getEvaluatedParameters()Obtain the evaluated parameter values that will be passed to the method to which the associated expression resolves.MethodInfogetMethodInfo()inthashCode()
-
-
-
Constructor Detail
-
MethodReference
public MethodReference(Object base, MethodInfo methodInfo, Annotation[] annotations, Object[] evaluatedParameters)
-
-
Method Detail
-
getBase
public Object getBase()
Obtain the base object on which the method will be invoked.- Returns:
- The base object on which the method will be invoked or
nullfor literal method expressions.
-
getMethodInfo
public MethodInfo getMethodInfo()
- Returns:
- The
MethodInfofor theMethodExpressionfor which thisMethodReferencehas been generated.
-
getAnnotations
public Annotation[] getAnnotations()
Obtain the annotations on the method to which the associated expression resolves.- Returns:
- The annotations on the method to which the associated expression resolves. If the are no annotations, then an empty array is returned.
-
getEvaluatedParameters
public Object[] getEvaluatedParameters()
Obtain the evaluated parameter values that will be passed to the method to which the associated expression resolves.- Returns:
- The evaluated parameters.
-
-