(self, spec: str)
| 258 | ) |
| 259 | |
| 260 | def parse(self, spec: str) -> set[int]: |
| 261 | acc = set() |
| 262 | for part in spec.split(','): |
| 263 | if not part: |
| 264 | raise self.ParseException('empty part') |
| 265 | acc |= set(self._parse_part(part)) |
| 266 | return acc |
| 267 | |
| 268 | def _parse_part(self, part: str) -> list[int]: |
| 269 | for regex, handler in self.pats: |
no test coverage detected