Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Eclipse automatic todo task addition

Tags:

eclipse

todo

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 ?

like image 764
Emil Avatar asked Dec 27 '22 13:12

Emil


1 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

like image 86
Kai Avatar answered Jan 06 '23 06:01

Kai