- // Getter methods that return Boolean and start with "is" instead of "get" aren't recognized as
- // properties and thus aren't returned from getPropertyDescriptors. A getter starting with
- // "is" is only supported if it returns primitive boolean. So we'll check for these via
- // getMethodDescriptors.
- for (final MethodDescriptor desc: beanInfo.getMethodDescriptors()) {
- final String methodName = desc.getName();
- if (Boolean.class.equals(desc.getMethod().getReturnType()) && methodName.startsWith("is")) {
- final String propertyName = WordUtils.uncapitalize(methodName.substring(2));
- processDataStoreProperty(propertyName, Boolean.class, desc.getMethod());
- }
+ private static String getPropertyName(final Method method) {
+ final String methodName = method.getName();
+ if (Boolean.class.equals(method.getReturnType()) && methodName.startsWith("is")) {
+ return WordUtils.uncapitalize(methodName.substring(2));
+ } else if (methodName.startsWith("get")) {
+ return WordUtils.uncapitalize(methodName.substring(3));