Android Fast Networking Library JSON Examples.
Let's look at some examples.
How to populate custom gridview with json data containing images and text.
In this tutorial we want to se how to download some JSON data from online asynchronously, parse that data and bind to a custom gridview with cardviews.
We are fetching images and text in our gridview. So our custom gridview will have cardviews that render for us images and text in a nice way.
We will be using the Fast Networking library which is built on top OkHttp. This will provide us with a fast and easy to work networking capability.
We are making a HTTP GET request. As our data is downloaded, we will show an indeterminate progressbar will be hidden automatically when the data download is finish.
This allows us to show user the download progress. In case of any error, we will show a Toast message containing details about the error so that you can view it at runtime, which is very important for newbies.