maha.parsers.rules.duration.utils#
Module Contents#
Functions#
|
Converts a list of durations to another unit using the mapping |
- convert_between_durations(*durations, to_unit)[source]#
Converts a list of durations to another unit using the mapping
DURATION_CONVERSION_MAP.- Parameters
*durations – List of durations to convert.
to_unit (maha.parsers.templates.enums.DurationUnit) – The unit to convert to.
durations (maha.parsers.rules.common.ValueUnit) –
- Returns
The converted value.
- Return type
float