Class: Oyster::StringOption
- Inherits:
-
Option
- Object
- Option
- Oyster::StringOption
show all
- Defined in:
- lib/oyster/options/string.rb
Instance Attribute Summary
Attributes inherited from Option
#description
Instance Method Summary
collapse
Methods inherited from Option
#alternate, create, #has_name?, #initialize, #name
Constructor Details
This class inherits a constructor from Oyster::Option
Instance Method Details
#consume(list) ⇒ Object
4
5
6
|
# File 'lib/oyster/options/string.rb', line 4
def consume(list)
list.shift
end
|
#default_value(value = nil) ⇒ Object
8
9
10
|
# File 'lib/oyster/options/string.rb', line 8
def default_value(value = nil)
super(value || nil)
end
|
#help_names ⇒ Object
12
13
14
|
# File 'lib/oyster/options/string.rb', line 12
def help_names
super.map { |name| name + ' ARG' }
end
|