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.
It is not clear from the Javadoc description of DataLoader.defaultActions() that it is not necessary to override this method if method DataLoader.actionsContext() is overridden and returns a non-null value. Documentation of DataLoader.defaultActions() does not specify any default value (value returned by the default implementation). The docs also states that it should return null if actionsContext() is used. This implies that if the programmer wants to use actionsContext(), they must override defaultActions() to return null. Suggested change: Either specify the default value of defaultActions (null) or add a statement that defaultActions() is not called if actionsContext() returns a non-null value.
Yarda I think you added this. Do you have any preference about what to document? BTW: original issue #64210
I do not understand what is the problem. Whether you override defaultActions or not, they are not going to be used if actionsContext is specified. I've put some text into the javadoc, but as I do not understand your request, I am closing as wont fix. If you have feeling there is need for improvement, please change the javadoc and attach patch here, I'll be glad to apply it. openide/loaders/src/org/openide/loaders/DataLoader.java,v <-- DataLoader.java new revision: 1.12
The only problem was that I refused to remove method defaultActions() returning always <null> as Petr Zajac and Jesse asked me to do. So I accept this bug's status as WONTFIX and I will keep my impl. of defaultActions() in PropertiesDataLoader.
Please fix the Javadoc to actually say what the default value is (or that the old method need not and should not be overridden), and fix the properties module.
I do not understand. Sorry. Why I would say that the old method need not be overriden or should not be overriden? That is implicit. The value is taken from NodeOp and can always different. So what I am supposed to document? Give me the java patch so I can evaluate it! I feel I will be capable to do that. Without it I am afraid I have to repeat that I do not understand.
x
Fine, I'll do it myself...
Checking in openide/loaders/src/org/openide/loaders/DataLoader.java; /cvs/openide/loaders/src/org/openide/loaders/DataLoader.java,v <-- DataLoader.java new revision: 1.13; previous revision: 1.12 done Checking in properties/src/org/netbeans/modules/properties/PropertiesDataLoader.java; /cvs/properties/src/org/netbeans/modules/properties/PropertiesDataLoader.java,v <-- PropertiesDataLoader.java new revision: 1.27; previous revision: 1.26 done