Method: UnitMeasurements::Cache#get
- Defined in:
- lib/unit_measurements/cache.rb
#get(source_unit, target_unit) ⇒ Numeric|NilClass
Retrieves the conversion factor between source and target units from the cache.
56 57 58 |
# File 'lib/unit_measurements/cache.rb', line 56 def get(source_unit, target_unit) cached_data.dig(source_unit, target_unit) end |