cjheath/geoip — pull request #26 by connec (2013-02-25 13:11:45+00:00)
Title: Support for extracting information from GeoIP region databases.

I've tried to follow the trends of the existing code:

- created a `GeoIP::Region` struct that has the relevant fields from City
- created a public `GeoIP#region` method for performing a region lookup (this also falls back to a city lookup if the database is a city database, similar to `GeoIP#country`)
- created a private `GeoIP#read_region` method containing the code for reading the database

All the code was adapted (almost line-for-line) from [maxmind's PHP GeoIP library](https://github.com/maxmind/geoip-api-php/blob/master/geoip.inc#L666).