Community
Participate
Working Groups
The generated getter and setter-functions of Java beans are not indented in a consistent way. The getters are indented with one tab, whereas the setters have two tabs as a prefix for every generated line of code.
Move to jdt.core The content passed to IType.createMethod is correctly indented for the inner class. createMethod seems to add a TAB.
The problem is the insertion position. The source code for the getters/setters is inserted after the tab. This results with an extra tab in from of the first line of the added method and the tab is missing in from of the closing brace of the type. It seems that the DOMField are updating their source range positions in the normalizeEndPosition method. I don't see any reason for that. The added method should contain the extra line breaks. Need to investigate more deeply this update.
Fixed and released in HEAD.