AutoApi.UnitType.unit_id
You're seeing just the function
unit_id
, go back to AutoApi.UnitType module for more information.
Specs
Returns the ID of an unit of measurement.
The measurement name can be passed either as string or atom, but the unit name is only accepted in atom format.
Examples
iex> AutoApi.UnitType.unit_id(:volume, :liters)
0x02
iex> AutoApi.UnitType.unit_id("power", :megawatts)
0x03
iex> AutoApi.UnitType.unit_id("power", :foobar)
nil