Lines Matching refs:DurationUnit
31 using DurationUnit = internal::DurationUnit; typedef
44 DurationUnit duration_unit, in FillDurationUnitMap()
45 std::unordered_map<std::string, DurationUnit>* target_map, in FillDurationUnitMap()
58 std::unordered_map<std::string, DurationUnit> BuildTokenToDurationUnitMapping( in BuildTokenToDurationUnitMapping()
60 std::unordered_map<std::string, DurationUnit> mapping; in BuildTokenToDurationUnitMapping()
61 FillDurationUnitMap(options->week_expressions(), DurationUnit::WEEK, &mapping, in BuildTokenToDurationUnitMapping()
63 FillDurationUnitMap(options->day_expressions(), DurationUnit::DAY, &mapping, in BuildTokenToDurationUnitMapping()
65 FillDurationUnitMap(options->hour_expressions(), DurationUnit::HOUR, &mapping, in BuildTokenToDurationUnitMapping()
67 FillDurationUnitMap(options->minute_expressions(), DurationUnit::MINUTE, in BuildTokenToDurationUnitMapping()
69 FillDurationUnitMap(options->second_expressions(), DurationUnit::SECOND, in BuildTokenToDurationUnitMapping()
106 DurationUnit GetDanglingQuantityUnit(const DurationUnit main_unit) { in GetDanglingQuantityUnit()
108 case DurationUnit::HOUR: in GetDanglingQuantityUnit()
109 return DurationUnit::MINUTE; in GetDanglingQuantityUnit()
110 case DurationUnit::MINUTE: in GetDanglingQuantityUnit()
111 return DurationUnit::SECOND; in GetDanglingQuantityUnit()
112 case DurationUnit::UNKNOWN: in GetDanglingQuantityUnit()
115 case DurationUnit::WEEK: in GetDanglingQuantityUnit()
116 case DurationUnit::DAY: in GetDanglingQuantityUnit()
117 case DurationUnit::SECOND: in GetDanglingQuantityUnit()
119 return DurationUnit::UNKNOWN; in GetDanglingQuantityUnit()
224 const DurationUnit main_unit = parsed_duration_atoms.rbegin()->unit; in FindDurationStartingAt()
236 if (atom.unit != DurationUnit::UNKNOWN) { in FindDurationStartingAt()
263 case DurationUnit::WEEK: in ParsedDurationAtomsToMillis()
266 case DurationUnit::DAY: in ParsedDurationAtomsToMillis()
269 case DurationUnit::HOUR: in ParsedDurationAtomsToMillis()
272 case DurationUnit::MINUTE: in ParsedDurationAtomsToMillis()
275 case DurationUnit::SECOND: in ParsedDurationAtomsToMillis()
278 case DurationUnit::UNKNOWN: in ParsedDurationAtomsToMillis()
325 const Token& token, DurationUnit* duration_unit) const { in ParseDurationUnitToken()