-
Notifications
You must be signed in to change notification settings - Fork 38.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Compensate for changes in JDK 7 Introspector
Prior to JDK 7, java.beans.Introspector registered indexed write methods irrespective of return type, for example either of the following methods were legal void setFoo(int i, Foo foo) Object setFoo(int i, Foo foo) This was considered a bug and disallowed starting with JDK 7, such that only the former signature is a candidate. Supporting non-void returning setter methods is exactly what ExtendedBeanInfo was designed to do, and prior to this commit, the implementation of ExtendedBeanInfo assumed this (somewhat surprising) behavior from the underlying Introspector, and because it worked out of the box, took no extra steps to recognize and register these methods. For this reason, non-void returning indexed write methods were not registered under JDK 7+, causing test failures in ExtendedBeanInfoTests. Now the implementation is careful to detect these methods without any assumption about Introspector behavior, such that they are registered in exactly the same fashion across JDK versions. Issue: SPR-9014
- Loading branch information
Showing
2 changed files
with
29 additions
and
20 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters