[英]Android: build android application to check app is running at emulator or real device
We need to develop android basic app which will detect the device is real or emulator and behave accordingly. 我们需要开发android基本应用,它将检测设备是真实的还是仿真器,并相应地运行。 But did not found sample code or process to detect this thing actually. 但实际上并未找到示例代码或过程来检测到此东西。 Please suggest me somebody to resolve this issue. 请建议我解决这个问题。 Thanks 谢谢
您可以检查Build.PRODUCT
"google_sdk".equals(Build.PRODUCT);
The IMEI on the emulator is "00000000000000". 仿真器上的IMEI为“ 00000000000000”。 Just check in your app if the IMEI equals the systems IMEI. 如果IMEI等于系统IMEI,只需签入您的应用即可。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.