I've got an assignment for school this week where we need to build an app in Android studio that endlessly queries a website that displays random cat pictures, validate if that picture is already downloaded on the device using JSON to check it's ID, download it if it's not already downloaded, and then display them one after another in an endless loop in a slideshow like setting. The app is being built with Android Studio, but to be honest the resources for this week's project are a bit on the light side.
From what I can gather, I need to establish an inputsteam to the network, build a JSON reader to scan the information, check the android device to make sure that the file isn't already there based on it's JSON ID, download it to the phone, then display it in a bitmap.
Problem is, I have no idea how to validate JSON data to determine duplicates, in this way or any other. Does anyone have any advice on how to do this? Bonus points if you can help me clarify the rest of the process as well, as I'm piece-mealing like crazy from different sources and don't have a very good grasp on how to even do this or create a proper JSON query.
Thank you all in advance!