This week's book giveaway is in the OCAJP 8 forum. We're giving away four copies of OCA Java SE 8 Programmer I Study Guide and have Edward Finegan & Robert Liguori on-line! See this thread for details.
Google for "java static source analysis" and you'll find many. Robert Martin developed a set of stability vs abstractness metrics for packages that are implemented in several tools, both free and commercial. There are others that check for style - naming, indenting, commenting, etc - and common bugs.
A good question is never answered. It is not a bolt to be tightened into place but a seed to be planted and to bear more seed toward the hope of greening the landscape of the idea. John Ciardi