Why using a framework to make Http requests in Android instead of using its own classes to make this? [closed]

StackOverflow https://stackoverflow.com/questions/22585462

There are many frameworks to make http requests in Android, like Retrofit and Volley. But also, Android has its own classes to make this type of request, like HttpURLConnection and HttpClient

So what is the advantage of using some framework like these mentioned?

My doubt is if there is some big advantage in make requests using some framework, instead of using Android native classes.

有帮助吗?

解决方案

The advantage is things like retries, restarts, threading & synchronization, and state management will be handled for you. This comes at the expense of configurability, but it's not a huge expense.

许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top