- Learning Concurrency in Kotlin
- Miguel Angel Castiblanco Torres
- 84字
- 2021-08-05 10:46:47
NetworkOnMainThreadException
In Java, network operations are blocking by nature. Calling a web service, for example, will block the current thread until a response is received or a timeout/error happens. Because blocking the UI thread would mean freezing all the UI – including animations and any other interactions – Android crashes whenever a network operation is made on the UI thread. The NetworkOnMainThreadException exception will be thrown whenever this happens, forcing developers to use a background thread, and thus improving the user experience.
推薦閱讀
- 自制編譯器
- Raspberry Pi for Secret Agents(Third Edition)
- Visual Basic學習手冊
- SQL Server 2016數據庫應用與開發
- Unity UI Cookbook
- Spring+Spring MVC+MyBatis從零開始學
- Django 3.0應用開發詳解
- Visual FoxPro 6.0程序設計
- Python Digital Forensics Cookbook
- HTML5+CSS3+jQuery Mobile+Bootstrap開發APP從入門到精通(視頻教學版)
- 劍指大數據:企業級電商數據倉庫項目實戰(精華版)
- Spring MVC Blueprints
- JSP編程教程
- C#教程
- 51單片機C語言程序設計經典實例(第3版)