有没有办法让Eclipse内置的Java代码格式化程序忽略注释?每次运行时,它会将这个变成:
/*
* PSEUDOCODE
* Read in user's string/paragraph
*
* Three cases are possible
* Case 1: foobar
* do case 1 things
* Case 2: fred hacker
* do case 2 things
* Case 3: cowboyneal
* do case 3 things
*
* In all cases, do some other thing
*/
转换为这个:
/*
* PSEUDOCODE Read in user's string/paragraph
*
* Three cases are possible Case 1: foobar do case 1 things Case 2: fred
* hacker do case 2 things Case 3: cowboyneal do case 3 things
*
* In all cases, do some other thing
*/
我已经尝试过在Windows > Preferences > Java > Code Style > Formatter中进行设置,但找不到保持注释格式的选项。我正在使用Eclipse 3.4.0。