Consume Webservices with Android - Retrofit or Volley?

Asked

Viewed 452 times

0

The question is just this: to consume Webservices with Android - Retrofit or Volley? I found the two complicated at first, but reading the documentation it seemed to me that retrofit can be something less complicated. What suggest?

2 answers

2


Retrofit is one of the most powerful and popular libraries of HTTP Client for Android and Java. I would recommend using the Retrofit2. No doubt it will make your life easier when you study it, because one of the great differentials of Retrofit2 is its 'Simplicity'. But if you are a beginner, I would recommend you do everything in the 'NAIL', from creating the connection to the Webservice until the deserialization of your consumed object, because then you would see how the consumption flow works.

0

I "have" (the company I work has hahaha) an application in Native Android and I consume WS but use neither of these two tools for a very important reason in my point of view, maintenance. And I sincerely suggest do what you need to consume WS that way will have nothing "leftover" in your application (you do only what you need and nothing more), for mobile development you need to take into account the "unused stretches" of your code. Won’t take long nor difficult consume a WS (the reality is that we mystify this a lot), and if you need change anything you have the opportunity and nothing stops you.

Ps. Like I said it’s mine recommending, if the opinions are different ok (happens).

  • 1

    Thanks @Webferreira . I am a student and need to create an application that consumes an API developed by the teacher. He left it free so I’m looking for solutions to this job.

Browser other questions tagged

You are not signed in. Login or sign up in order to post.