src/org/kocakosm/pitaya/time/Dates.java
public static boolean isSameWeek(Calendar cal1, Calendar cal2)
	{
		return cal1.get(ERA) == cal2.get(ERA)
			&& cal1.get(YEAR) == cal2.get(YEAR)
			&& cal1.get(WEEK_OF_YEAR) == cal2.get(WEEK_OF_YEAR);
	}
public static boolean isSameWeek(Calendar cal1, Calendar cal2)
	{
		return cal1.get(ERA) == cal2.get(ERA)
			&& cal1.get(YEAR) == cal2.get(YEAR)
			&& cal1.get(WEEK_OF_YEAR) == cal2.get(WEEK_OF_YEAR);
	}
Returns whether the given {@code Calendar}s represent the same week.

@param cal1 the first {@code Calendar}.
@param cal2 the second {@code Calendar}.

@return whether the given {@code Calendar}s represent the same week.

@throws NullPointerException if one of the arguments is {@code null}.