Is there a way in eclipse to automatically add TODO task eg:- //TODO: TO BE TESTED
to the top of the function or class so that i can easily keep track of the changes yet to be tested ?
2 Answers
Do you want to add the TODO when you generate the methods/classes? Then you could use code templates for that. Like // TODO Auto-generated method stub
is added when you generate a method you could put any other comment on top of a method. Window
-> Preferences
-> Java
-> Code Style
-> Code Templates
Or do you want to add the TODO to all methods/classes which currently do exist? Thats a bit harder, you could write a plugin which does that for you: Eclipse JDT
If that TODO should always be created when you have modified a class or method you could also write an eclipse plugin which monitors the CompilationUnit
in the editor. See recordModifications()
here

- 38,985
- 14
- 88
- 103
You can edit the code templates and include the TODO comment there. Code templates are located on the preferences dialog
Window > Preferences > Java > Code Style > Code Templates
Unfortunately, this will only help for new methods and classes.

- 3,956
- 8
- 38
- 58

- 37,124
- 11
- 56
- 82