[SOLVED] MAP524 - Mobile App Development  - Android Final Test – Practical Section

30.00 $

Programming resource
Digital learning resource
Category:
Practical programming resource
Suitable for guided study and reference
Tutor guidance available when needed

Description

5/5 - (2 votes)

Task:

You are to create an Android application named as YourFirstname_Vacation as per the specifications given below:

The app will consist of two (2) screens:

  1. Main Screen: This screen displays a list of countries
  2. Favorite List Screen: This screen displays a list of countries that the user marked as favourite

 

Details about each screen are provided below.

Main Screen:

 

  • The image of the country’s flag must be obtained from https://www.countryflags.io/XX/flat/64.png, where XX is the country code. You must use the country code obtained from https://restcountries.eu/rest/v2/all to construct the URL for connecting to and fetching the image from countryflags.io. Hint: You should use Picasso or Glide library for getting the images displayed.
  • A user can mark a country as “favourite” by tapping on a row in the RecyclerView. You must save the user’s favorite country in a Room or Cloud Firestore database.
  • Finally, provide an options menu to the user on main screen through which they should be able to open a new screen to view favorite list screen.
  • Bonus (5%) : While adding country to favourite list on Firestore, check if the country already exists on the fav list; if yes, don’t add it on Firestore and display appropriate message to the user.

Favourite List Screen:

  • Upon opening this screen, the app should fetch all the favourite countries from database and display them in a RecyclerView. Each item of the RecyclerView must show the country name and image of the flag. Flag images should be obtained using Glide/Picasso from https://www.countryflags.io/XX/flat/64.png, where XX is the country code.
  • When the user taps on a row in the RecyclerView, remove the country from the user’s favorites list which must be reflected in database.
Resource details

Understand the Task Before You Use the Resource

Review the requirements, identify the programming concepts involved, study the implementation and test your understanding with your own examples and modifications.