checkstyle rules that covers Effective Java recommendations
Does anyone know if there is a compilation of check style rules that covers most of the recommendations made by Joshua Bloch in his Effective Java book? I know I can add custom rules in the checkstyle plugin but I was wondering if anyone has already do开发者_JAVA技巧ne so and if willing to share them. :)
I am the founder of the Checkstyle project. As far as I know, no such Checkstyle rules file exists. I am not surprised as Checkstyle checks can only check source code level things, such as Javadoc comments, whitespace, etc.
Unlike FindBugs, Checkstyle does not compile the source code, and hence does not have access to type information which would be required to implement implement some of the recommendations made by Joshua Bloch in his Effective Java book.
I agree with Oliver, that Checkstyle have limitation and not all from "Effective Java" could be covered by checkstyle. Take a look at our extension for standard checkstyle project - we take bunch of ideas from this book and we have plans to implement more.
Url: http://sevntu-checkstyle.github.com/sevntu.checkstyle/
Feel free to cooperate.
精彩评论