I've just added a new post on my blog, http://blog.xlv-labs.com/, detailing the steps needed to run the PMD static analyzer on Android projects.
There are a few rules in the PMD distribution specific for the Android platform (calling super in onCreate, onResume, ..., protecting calls to Log.d and Log.v). More rules will be added in the future, for instance the hard coding of "/sdcard" mentioned in my post. The existing rules were added in PMD when I started developing for Android so they may need to be refined a little bit. In future posts, I will address some of the rules mentioned in the guideline documents from the official Android site, assuming the type of check can be addressed by PMD rules. Once the setup is done in Eclipse and/or ant's build.xml, it is pretty easy to make sure that violations are not creeping up as the complexity of the project increases and keep the code quality high. Finally, using the rules mentioned above flags a few problems in the Android source code itself so it may be a good idea to setup PMD checks on that code too... Best Regards, Xavier Le Vourch -- XLV Labs Publisher of "Who Called?", Caller Id application for Android phones: http://www.xlv-labs.com/whocalled --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/android-developers?hl=en -~----------~----~----~----~------~----~------~--~---

