Parses a variety of date formats into a 9-tuple in GMT
(dateString)
| 3551 | registerDateHandler(_parse_date_perforce) |
| 3552 | |
| 3553 | def _parse_date(dateString): |
| 3554 | '''Parses a variety of date formats into a 9-tuple in GMT''' |
| 3555 | if not dateString: |
| 3556 | return None |
| 3557 | for handler in _date_handlers: |
| 3558 | try: |
| 3559 | date9tuple = handler(dateString) |
| 3560 | except (KeyError, OverflowError, ValueError): |
| 3561 | continue |
| 3562 | if not date9tuple: |
| 3563 | continue |
| 3564 | if len(date9tuple) != 9: |
| 3565 | continue |
| 3566 | return date9tuple |
| 3567 | return None |
| 3568 | |
| 3569 | def _getCharacterEncoding(http_headers, xml_data): |
| 3570 | '''Get the character encoding of the XML document |
no test coverage detected
searching dependent graphs…