Sha256: 2210b01c1f9213d8d4fa31b12c97370373ca51f56cd3a52bb1bb44271f4e3cc4
Contents?: true
Size: 696 Bytes
Versions: 8
Compression:
Stored size: 696 Bytes
Contents
# encoding: UTF-8 Measurement.define(:'m³') do |unit| unit.alias :m3, :'m^3', :'m*m*m', :'cubic meter', :'cubic meters' unit.convert_to(:dm3) { |value| value * 1_000.0 } unit.convert_to(:cm3) { |value| value * 1_000_000.0 } end Measurement.define(:'dm³') do |unit| unit.alias :dm3, :'dm^3', :'dm*dm*dm', :'cubic decimeter', :'cubic decimeters' unit.convert_to(:m3) { |value| value / 1_000.0 } unit.convert_to(:cm3) { |value| value * 1_000.0 } end Measurement.define(:'cm³') do |unit| unit.alias :cm3, :'cm^3', :'cm*cm*cm', :'cubic centimeter', :'cubic centimeters' unit.convert_to(:m3) { |value| value / 1_000_000.0 } unit.convert_to(:dm3) { |value| value / 1_000.0 } end
Version data entries
8 entries across 8 versions & 1 rubygems