Find TODO tags in Eclipse

2020-05-11 03:04发布

When I used Eclipse to add unimplemented methods to a Java class to fix an error, methods were auto-generated and include // TODO Auto-generated method stub

Is there an easy way to view all methods which contain this comment? Some sort of menu option?

5条回答
看我几分像从前
2楼-- · 2020-05-11 03:43

Tasks view, under Window -> Show View -> Tasks

查看更多
冷血范
3楼-- · 2020-05-11 03:45

Sometimes Window → Show View does not show the Tasks. Just go to Window → Show View -> Others and type Tasks in the dialog box.

查看更多
Emotional °昔
4楼-- · 2020-05-11 03:47
  1. Push Ctrl+H
  2. Got to File Search tab
  3. Enter "// TODO Auto-generated method stub" in Containing Text field
  4. Enter "*.java" in Filename patterns field
  5. Select proper scope
查看更多
萌系小妹纸
5楼-- · 2020-05-11 03:54

Is there an easy way to view all methods which contain this comment? Some sort of menu option?

Yes, choose one of the following:

1) Go to Window → Show View → Tasks(Not TaskList). The new view will show up where the "Console" and "Problems" tabs are by default.

2) As mentioned elsewhere, you can see them next to the scroll bar as little blue rectangles if you have the source file in question open.

3) If you just want the // TODO Auto-generated method stub messages (rather than all // TODO messages) you should use the search function (Ctrl-F for ones in this file Search-->java-->search string for the ability to specify this workspace, that file, this project, etc.)

查看更多
Explosion°爆炸
6楼-- · 2020-05-11 04:03

Go TO Window>Show View >Markers

than you will get java task .

java task have all TODOs of your project

查看更多
登录 后发表回答