什么是ANR对话框中的Andr​​oid? [英] What is ANR Dialog in android?

查看:103
本文介绍了什么是ANR对话框中的Andr​​oid?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想了解一下Android应用程序ANR对话框,何时会发生,以及如何删除。
请帮我。


解决方案

  

ANR - 应用程序没有响应。


出现这个对话框时,应用程序的主线程被阻塞的时间过长,例如,当你在这个线程睡觉,或执行长的连接。

避免它是通过移动沉重业务给其他线程完成。有关于如何落实,一个伟大的文章 - 无痛线程

I want to know about ANR dialog in android applications and when it will happen and how to remove that. Please help me.

ANR - application not responding.

This dialog appears when the main thread of the application is blocked for too long, for example, when you sleep on this thread, or performing a long connection.

Avoiding it is done by moving the heavy operations to other threads. There's a great article regarding the ways to implement that - Painless Threading.

这篇关于什么是ANR对话框中的Andr​​oid?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