Module: GeoDistance::Unit
- Extended by:
- GeoUnits, GeoUnits::UnitMaps
- Defined in:
- lib/geo_vectors/util/geo_distance/units.rb
Overview
used to extend Fixnum and Float
Instance Method Summary collapse
Methods included from GeoUnits::Methods
#check_unit!, #default_unit, #default_unit=, #valid_unit?, #valid_units
Methods included from GeoUnits::UnitMaps
Instance Method Details
#[](key) ⇒ Object
24 25 26 27 |
# File 'lib/geo_vectors/util/geo_distance/units.rb', line 24 def [] key raise ArgumentError, "Invalid unit key #{key}" if !respond_to? key earth_radius[key] * self end |