Exemple #1
0
def parse(subject, value, red):
    try:
        date = rh.parse_date(value)
    except ValueError:
        red.add_note(subject, rs.BAD_DATE_SYNTAX)
        return None
    return date
Exemple #2
0
 def parse(self, field_value: str, add_note: AddNoteMethodType) -> int:
     try:
         date_value = headers.parse_date(field_value, add_note)
     except ValueError:
         raise
     return date_value
Exemple #3
0
 def parse(self, field_value: str, add_note: AddNoteMethodType) -> int:
     try:
         date = headers.parse_date(field_value, add_note)
     except ValueError:
         raise
     return date