Details
-
Type:
Improvement
-
Status:
Open
-
Priority:
Major
-
Resolution: Unresolved
-
Affects Version/s: 1.3
-
Fix Version/s: None
-
Component/s: None
-
Labels:None
-
Testcase included:yes
-
Number of attachments :
Description
It looks like BasicBeanDescription throws an exception if multiple setters are found for a property:
Conflicting setter definitions for property "value": OverloadedBean#setValue(1 params) vs OverloadedBean#setValue(1 params)
I've been able to get around this limitation by subclassing BasicBeanDescription and overriding okNameForSetter to check not just for a reasonable name but also that there is a getter that has a return type the same as the setter's argument. Since okNameForSetter is called so frequently it would be much more efficient to be done only when a potential problem is detected (in BasicBeanDescription.findSetters).