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.
https://svn.codehaus.org/mojo/trunk/mojo/nbm-maven-plugin/src/main/java/org/codehaus/mojo/nbm/ExamineManifest.java @14750 has public void setPublicPackages( boolean publicPackages ) { this.publicPackages = publicPackages; } which Find Usages confirms is used only within ExamineManifest itself. I asked to inline this method, since it is not intended to be called externally and would be easier to read if inlined, but got the error given in the subject line. The Inline refactoring should only issue this error if the method is actually called from another class (other than a nested class). Even then the error should probably be made into a warning: if the field is accessible to the current caller, it is the user's decision whether to let that caller access the field directly; even if not currently accessible, it could be made accessible if that is the intent.
changeset : 610c1756da93 author : Ralph Benjamin Ruijs <ralphbenjamin@netbeans.org> date : Thu Feb 23 17:10:49 CET 2012 summary : Issue #204694 - "Cannot inline public method which uses local accessors" when method used only in-class
Integrated into 'main-golden', will be available in build *201202250400* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) Changeset: http://hg.netbeans.org/main-golden/rev/610c1756da93 User: Ralph Benjamin Ruijs <ralphbenjamin@netbeans.org> Log: Issue #204694 - "Cannot inline public method which uses local accessors" when method used only in-class