Sha256: 43f42177a156c80b84d66c99371e70860b46c58eb094398281afaf00264d8b99
Contents?: true
Size: 513 Bytes
Versions: 1
Compression:
Stored size: 513 Bytes
Contents
module Indirizzo # Defines the matching of parsed address tokens. Match = { # FIXME: shouldn't have to anchor :number and :zip at start/end :number => /^(\d+\W|[a-z]+)?(\d+)([a-z]?)\b/io, :street => /(?:\b(?:\d+\w*|[a-z'-]+)\s*)+/io, :city => /(?:\b[a-z][a-z'-]+\s*)+/io, :state => State.regexp, :zip => /\b(\d{5})(?:-(\d{4}))?\b/o, :at => /\s(at|@|and|&)\s/io, :po_box => /\b[P|p]*(OST|ost)*\.*\s*[O|o|0]*(ffice|FFICE)*\.*\s*[B|b][O|o|0][X|x]\b/ } end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
HornsAndHooves-indirizzo-0.1.7.1 | lib/indirizzo/match.rb |