def search(query, count=10)
      return [] if query.length < 4
      response = @connection.get DOMESTIC_URL, params: { q: query.to_ascii, count: count }
      addresses = response.parsed['addresses'].each do |a|
        a['address_id'] = Integer(a['address_id'])
        a['dpid'] = Integer(a['dpid']) if a['dpid']
      end
      addresses.map {|address| OpenStruct.new(address)}
    end
def search(query, count=10)
      return [] if query.length < 4
      response = @connection.get DOMESTIC_URL, params: { q: query.to_ascii, count: count }
      addresses = response.parsed['addresses'].each do |a|
        a['address_id'] = Integer(a['address_id'])
        a['dpid'] = Integer(a['dpid']) if a['dpid']
      end
      addresses.map {|address| OpenStruct.new(address)}
    end
Creates a new ParcelApi::Address instance.
 Search for a Domestic (NZ) Address
 @param [String] characters to search for
 @param [Integer] number of search results to return (max 10)
 @return [Array] array of addresses