getDateFormat method implemented.