The plugin rearranges class and class member declarations according to a user-specified order.
New in version 0.9:
- Comments may be inserted conditionally based on whether items matched any or all of the preceding and/or subsequent rules.
A comment may be emitted:
For example, if your Class Member Order is defined as follows:
then the "PRIVATE FIELDS" comments will only appear if one or more private fields were found; likewise, the "STATIC FIELDS" comments will only appear if one or more static fields were found. The "FIELDS BEGIN/END HERE" comments will only appear if at least one private or static field was found. In the case where there were private fields but no static fields, output might be:
Version 0.9 also fixes deletion of comments inserted by a previous run of the Rearranger when those comments were adjacent.
The plugin is available via Plugin Manager or at http://www.intellij.org/twiki/bin/view/Main/RearrangerPlugin.