Project: JDT
Bug 32431 extract method: extracted method should be private, not public [refactoring]
Reported: 2003-02-20 19:19:16 | Status: resolved fixed

Currently, the default protection level of an extracted method is 'public'. This is a 'worst practice' of object-oriented programming, since it would violate encapsulation by introducing a method into the class' public API. The default selection should be 'private'. Or at least be settable.

Files changed in fix:
org.eclipse.jdt.ui/core refactoring/org/eclipse/jdt/internal/corext/refactoring/code/ExtractMethodRefactoring.java