Git Product home page Git Product logo

terremoto's Introduction

Terremoto

Terremoto is a sample iPhone application that I wrote as an exercise in iPhone programming.

Implementation Overview

This iOS 6 application uses NSXMLParser to fetch and parse earthquake information from the USGS web site. It then plots the earthquakes on a world map using MapKit.

There are several similar apps on the web and in the app store. Apple has sample code to show the use of the NSXMLParser, but that code displays the earthquakes in arbitrary order in a UITableView with no map.

Another similar application is from Bill Dudney's screencast and sample code at Pragmatic Programmers. The code in Terremoto (my application) uses Dudney's XML parser code (with permission) almost verbatim at present. My view controller is similar to Dudney's, since I learned from his code and there are only so many ways to do this, although over time my view controller code has taken its own direction. Among the ways my app, Terremoto, differs from Dudney's is that Terremoto displays all earthquake events fetched from the USGS site, not just the 50 or 100 nearest to the user's location. This requires changes in the way Terremoto zooms to the user's current location, among other things. My application also displays details about the earthquake in a UIWebView within the application, whereas Dudney's demo app displayed this information by launching Safari on a USGS URL.

I plan to show earthquakes on the map using a custom annotation view to resemble the maps on the USGS web site itself, where events are displayed not as color-coded pins, but as squares of varying sizes and colors. I also want to add a control to allow the user to zoom to the current location at any time. Another feature I plan to add is one that will show the most recent earthquakes first, perhaps making a recent earthquake the initial zoom location, or perhaps adding a view that shows the earthquakes in a list sorted by time of the event or by magnitude.

Craig Schamp

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.