added isDateType check and a parser method for date types.