public Object invokeGetterMethodOnTarget ( String javaPropertyName , Object target ) throws NoSuchMethodException , SecurityException , IllegalArgumentException , IllegalAccessException , InvocationTargetException { String [ ] methodNamesArray = findMethodNames ( "get" + javaPropertyName ) ; if ( methodNamesArray . length <= 0 ) { // Try 'is' getter ... methodNamesArray = findMethodNames ( "is" + javaPropertyName ) ; } if ( methodNamesArray . length <= 0 ) { // Try 'are' getter ... methodNamesArray = findMethodNames ( "are" + javaPropertyName ) ; } return invokeBestMethodOnTarget ( methodNamesArray , target ) ; }
Find and execute the getter method on the target class for the supplied property name . If no such method is found a NoSuchMethodException is thrown .