我有一个带有注释的方法声明,该注释由 Eclipse Mars 格式化,如下所示:
@Override
void addLoadShiftingConstraints() throws NoSuchDataException {
//method body
}
我不想缩进方法声明:
@Override
void addLoadShiftingConstraints() throws NoSuchDataException {
//method body
}
目前我有以下方法声明的格式化程序设置:
右键单击 Project =>Properties=>Java Code Style=>Formatter =>Edit active profile => LineWrapping => Method Declaration => Declaration => Wrap in necessary
如果我选择不换行选项,不需要的缩进就会消失。但是,我想保留长声明的包装。
这是一个 Eclipse 错误还是我必须更改注释的附加设置以避免缩进?