I would like to create a Class that would convert common date formats to their python equivalent.
I thought of an enum class but I have a problem when I have variable names with hyphens (which is not possible in python).
import enum
class DateFormatList(enum.Enum):
yyyymmdd = '%Y%m%d'
yymmdd = '%y%m%d'
I have issue with:
mmm-dd-yyyy = '%b-%d-%Y'
Any suggestion about how to do this?