70 likes | 223 Views
Assignment 2 – GPS Message Board. Justin Loo. Purpose. Retrieve messages from a server based on your current latitude/longitude Uses GPS for latitude/longitude Also has option to use your own input for coordinates
E N D
Assignment 2 – GPS Message Board Justin Loo
Purpose • Retrieve messages from a server based on your current latitude/longitude • Uses GPS for latitude/longitude • Also has option to use your own input for coordinates • Can add/delete messages if so desired, no concept of permissions for deleting messages.
Activities • Initial Screen 2. Message List Latitude Longitude Messages Select Input toggle button (When checked it uses User input, otherwise GPS)
Activities cont’d • 2. Message List (GPS) 3. Add Message
Design • Message Object for each entry • Contains the following • Message ID (generated server side, passed back with request) • Name (String) • Message (String) • Latitude (int) • Longitude (int) • Timestamp (double, not used but perhaps in the future)
Design • Terms of Service screen uses SharedPreferences to store whether or not the user previously wanted to skip that screen, does not register if reject was pressed. • Messages are retrieved from AppEngine running JSONEngine, the GET request contains latitude and longitude. Response is parsed into a list of Message objects and the scrolling display is populated using that. • Longpress on an entry to bring up option for deleting it, uses the id stored in each Message object • Adding Messages uses an HTTP Post with key, value pairs for Name, Message, and Coordinates