Class: HammerCLI::Options::OptionProcessor

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

Direct Known Subclasses

Sources::Base, Validators::Base

Instance Method Summary collapse

Constructor Details

#initialize(name: nil) ⇒ OptionProcessor

Returns a new instance of OptionProcessor.



4
5
6
# File 'lib/hammer_cli/options/option_processor.rb', line 4

def initialize(name: nil)
  @name = name
end

Instance Method Details

#nameObject



8
9
10
# File 'lib/hammer_cli/options/option_processor.rb', line 8

def name
  @name || self.class.name.split('::')[-1]
end

#process(defined_options, result) ⇒ Object



12
13
14
# File 'lib/hammer_cli/options/option_processor.rb', line 12

def process(defined_options, result)
  result
end