Here you can find the source of isSameLocalTime(Calendar calSource, Calendar calDesti)
public static boolean isSameLocalTime(Calendar calSource, Calendar calDesti)
//package com.java2s; import java.sql.Timestamp; import java.util.Calendar; public class Main { public static boolean isSameLocalTime(Calendar calSource, Calendar calDesti) {//w w w. j av a2 s . co m return calSource.equals(calDesti); } public static boolean equals(Timestamp t1, Timestamp t2) { if (t1 == null && t2 == null) { return true; } else { if (t1 == null) { return t2.equals(t1); } else { return t1.equals(t2); } } } }