return Math.abs(date1.getTimeInMillis() - date2.getTimeInMillis()) < ONE_DAY_IN_MILLIS;
return Math.abs(timestamp1.getTimeInMillis() - timestamp2.getTimeInMillis()) < ONE_DAY_IN_MILLIS;
    private boolean isSameDailySession(Calendar timestamp1, Calendar timestamp2) {        if (!isDailySessionTime(timestamp1) || !isDailySessionTime(timestamp2)) {            return false;        }        if (timestamp1.equals(timestamp2)) {            return true;        }        Calendar date1 = getDateOnly(timestamp1, calendar1);        Calendar date2 = getDateOnly(timestamp2, calendar2);        if (startTime.before(endTime) || startTime.equals(endTime)) {            return date1.equals(date2);        } else if (startTime.after(endTime)) {            return Math.abs(date1.getTimeInMillis() - date2.getTimeInMillis()) < ONE_DAY_IN_MILLIS;        }        return false;    }