Class: CSVGeocoder::OutputPathRetriever

Inherits:
Object
  • Object
show all
Defined in:
lib/csv_geocoder/output_path_retriever.rb

Instance Method Summary collapse

Constructor Details

#initialize(prompt) ⇒ OutputPathRetriever

Returns a new instance of OutputPathRetriever.



3
4
5
# File 'lib/csv_geocoder/output_path_retriever.rb', line 3

def initialize(prompt)
  @prompt = prompt
end

Instance Method Details

#ask_for_output_pathObject



7
8
9
10
11
12
13
# File 'lib/csv_geocoder/output_path_retriever.rb', line 7

def ask_for_output_path
  @prompt.ask("Where do you want to save the new CSV?",
    required: true,
    value: "./geocoded.csv",
    convert: :path
  )
end