Here you can find the source of parseDate4UrlCreateTime(String dateStr)
public static Date parseDate4UrlCreateTime(String dateStr)
//package com.java2s; import java.text.ParseException; import java.text.SimpleDateFormat; import java.util.Date; public class Main { private final static String FMT_4_URL_CREATETIME = "yyyy-MM-dd HH:mm:ss"; public static Date parseDate4UrlCreateTime(String dateStr) { Date result = null;//from ww w . jav a2 s. c o m try { result = new SimpleDateFormat(FMT_4_URL_CREATETIME).parse(dateStr); } catch (ParseException e) { e.printStackTrace(); } return result; } }