Sha256: 32b46f8e3059426a10984a47c3a332aea5fc933a22a4e944d18b8f4d25f65340
Contents?: true
Size: 347 Bytes
Versions: 2
Compression:
Stored size: 347 Bytes
Contents
module Barometer module Query module Format # # eg. 90210 or 90210-5555 # class Zipcode < Base def self.country_code(query); "US"; end def self.regex; /(^[0-9]{5}$)|(^[0-9]{5}-[0-9]{4}$)/; end end end end end Barometer::Query::Format.register(:zipcode, Barometer::Query::Format::Zipcode)
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
barometer-0.9.1 | lib/barometer/query/formats/zipcode.rb |
barometer-0.9.0 | lib/barometer/query/formats/zipcode.rb |