This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
This code: Method getter; try { try { getter = inst.getClass().getMethod("getDisplayName", null); } catch (NoSuchMethodException me) { getter = inst.getClass().getMethod("getName", null); } } catch (Exception ex) { // do nothing return; } try { String name = (String) getter.invoke(inst, null); // ... is not quite right. It needs to check also that the declaring class of the method is public. Compare BeanNode.initialize and .registerName, and issue #1937.
Created attachment 8342 [details] Example stack trace from unit tests
BTW there is no core/settings IZ subcomponent, would probably be helpful...
I have changed version from 4.0 dev to S1S 4.2 (Nevada).
There is openide/settings subcomponent in IZ that has been shared also by the settings module so far.
Fixed in trunk. Added check if method getDisplayName or getName is accessible: /cvs/core/src/org/netbeans/core/projects/SerialDataConvertor.java,v <-- SerialDataConvertor.java new revision: 1.18; previous revision: 1.17 /cvs/core/settings/src/org/netbeans/modules/settings/SaveSupport.java,v <-- SaveSupport.java new revision: 1.8; previous revision: 1.7
closed