Is there any static code analysis tools for Android that would pick up simple things like NullPointerExceptions from trying to access an object that might be null (without checking for it first)...
Tools like resharper on C# projects do this quite well, so I'm presuming there is similar tools for Android's Java...
Since ADT 16 there is build-int Android Lint tool for static code analysis. http://tools.android.com/tips/lint/
It's not really android specific, it's Java specific.
Several tools I know of:
More complete list of tools can be found on wikipedia .
AndroidStudio is a thin layer on top of IntelliJ IDEA which zloyrobot points out has lots of inspections. The problem is that there are so many inspections that it is difficult to narrow down your queries to pick up only the really good stuff. I developed a profile for that purpose and describe how to use it here: http://superliminal.com/computing/idea_static_analysis.html
Try IntelliJ IDEA from Jetbrains (the creator of resharper). It has a lot of java code inspections like resharper and support developing Android applications .
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.