Created
February 13, 2012 09:33
-
-
Save ndeverge/1815478 to your computer and use it in GitHub Desktop.
Need some refactoring...
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public static Date getDateDDMMYYYY(final String dateString) { | |
final SimpleDateFormat formatter = new SimpleDateFormat("dd/MM/yyyy"); | |
try { | |
return formatter.parse(dateString, new ParsePosition(0)); | |
} catch (NullPointerException e) { | |
return null; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment