org.omnaest.utils.beans
Class BeanUtil.PropertyCriterionHasGetterSetter

java.lang.Object
  extended by org.omnaest.utils.beans.BeanUtil.PropertyCriterion
      extended by org.omnaest.utils.beans.BeanUtil.PropertyCriterionHasGetterSetter
Enclosing class:
BeanUtil

public static class BeanUtil.PropertyCriterionHasGetterSetter
extends BeanUtil.PropertyCriterion

Test a method if it is a getter or / and a setter of a property. Getter and setter methods have to be public.

Author:
Omnaest

Constructor Summary
BeanUtil.PropertyCriterionHasGetterSetter()
           
 
Method Summary
 boolean inspectMethod(Method method)
          This method is called for every declared method.
 boolean isTestForGetter()
           
 boolean isTestForSetter()
           
 void prepareInspection(Class<?> clazz)
          This method will be called once before the inspection process runs.
 BeanUtil.PropertyCriterionHasGetterSetter setTestForGetter(boolean testForGetter)
           
 BeanUtil.PropertyCriterionHasGetterSetter setTestForSetter(boolean testForSetter)
           
 
Methods inherited from class org.omnaest.utils.beans.BeanUtil.PropertyCriterion
and, annotationname, hasGetter, hasGetterAndSetter, hasGetterOrSetter, hasSetter, methodname, or
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BeanUtil.PropertyCriterionHasGetterSetter

public BeanUtil.PropertyCriterionHasGetterSetter()
Method Detail

inspectMethod

public boolean inspectMethod(Method method)
Description copied from class: BeanUtil.PropertyCriterion
This method is called for every declared method. The method should return true if the method matches the criteria.

Specified by:
inspectMethod in class BeanUtil.PropertyCriterion
Returns:

prepareInspection

public void prepareInspection(Class<?> clazz)
Description copied from class: BeanUtil.PropertyCriterion
This method will be called once before the inspection process runs. This can be used to collect needed information.

Specified by:
prepareInspection in class BeanUtil.PropertyCriterion

isTestForGetter

public boolean isTestForGetter()

setTestForGetter

public BeanUtil.PropertyCriterionHasGetterSetter setTestForGetter(boolean testForGetter)

isTestForSetter

public boolean isTestForSetter()

setTestForSetter

public BeanUtil.PropertyCriterionHasGetterSetter setTestForSetter(boolean testForSetter)


Copyright © 2011. All Rights Reserved.