> So have one refactoring that allows moving classes from anywhere to > anywhere. Anywhere is defined as anonymous, inner, static inner (nested) and > top level.
Or even better, to have only one refactoring at all, which is able to refactor anything into anything in any possible way. You will just need to assign proper values for a few thousands of checkboxes, edit fields and other controls in the configuration dialog and the refactorting will be done. The negative is that it will obviously contain thousands of bugs, because some cases among millions ones were not tested. :-))) Developing refactorings for IDEA (and this applies to other IDEA features too), we try to find out some set of simple, orthogonal refactorings that allow performing more complex ones in a few steps. Each simple refactoring has its own specifics to be solved during refactoring. For example, when converting an anonymous class into an inner class, the main issue is proper choosing of parameters passed into the constructor. When you performed this step, make sure that the refactoring did not break your code (some refactoring gurus, for example, Martin Fowler, recommend to compile and test after each step!). Then you can proceed with further refactoring. When converting an inner class into a top-level class, there can be difficulties with using private members of the original class. They can be solved in a number of ways (changing visibility, using access methods instead of direct access, passing some additional data as constructor parameters). If you would perform both refactorings in one step, you had to encounter all difficulties and problems at the same time. This increases the risk of mistakes. Best regards, Valentin Kipiatkov ----------------------------------------------------------- IntelliJ Software, http://www.intellij.com/ "Develop with pleasure" ----------------------------------------------------------- ----- Original Message ----- From: "Mark Swinkels" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Friday, November 09, 2001 12:02 AM Subject: RE: [Eap-list] Refactoring anonymous classes > Maybe all the different types of refactorings of classes to classes in other > locations should be considered 'Moving' a class. There is an outstanding > request for control over where the Move Inner to Upper Level refactoring > should put the resulting class. In my case I would like control over the > name of the class when I do a Move between packages since our coding > standard requires that public classes have package specific prefixes > (although IDEA's great navigation tools makes the original rational somewhat > obsolete). > > So have one refactoring that allows moving classes from anywhere to > anywhere. Anywhere is defined as anonymous, inner, static inner (nested) and > top level. Obviously there are considerable constraints when changing a > class to be anonymous. > > -- Mark > > -----Original Message----- > From: Kirk Woll [mailto:[EMAIL PROTECTED]] > Sent: Thursday, November 08, 2001 10:48a > To: IntelliJ Idea Early Access List > Subject: [Eap-list] Refactoring anonymous classes > > > For me, I generally want to refactor anonymous classes directly to > top-level classes. Currently I must first refactor the anonymous class > to an inner class, and then refactor the inner class to a top-level > class. Can this be made one step? > > Kirk > > > _______________________________________________ > Eap-list mailing list > [EMAIL PROTECTED] > http://www.intellij.com/mailman/listinfo/eap-list > > _______________________________________________ > Eap-list mailing list > [EMAIL PROTECTED] > http://www.intellij.com/mailman/listinfo/eap-list _______________________________________________ Eap-list mailing list [EMAIL PROTECTED] http://www.intellij.com/mailman/listinfo/eap-list
