Requested Features

If you would really want a feature and its not on the list below, could you please enter it in the SourceForge database? Here is how:

Go to the JRefactory Project and click on the list of bugs or features. Then press the button to submit a new request.


Also, if you really want a feature that is listed here, send me e-mail which feature it is. The more people who want a feature, the sooner I'll get it done. (As it is, I'll never finish this list, so I prioritize the feature based on the number of requests for it.). Better yet, offer to help implement it!

Pretty Printer

  1. Removed duplicate import statements
  2. Remove import *
  3. A "remove imports not used" function (automatic or prompt at users choice?)
  4. Long loop for bug with super() and no ;
  5. Improve error reporting for the Parser and Pretty Printer.
  6. Removes CVS comments from the end of the file
  7. Blocks inside a method
  8. // single line comments move after the {
  9. IMPLEMENTED: When passing values to a function which spans more than one line, the parameters should line up with the (
  10. If only a @return tag, don't include the double spaceafter the name
  11. Space in statements but not expressions and space after !
  12. Wrap long lines of code. They should be wrapped on parameter separator (","), then on open bracket ("("), then on expressions but not inside brackets.
  13. Parse Error dialog - only a single one with error in a scrollable area box
  14. File header without the stars to the left
  15. Eliminate javadoc comments if it is already documented in the interface
  16. Combine javadoc comments from the interface with implementation details from the class method.
  17. Add a header only if no header comments are present
  18. Growing javadoc comments
  19. A single line // comment should be moved to the line before the code
  20. Indent variable declarations with the previous block
  21. Default comment for getAt and setAt
  22. If a method overloads a method from a parent class or abstract class or implements a method in an interface insert a javadoc comment that says that the description is in the appropriate interface/abstract method/parent class with a @see tag.
  23. Only use the variable spacing for fields (not for variables in a method)
  24. Make array declarations line up with the rest of the declarations
  25. Array {} line up with the declaration but the contents of the array are indented
  26. IMPLEMENTED: Sort implemented classes
  27. IMPLEMENTED: Sort thrown exceptions
  28. Newline before extends
  29. Newline before implements
  30. Option to add blank line after "package"
  31. Option to add blank line after "import"
  32. IMPLEMENTED: Sort order for imports. Example: put "java" on top, then javax, then other packages. This can be done in even more complicated, but logical way if you sort packages by level matching.
  33. Option to add blank line after every "import" group (java, javax, com...). Problem: some imports should be grouped by second package level, like "com" because they import very different things. Idea: if group contains more than "n" imports, split it on next level recursively.
  34. Import sort looks bad if you already have blank lines between imports because it keeps blank line after import example:
  35. Option to add space before block statements like for, while, try, switch..., but only if they are not the first statement of containing block. Javadoc template for indexed properties (getSomething(int it), setSomething(int i))
  36. IMPLEMENTED: Sort order: add option to sort by final / non-final.
  37. Option to add blank line(s) between method/class declaration and body.
  38. Templates for getters / setters / parameters: if property name contains uppercase letters, {3} should be split into lowercase words. Example: setHostName return "host name". In Javadoc, you'll get "Sets host name" rather than "Sets hostName". But if there are more than one uppercase letter, split and leave uppercase: setHostURL becomes "host URL".
  39. IMPLEMENTED: Comments for add / remove listener methods are strange (feature?!). Example:
  40. Add a removeSomething template.


  1. Rename method
  2. Rename inner class
  3. Rename local variable
  4. Accurately reflect whether a method can be moved
  5. Move method into field
  6. Deleting comment before extract method
  7. Automatically manage length of undo stack
  8. NEXT Browser - instead of class diagram view
  9. Rename package
  10. Move class to different package
  11. Move inner classes into their own file
  12. Allow user to set public/package for parent class
  13. Push up a constructor
  14. Include the javadoc from the original file when you do an extract
  15. Create stub operation. User enters a method with arguments, highlights the method, and then selects create stub. System generates a method with the correct signature based on the inputs and a reasonable return (null or 0 or false).
  16. ConvertLocalVariableToInstanceVariable refactoring
  17. Change the parameters of the extract method
  18. Better at getting the return type when a return statement is included
  19. Encapsulate field (replace a public field with a private one, add getters and setters and replace all usage of the field with the appropriate accessor.
  20. Make field static / not static.
  21. Grey out / don't show refactorings that are not possible in the current context.

UML Diagrams

  1. Add a tooltip for each class (especially when in 10% zoom mode)
  2. Put a wait cursor over the structure pane when loading the diagrams
  3. Scroll pane makes larger jumps for the key and class list panels
  4. Develop a layout engine
  5. IMPLEMENTED: Moving a class changes the view back to 100%
  6. View inner classes in a diagram
  7. Center Loading dialog box for the metadata
  8. Hide methods/fields/classes to simplify the diagram
  9. Edit classes in the UML diagrams (change class/method/field/arguments names + add/remove of the same + updates of usage)
  10. Add class to a package (without relationship to other classes)
  11. Sizing of classes in the UML diagram and more steps to the zoom function. Also, there should be a tick showing what zoom level is currently chosen
  12. The dialog box that pops up when "New UML diagram" is chosen has a very narrow window, unsuitable for long pacakage names. Resizing the dialog box does not help since the scrollpane does not "follow".
  13. JDK summary loader not sized for linux
  14. When mouse is held at background, it would be nice to move diagram with mouse.
  15. Add notes to the UML diagram, these are @todo, @fixme, etc. as appropriate in the Java source file.
  16. Inheritance centric view of classes, all super-classes and interfaces are shown in one diagram even if they are in different packages.
  17. Scale diagram so that all classes are just visible.
  18. Scale diagram so that all classes are printed on one (or N) page(s).
  19. Better use of colours and icons.
  20. Generate more conformant UML, e.g. associations created from array variables.
  21. Show implementation of certain interfaces as Roles (e.g. Serializable, Cloneable) as they are markers not real interfaces.
  22. IMPLEMENTED: Make package selector a tree view and  make showing of JDK packages optional.


  1. Integrate into netbeans
  2. Moving/Adding/Renaming classes should update JBuilder
  3. IMPLEMENTED: JRefactory plugs into JEdit (like JavaStyle)
  4. Plugin for VA4J I need to learn answers to the following questions before JRefactory can integrate with VA4J. Some answers are in Chapter 27.
  5. Access JRefactory from the structure pane of a .java file in JBuilder
  6. Add a new diagram to the project pane of JBuilder
  7. Integrate with Emacs JDE
  8. It would be nice if the default for the "New UML diagram" was the package that one are currently viewing. In JBuilder, I often want the UML diagram for the class that I am currently viewing.
  9. When a UML diagram is saved, it's (default) location is in its place in the package hierarchy. Fine. But why is it not shown in its place in the package hierarchy in the JBuilder project pane? Seems that all UML diagrams are shown at top level.
  10. IMPLEMENTED: Menu item to edit pretty.settings
  11. IMPLEMENTED: Integrate error reporting with IDE (e.g. JEdit's ErrorList plugin).


  1. Better documentation of what the pretty printer does:

    The pretty printer does these transformations on the source file:

    Just a brief overview of what changes the pretty printer does to the source possibly intermixed with some examples.

  2. Color blind colors in about box
  3. Do a check for style (catching and ignoring exceptions, correct case for fields and methods and classes, etc.
  4. Add embedded JSQL to the parser
  5. Online help
  6. Add the ability for a user to add a comment to the log file to serve as a vote for future refactorings
  7. Add "usage search". There obviously is one implicitly since the "Rename class" function updates all usages, but it would be nice to simply have the results available in a list with a "Show source" option.

    Then it would be possible to have the questions "is this class used at all?" and "where is this class used?" answered easily.

  8. IMPLEMENTED: A "find private fields/methods never used" function. Items found could actually be removed (after prompting the user ?) Likewise, a "Find protected/public/default fields/methods would be useful, searching all available code. Here the user must evaluate wether the items found can be deleted, since they may be used by others. But it would be helpful when searching for obsolete code in larger systems.
  9. Break the JPG file into pages
  10. Export UML diagram to another UML tool's format
  11. Indent standards from Sun

Last Modified: 2 November 2003