public class MethodProperty extends GenericProperty
 A MethodProperty is a Property which is accessed
 through accessor methods (setX, getX). It is possible to have a
 MethodProperty which has only setter, only getter, or both. It
 is not possible to have a MethodProperty which has neither
 setter nor getter.
 
| Constructor and Description | 
|---|
| MethodProperty(PropertyDescriptor property) | 
| Modifier and Type | Method and Description | 
|---|---|
| Object | get(Object object) | 
| <A extends Annotation>  | getAnnotation(Class<A> annotationType)Returns property's annotation for the given type or  nullif it's not present. | 
| List<Annotation> | getAnnotations()Returns the annotations that are present on read and write methods of this property or empty  Listif
 there're no annotations. | 
| boolean | isReadable() | 
| boolean | isWritable() | 
| void | set(Object object,
   Object value) | 
getActualTypeArgumentspublic MethodProperty(PropertyDescriptor property)
public List<Annotation> getAnnotations()
List if
 there're no annotations.getAnnotations in class PropertyList if there're no annotationspublic <A extends Annotation> A getAnnotation(Class<A> annotationType)
null if it's not present. If the annotation is present
 on both read and write methods, the annotation on read method takes precedence.getAnnotation in class PropertyA - class of the annotationannotationType - the type of the annotation to be returnednull if it's not presentpublic boolean isWritable()
isWritable in class Propertypublic boolean isReadable()
isReadable in class PropertyCopyright © 2008–2021. All rights reserved.