Class: DumpCleaner::Options

Inherits:
Object
  • Object
show all
Defined in:
lib/dump_cleaner/options.rb

Constant Summary collapse

DEFAULT_OPTIONS =
{
  config_file: "config/dump_cleaner.yml"
}.freeze

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(argv) ⇒ Options

Returns a new instance of Options.



13
14
15
16
17
# File 'lib/dump_cleaner/options.rb', line 13

def initialize(argv)
  DEFAULT_OPTIONS.each { |k, v| send(:"#{k}=", v) }
  parse(argv)
  validate
end

Instance Attribute Details

#config_fileObject

Returns the value of attribute config_file.



11
12
13
# File 'lib/dump_cleaner/options.rb', line 11

def config_file
  @config_file
end

#destination_dump_pathObject

Returns the value of attribute destination_dump_path.



11
12
13
# File 'lib/dump_cleaner/options.rb', line 11

def destination_dump_path
  @destination_dump_path
end

#source_dump_pathObject

Returns the value of attribute source_dump_path.



11
12
13
# File 'lib/dump_cleaner/options.rb', line 11

def source_dump_path
  @source_dump_path
end