public static long getMinutesDifference(Date startDate, Date endDate) {
		long startTime = startDate.getTime();
		long endTime = endDate.getTime();
		long diffTime = endTime - startTime;
		long diffInMinutes = TimeUnit.MILLISECONDS.toMinutes(diffTime);
		return diffInMinutes;
	}
public static long getMinutesDifference ( Date startDate , Date endDate ) { long startTime = startDate . getTime ( ) ; long endTime = endDate . getTime ( ) ; long diffTime = endTime - startTime ; long diffInMinutes = TimeUnit . MILLISECONDS . toMinutes ( diffTime ) ; return diffInMinutes ; }
Gets the minutes difference.

@param startDate the start date
@param endDate   the end date
@return the minutes difference