Is it possible to show a progress bar when downloading a file through Retrofit 2, Android

I am currently using Retrofit 2 and I want to download a file from my server. Can I call back some event to catch the percentage complete download file to show in the notification how this image enter image description here

I am linking to this link, but it is loading, can I do it with the same problem? Link

Is it possible to demonstrate progress using the retrofit 2 library?

+5
source share
1 answer

You can use ResponseBody and set it for the OkHttp client and update the progress in the user interface that you can use. check this link

+8
source

Source: https://habr.com/ru/post/1247919/


All Articles