public static void main(String[] args){
long nowInMillis = System.currentTimeMillis();
long INACTIVITY_TOLERANCE_IN_MILLIS = 32L * MILLIS_IN_ONE_DAY;
RollingCalendar rc = new RollingCalendar("yyyy-MM-dd-HH");
System.out.println("periodicityType: " + rc.computePeriodicityType().name());
TimeZone timeZone = rc.getTimeZone();
System.out.println("timeZone: " + timeZone.getDisplayName());
long start = nowInMillis;
long end = nowInMillis + INACTIVITY_TOLERANCE_IN_MILLIS;
System.out.println("start: " + new Date(start));
System.out.println("end: " + new Date(end));
long startFloored = rc.getStartOfCurrentPeriodWithGMTOffsetCorrection(start, timeZone);
long endFloored = rc.getStartOfCurrentPeriodWithGMTOffsetCorrection(end, timeZone);
System.out.println("startFloored: " + startFloored + ", " + new Date(startFloored));
System.out.println("endFloored: " + endFloored + ", " + new Date(endFloored));
long diff = endFloored - startFloored;
System.out.println("diff: " + diff);
System.out.println("Integer.MAX_VALUE: " + Integer.MAX_VALUE);
System.out.println((int) diff / MILLIS_IN_ONE_HOUR);
System.out.println(rc.periodBarriersCrossed(start, end));
}