Add helper for maxlength into measure.lua

This commit is contained in:
Frédéric Rodrigo 2018-06-06 11:07:01 +02:00 committed by Patrick Niklaus
parent 3088dd0342
commit 7ff68792d7

View File

@ -70,7 +70,14 @@ function Measure.get_max_width(raw_value)
end
end
--- Get maxweight of specified way in kilogramms
--- Get maxlength of specified way in meters.
function Measure.get_max_length(raw_value)
if raw_value then
return Measure.parse_value_meters(raw_value)
end
end
--- Get maxweight of specified way in kilogramms.
function Measure.get_max_weight(raw_value)
if raw_value then
return Measure.parse_value_kilograms(raw_value)