Class: Oyster::FloatOption

Inherits:
StringOption show all
Defined in:
lib/oyster/options/float.rb

Instance Attribute Summary

Attributes inherited from Option

#description

Instance Method Summary collapse

Methods inherited from StringOption

#help_names

Methods inherited from Option

#alternate, create, #has_name?, #help_names, #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/float.rb', line 4

def consume(list)
  super.to_f
end

#default_valueObject



8
9
10
# File 'lib/oyster/options/float.rb', line 8

def default_value
  super(0)
end