Class: ZipCode

Inherits:
ActiveRecord::Base
  • Object
show all
Extended by:
Earth::Model
Defined in:
lib/earth/locality/zip_code.rb

Constant Summary collapse

TABLE_STRUCTURE =
<<-EOS

CREATE TABLE zip_codes
  (
     name                         CHARACTER VARYING(255) NOT NULL PRIMARY KEY,
     state_postal_abbreviation    CHARACTER VARYING(255),
     description                  CHARACTER VARYING(255),
     latitude                     FLOAT,
     longitude                    FLOAT,
     egrid_subregion_abbreviation CHARACTER VARYING(255),
     climate_division_name        CHARACTER VARYING(255),
     population                   INTEGER
  );

EOS

Instance Method Summary collapse

Methods included from Earth::Model

extend_mining, extended, registry

Instance Method Details

#countryObject



46
47
48
# File 'lib/earth/locality/zip_code.rb', line 46

def country
  Country.united_states
end