code: def __parse(value):
          
          match_result = _RE_DATETIME.match(value)
          if match_result is None:
             raise ValueError("date data has invalid format '%s'" % (value,))
  
          date = _date_from_match(match_result)
          time, round_up = _time_from_match(match_result)
          tzinfo = _tzinfo_from_match(match_result)
  
          value = datetime.datetime.combine(date, time)
          value = value.replace(tzinfo=tzinfo)
          if round_up:
              value += datetime.timedelta(microseconds=1)
          return value
docs: Parse the string datetime.
  
          Supports the subset of ISO8601 used by xsd:dateTime, but is lenient
          with what is accepted, handling most reasonable syntax.
  
          Subsecond information is rounded to microseconds due to a restriction
          in the python datetime.datetime/time implementation.
  
          @param value: A datetime string.
          @type value: str
          @return: A datetime object.
          @rtype: B{datetime}.I{datetime}