Here you can find the source of isSameDate(long var0, long var2)
public static boolean isSameDate(long var0, long var2)
//package com.java2s; //License from project: Apache License import java.util.Calendar; import java.util.Date; public class Main { public static boolean isSameDate(long var0, long var2) { return isSameDate(var0, var2, 5); }// ww w.j a v a 2s . c o m public static boolean isSameDate(long var0, long var2, int var4) { Calendar var5 = Calendar.getInstance(); Calendar var6 = Calendar.getInstance(); var5.setTime(new Date(var0)); var6.setTime(new Date(var2)); return var5.get(1) == var6.get(1) && (var4 == 1 || var5.get(2) == var6.get(2) && (var4 == 2 || var5.get(5) == var6.get(5))); } }