CMPUT 301

Software Engineering

Lab 2 Instructions


Lab 2 Instructions

In Lab 2, we'll be doing the following:

Quick review of OOP principles Android Basics (Lab 2 Android Basics PDF under Lab 2) Displaying a list of items using ListView/ListAdapter (Lab 2 ListView Demo Example - Instructions PDF under Lab 2) Lab Exercise - adding and removing items from ListAdapter (see the Lab 2 Participation Exercise below for more details.)

Lab 2 Participation Exercise

Task: Modify/Expand ListyCity to allow for the addition of new cities as well as the deletion of existing ones in the ListView. The specifics of the design of this functionality are up to you.

If you could not attend the labs or do not have the code for ListyCity, follow the instructions in Lab 2 ListView Example - Instructions.

Hints:

  1. You may want to use the OnClickListener methods discussed in the lab.

  2. Ideally you should consider treating the cities as objects, however, in this exercise it may not be necessary.

Here are some screenshots from an example application that demonstrate the required functionality.

Your app does not need to look exactly like this demo!!!

  1. Press "ADD CITY" then type the name and press "CONFIRM". This adds a new city name to the listview

  2. Tap a city name to select it then press "DELETE CITY" to remove the city from the listview.

Screen1 Screen2 Screen3 Screen4

You should submit your exercise as the project folder in the format of a zip archive.

Note: Proper completion of this exercise is considered as part of course participation.

Due Date

Friday after the Thursday lab at 4PM