????

Your IP : 3.140.198.3


Current Path : /proc/self/root/proc/self/root/lib/python3.6/site-packages/pyasn1/compat/
Upload File :
Current File : //proc/self/root/proc/self/root/lib/python3.6/site-packages/pyasn1/compat/dateandtime.py

#
# This file is part of pyasn1 software.
#
# Copyright (c) 2005-2017, Ilya Etingof <etingof@gmail.com>
# License: http://pyasn1.sf.net/license.html
#
from sys import version_info
from datetime import datetime
import time

__all__ = ['strptime']


if version_info[:2] <= (2, 4):

    def strptime(text, dateFormat):
        return datetime(*(time.strptime(text, dateFormat)[0:6]))

else:

    def strptime(text, dateFormat):
        return datetime.strptime(text, dateFormat)