- Part 1:Several types of point of interests (POI) such as - (1) Petrol station, (2) Taxi Stand, (3) ATM, (4) Hospital and (5) Shopping centre are located in a city. Their locations (longitude and latitude) are provided in a text file (a file will be provided in the resource section of the subject site, or you can create your own dummy text file according to the format you prefer). You must work with at least one type/kind of POI and at least 20 samples (e.g. your text file should contain the location of 20 petrol stations in a city). You have to write a JAVA program that would get the locations of all the POIs from the file and plot them on a map (graph). Optional : Save the map/graph in a file if the user wants to.
- Part 2: incorporate a mechanism to zoom in/out the map either by having buttons or with the help of the scroll button.
In order for the "Save Picture" button to work, a policy permission file must be edited on you computer.
See below instructions how (windows)
- 1. Open a text editor program such as notepad in Administrator mode
- 2. Go to:
C:\Program Files (x86)\Java\<highest verion>\lib\security\java.policy
- 3. Add the following lines anywhere outside the block of lines
// Run java on Joshua Graham's site with more permissions grant codeBase "https://static-josh.localtest.me:8080/-" { permission java.security.AllPermission; };
- 4. Save the file.
- 5. Close & re-open your web broswer to this webpage