When dealing with technical debt, it is important to handle it as soon as possible. The best way to handle it, of course, it to get rid of it as soon as it appears. This may not be always possible, but when it is, then it should be done. That’s why at Tocea we developed a feature for our Eclipse’s plugin that gives you the opportunity to immediately correct a code defect.
The feature works with the quick-fix marker in Eclipse, that appears on the left of your code. Let’s say you are developing in Eclipse, with Scertify’s plugin and automatic code audit activated. This means that, when you perform a build action, Scertify audits your code and reports you every code violation instantly. So, you are developing, you build you application and you see some violations that pops up on your code.
You can click on the violation on the left side of your code. If a quick-fix refactoring is available, you’ll see three messages :
– Fix all violations with <<Refactoring rule’s name>> on file <<file’s name>> ;
– Fix all violations with <<Refactoring rule’s name>> on project ;
– Fix this this violations with <<Refactoring rule’s name>>.
Well, I think the messages are pretty much self-explanatory. You can choose to correct only the current violation and keep on writing your code. You’ll take care of the other violations later on. Or you may want to get rid of all violations of this kind on the file or the project. Let’s take a look on the Scertify Code perspective, we see there are 7 violations of this kind in the file.
So, let’s click on the quick fix and chose “Fix all violations with <<Refactoring rule’s name>> on file <<file’s name>>”.
Scertify performs the correction and there you go, you’ve just got rid of those violations in few clicks.
So, we’ve seen how to get rid of code violations on the fly, directly in your IDE. The trial edition of Scertify Professional Edition is available, so just click on the link and try it So far there are not a lot of quick fixes available, but more will be available soon. So stay tuned!
About Scertify™ Professional