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.
The method returns any component, but in case there is no component in the Ref instance it throws runtime exception (NoSuchElementException). That's ugly and wrong API, should be replaced by similar method, but which in that case simply returns null.
P9? This will just add one new method to the API. But ok, maybe boolean hasAnyComponents ()?
Set target milestone to TBD
What about: anyComponent ()?
Not hasAnyComponent, needed is just the method for retrieving the "any" component without use of try-catch block. I would prefer name starting with get, e.g. getOneComponent? getArbitraryComponent? getSomeComponent?. Well the good name seems to be already used.
I have changed version from 4.0 dev to S1S 4.2 (Nevada).
After talk with english native (Tim), I'm going to put there the name getArbitraryComponent().
Fixed in [trunk] (also the usages of getAnyComponent method) org/openide/windows/CloneableTopComponent.java 1.23 org/openide/windows/CloneableOpenSupport.java 1.17 org/openide/text/CloneableEditorSupport.java 1.80 openide/openide-spec-vers.properties 1.106 openide/api/doc/changes/apichanges.xml 1.143
verified in source code