问题描述
当在eclipse开发的android.util.Config.DEBUG恒始终为假,甚至当我调试项目。
When developing in eclipse, the android.util.Config.DEBUG constant is always false even when I debug the project.
此常数的javadoc说:如果这是一个调试版本,本场将是真实的。我在做什么错了?
The javadoc for this constant says that "If this is a debug build, this field will be true." What am I doing wrong?
推荐答案
文件中提到建是不是你的应用程序构建,但Android系统的版本。
The "build" mentioned in the document is not your application build, but the Android system build.
Config.DEBUG值的仅取决于你的设备的系统(ROM)上,无关的应用程序。与生产版本ROM的设备,Config.DEBUG常是假的,不管你如何在清单上的设备和调试的标志设置USB调试。
The value of Config.DEBUG ONLY depends on the system (ROM) of your device, nothing to do with your application. On a device with production build ROM, Config.DEBUG is alway false no matter how you set USB debugging on device and debuggable flag in manifest.
如果该文件是这样写的:如果Android系统是一个调试版本,本场将是真实的。,那么这将是减少混乱。
If the document is written like: "If the Android system is a debug build, this field will be true.", then it will be less confusing.
这篇关于android.util.Config.DEBUG在Eclipse中开发,即使总是虚假和调试。为什么?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!