游戏邦在:
杂志专栏:
gamerboom.com订阅到鲜果订阅到抓虾google reader订阅到有道订阅到QQ邮箱订阅到帮看

developer盘点Android开发者必备的十大开发工具

发布时间:2011-04-27 12:11:42 Tags:,,,

Android SDK提供了一系列可帮助开发者设计、创建、测试和发布Android应用程序的强大工具,以下是游戏邦编译developer推荐的10款最常用的开发工具。

1.Eclipse w/ADT

虽然Eclipse并非唯一可用于开发Android应用的Java开发环境,但它是目前最欢迎的工具,有很大程度上是因为它的成本很低(免费),但最主要的原因还是它与其他Android工具的强大组合功能。最典型的表现就是它与Android Development Tools(ADT)插件的组合(游戏邦注:开发者可以通过Android网站下载ADT)。

Eclipse

Eclipse

2.Android SDK and AVD Manager

这项SDK可提供多种重要的功能,它能管理不同版本的Android SDK,以及第三方附件、工具、设备驱动程序和文件。第二大功能就是管理用来安装模拟器实体的Android Virtual Device配置(AVD)。

The SDK and AVD Manager

The SDK and AVD Manager

3.Android Debug Bridge(adb)

该工具可将其他工具接入模拟器和设备,它除了可以让其他工具(游戏邦注:尤其是Eclipse ADT插件)功能生效以外,还可以使命令行上传或下载文件,安装或卸载程序包,通过进入设备或模拟器的shell环境访问许多其他功能。

4.Dalvik Debug Monitor Server(DDMS)

无论是通过独立应用程序还是Eclipse perspective访问DDMS,它都能提供检查、调试、与模拟器及设备实体交互的便利功能。开发者可使用DDMS检查运行程序和线程,探索文件系统,搜集堆栈和其他内存信息,附上调试器,甚至是抓取视频截图。通过模拟器,开发者还可以模拟电话接听和发送SMS等状态。

Dalvik Debug Monitor Server

Dalvik Debug Monitor Server

5.Android模拟器和实际移动设备

如果开发者创建完成了一款应用程序,就必须针对自己锁定的设备进行测试。你可以将模拟器与AVD结合在一起模拟目标移动设备的运行环境,但更全面地进行测试,你还是需要一个真正的移动设备,因为模拟器虽然功能强大,但它毕竟不是实际使用的手机,用户也不可能使用模拟器运行应用程序,所以实际移动设备也是测试环节必不可少的工具。

The Android Emulator

The Android Emulator

6.LogCat

LogCat是Android日志系统的名称,你可以通过Eclipse、adb读取LogCat数据,它可以提供系统中相关事件的诊断信息。开发者可以由此将应用程序的调试和诊断信息发送到LogCat。

7.The Hierarchy Viewer

开发者可通过独立应用程序或者Eclipse perspective访问The Hierarchy Viewer,它的作用是在运行过程中查看程序的UI布局,提供了一个图表显示应用程序布局和视图层级的情况,开发者可依此判断程序UI布局的存在问题。

The Hierarchy Viewer

The Hierarchy Viewer

8. Draw 9-Patch

Draw 9-Patch可助开发者更方便地完成应用程序的图形设计,该工具支持开发者将传统的PNG图像文件转化成更具灵活性、更能有效运用于手机应用开发过程的可扩展图像文件。这项工具可以在快速显示效果的环境中简化NinePatch文件的创建过程。

Draw 9-Patch

Draw 9-Patch

9.The Monkey Test Tools

它包括Monkey试验程序和monkeyrunner工具,这两项工具可用于自动测试应用程序。前者可在强度测试过程中将其中发生事件随机发送到应用程序中,而后者可使用Python脚本通过截屏自动测试和检查相关结果,以此测试应用的稳定性。

10. ProGuard

它是典型的Android应用开发过程中必不可少的一个环节,为开发者提供了一个发布产品后保护知识产权的有效方法。ProGuard这种混淆器可用于模糊相关信息,并用无意义的字符序列来替换其中重要内容,使其难以进行逆向工程。通过ProGuard可得到更精简的文件,也就意味着网络传输更省时,装载速度更快,占用内存空间更小。

总结

Android SDK含有大量其他开发工具,其中有许多工具主要用于开发特殊项目,上文所列的常见工具均适用于每一种类型的Android应用开发项目。当然,这个领域的新型工具还会频频问世,所以开发者需要留意 AVD和SDK Manager的更新信息。最好的开发工具信息来源当然还是Android Developer网站,开发者可从中下载最新SDK、源文件、新手教程、技术分析文章,并通过Android博客获取最新情报,相信该网站的内容一定会让各位Android应用开发者受益匪浅。(本文为游戏邦/gamerboom.com编译,转载请注明来源:游戏邦)

