wood burning stoves
The moose likes Agile and Other Processes and the fly likes [book] Tools not mentioned Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of REST with Spring (video course) this week in the Spring forum!
JavaRanch » Java Forums » Engineering » Agile and Other Processes
Bookmark "[book] Tools not mentioned" Watch "[book] Tools not mentioned" New topic

[book] Tools not mentioned

Junilu Lacar

Joined: Feb 26, 2001
Posts: 6497

Eric/Brian: Since I didn't see any mention of them in the online TOC, what tools do you use/recommend, if any, to help you:
1. Refactor code
2. Enforce coding standards

Junilu - [How to Ask Questions] [How to Answer Questions]
Lasse Koskela

Joined: Jan 23, 2002
Posts: 11962
My name is not Eric/Brian but as a selfish person I'll state my preferred tools for the job.
I use Eclipse, which by default comes with refactoring support. For my use it's more than enough. However, a plugin called PMD is quite helpful in pointing out places where refactoring would be appropriate, based on some metrics.
Coding standards:
I've used Checkstyle (Eclipse plugin, Ant task) to make sure that the code I'm producing complies with the coding standard in use.
Related to forcing coding standards, I'd be interested to hear about projects where e.g. Checkstyle was integrated into a source control system (in a way that checked in code would be run through a "formatter" or a "validator"). I've been planning to do something like this with Ant and Checkstyle for a while but haven't had the time/enthusiasm to do it.

Author of Test Driven (2007) and Effective Unit Testing (2013) [Blog] [HowToAskQuestionsOnJavaRanch]
Matthew X. Brown
Ranch Hand

Joined: Nov 08, 2000
Posts: 165
I have a tool called "RefactorIt"- and believe me-
don't use it. Maybe its evolved since I "won" fully licenced version about a year ago, but its not a very good tool. I use Eclipse for refactoring now.
Ilja Preuss

Joined: Jul 11, 2001
Posts: 14112
I also use Eclipse for refactoring. IDEA is even more powerfull here as far as I know, but I don't use it for other reasons.
We don't use a tool to enforce coding standards, though we use a code formatter to help us conform to it. I don't think we need more - why do you think you do?

The soul is dyed the color of its thoughts. Think only on those things that are in line with your principles and can bear the light of day. The content of your character is your choice. Day by day, what you do is who you become. Your integrity is your destiny - it is the light that guides your way. - Heraclitus
Lasse Koskela

Joined: Jan 23, 2002
Posts: 11962
Originally posted by Ilja Preuss:
We don't use a tool to enforce coding standards, though we use a code formatter to help us conform to it. I don't think we need more - why do you think you do?

Because only 10% percent of the multi-vendor organization are complying with the standards put down on paper... Some of the vendors are using a different build system for their part of the system so that's basically out of our control but for the rest of us, located in a single space, having an enforced check/fix step for coding standards compliance would probably make a difference.
Rarely a day goes by when I don't hear a colleague cry in pain while looking at something as ingenious as

And that's not a fake! We found it today from another vendor's code. If there are these kind of interesting statements, you bet they are also breaking the coding standards as well...
I consider myself one of the more pedantic personalities when it comes to the form of code but I still don't trust myself with certain things -- I make mistakes and I know it.
Brian Coyner

Joined: Mar 22, 2003
Posts: 7
1. Refactor code

We both use IDEA. It's not free, though. Eclipse is a free Java IDE that has refactoring support. We like IDEA because it's very intuitive and easy to use. I tried using Eclipse about a year ago and deleted it after about thirty minutes because I could not get a simple project created. Of course, Eclipse may be better now.
Intellij IDEA

2. Enforce coding standards

Checkstyle is a very popular code format enforcer.

Author of <a href="http://www.amazon.com/exec/obidos/ASIN/0596003870/ref=jranch-20" target="_blank" rel="nofollow">Java Extreme Programming Cookbook</a>
I agree. Here's the link: http://aspose.com/file-tools
subject: [book] Tools not mentioned
It's not a secret anymore!