Here you can find the source of parseDate(String dateStr)
private static Date parseDate(String dateStr)
//package com.java2s; //License from project: Apache License import java.text.ParseException; import java.text.SimpleDateFormat; import java.util.Date; public class Main { private static Date parseDate(String dateStr) { if (dateStr == null || dateStr.length() < 14) return null; int hour = Integer.parseInt(dateStr.substring(0, 2)); int mins = Integer.parseInt(dateStr.substring(3, 5)); String date = dateStr.substring(6); SimpleDateFormat format = new SimpleDateFormat("dd/MM/yyyy"); try {/* w ww . j ava 2 s . c om*/ Date tmp = format.parse(date); return new Date(tmp.getTime() + 60 * 60 * 1000 * hour + 60 * 1000 * mins); } catch (ParseException e) { // TODO Auto-generated catch block e.printStackTrace(); } return null; } }