10 Must-Have Android Tools for Developers

The Android SDK comes with a robust set of tools to help developers design, develop, test, and publish quality Android applications. In this article, we discuss 10 of the most common tools you should know about and learn to use.

Android Tool #1: Eclipse w/ADT

Although Eclipse is not the only Java development environment that can be used to develop Android applications, it is by far the most popular. This is partially due to its cost (free!) but mostly due the strong integration of the Android tools with Eclipse. This integration is achieved with the Android Development Tools (ADT) plug-in for Eclipse, which can be downloaded from the Android website.

Android Tool #2: The SDK and AVD Manager

This tool serves a number of important functions. It manages the different versions of the Android SDKs (build targets) that you can develop for, as well as third-party add-ons, tools, devices drivers, and documentation. Its second function is to manage the Android Virtual Device configurations (AVDs) you use to configure emulator instances.

Android Tool #3: Android Debug Bridge

The Android Debug Bridge (adb) connects other tools with the emulator and devices. Besides being critical for the other tools (most especially the Eclipse ADT plug-in) to function, you can use it yourself from the command line to upload and download files, install and uninstall packages, and access many other features via the shell on the device or emulator.

Android Tool #4: Dalvik Debug Monitor Server

The Dalvik Debug Monitor Server (DDMS), whether it’s accessed through the standalone application or the Eclipse perspective with the same name, provides handy features for inspecting, debugging, and interacting with emulator and device instances. You can use DDMS to inspect running processes and threads, explore the file system, gather heap and other memory information, attach debuggers, and even take screenshots. For emulators, you can also simulate mock location data, send SMS messages, and initiate incoming phone calls.

Android Tool #5: The Android Emulator and Real Devices

Once you have begun to develop an app, it’s important to test it on the appropriate device targets. The emulator can be used in conjunction with AVDs to simulate device targets. That said, testing on real physical devices is essential for complete test coverage. The emulator, while powerful, cannot emulate the idiosyncrasies of individual devices. Therefore, a solid test plan must incorporate both emulators and real devices. After all, your users won’t be running your app on an emulator, will they?

Android Tool #6: LogCat

LogCat is the name of the Android logging system. LogCat data is accessible from within Eclipse, as well as through adb, and provides helpful diagnostic information about events on the system. As a developer, you can enable your applications to log debugging and diagnostic information to LogCat as well. Logging from within an application is about as easy as a printf() statement.

Android Tool #7: The Hierarchy Viewer

The Hierarchy Viewer, whether it’s access through the standalone application or the relatively new Eclipse perspective, is used to see how your layouts and screens resolve at runtime. It provides a graphical representation of the layout and view hierarchy of your application and can be used to diagnose layout problems.

Android Tool #8: Draw 9-Patch

When it comes to graphics design, the Draw 9-patch tool comes in handy. This tool allows you to convert traditional PNG graphic files into stretchable graphics that are more flexible and efficient for mobile development use. The tool simplifies the creation of NinePatch files in an environment that instantly displays the results.

Android Tool #9: The Monkey Test Tools

The Monkey Test Tools, including the Monkey exerciser tool and the monkeyrunner tool, are a pair of applications that can be used to automate application testing. The Monkey exerciser randomly sends events to your application for stress testing purposes. The monkeyrunner tool is a scripting library that can be used for automated testing and checking of the results via screenshots using

Python scripts.

Android Tool #10: ProGuard

ProGuard, which is now part of the typical Android build process, provides developers with a straightforward way to increase protection of their intellectual property after publication. The ProGuard tool can be configured to obfuscate the resulting binaries to make them difficult to reverse engineer. The ProGuard tool can also be used to optimize the size of the resulting binary,

reducing the overall package size and speeding delivery to your users.

Conclusion

The Android SDK ships with numerous other tools. Many of which are used for special development cases. However, the tools listed above will be used with just about every project, regardless of the type of app being developed. For more information on these and other tools available, check out the Android Tools section of the Android website. Also, new tools and improved tools are released on a fairly regular basis, so make sure you keep all of the packages updated with the AVD and SDK Manager.

Finally, above and beyond the Android tools we’ve discussed, your best resource is the Android Developer website. Complete with up-to-date SDK downloads, source documentation, tutorials, technical articles, and the Android blog with the latest news, this website provides critical knowledge and support for Android developers.(source: developer


上一篇:

下一篇: