Class: AddressFinder::Bulk

Inherits:
Object
  • Object
show all
Defined in:
lib/addressfinder/bulk.rb

Defined Under Namespace

Classes: ClientProxy

Instance Method Summary collapse

Constructor Details

#initialize(http:, verification_version:, default_country:, &block) ⇒ Bulk

Returns a new instance of Bulk.



3
4
5
6
7
8
# File 'lib/addressfinder/bulk.rb', line 3

def initialize(http:, verification_version:, default_country:, &block)
  @block = block
  @verification_version = verification_version
  @default_country = default_country
  @http_config = http
end

Instance Method Details

#performObject



10
11
12
13
14
# File 'lib/addressfinder/bulk.rb', line 10

def perform
  http_config.start do |http|
    block.call ClientProxy.new(http: http, verification_version: verification_version, default_country: default_country)
  end
end