Sha256: 254af0797006badd5e7c50b1e46668115b42fac30938be4d7502c05dd52d0f63

Contents?: true

Size: 532 Bytes

Versions: 11

Compression:

Stored size: 532 Bytes

Contents

# -*- encoding: utf-8 -*-
# -*- frozen_string_literal: true -*-
# -*- warn_indent: true -*-

UnitMeasurements::Length = UnitMeasurements.build do
  primitive "m"

  system :metric do
    si_unit "m", aliases: ["meter", "metre", "meters", "metres"]
  end

  system :imperial do
    unit "in", value: "25.4 mm", aliases: ['"', "inch", "inches"]
    unit "ft", value: "12 in", aliases: ["'", "foot", "feet"]
    unit "yd", value: "3 ft", aliases: ["yard", "yards"]
    unit "mi", value: "1760 yd", aliases: ["mile", "miles"]
  end
end

Version data entries

11 entries across 11 versions & 1 rubygems

Version Path
unit_measurements-4.10.0 lib/unit_measurements/unit_groups/length.rb
unit_measurements-4.9.0 lib/unit_measurements/unit_groups/length.rb
unit_measurements-4.8.0 lib/unit_measurements/unit_groups/length.rb
unit_measurements-4.7.0 lib/unit_measurements/unit_groups/length.rb
unit_measurements-4.6.0 lib/unit_measurements/unit_groups/length.rb
unit_measurements-4.5.0 lib/unit_measurements/unit_groups/length.rb
unit_measurements-4.4.0 lib/unit_measurements/unit_groups/length.rb
unit_measurements-4.3.0 lib/unit_measurements/unit_groups/length.rb
unit_measurements-4.2.0 lib/unit_measurements/unit_groups/length.rb
unit_measurements-4.1.0 lib/unit_measurements/unit_groups/length.rb
unit_measurements-4.0.0 lib/unit_measurements/unit_groups/length.rb