Here you can find the source of add(Date date, long minutes)
public static Date add(Date date, long minutes)
//package com.java2s; import java.util.Calendar; import java.util.Date; public class Main { public static final int MINUTE = 2; public static Date add(Date date, long minutes) { if (date == null) { throw new IllegalArgumentException(); }/* w w w . j a va 2 s . c o m*/ return addMinutes(date, minutes); } public static java.util.Date addMinutes(java.util.Date date, long... minutes) { if (minutes == null) { return date; } java.util.Calendar c = java.util.Calendar.getInstance(); c.setTime(date); for (long minute : minutes) { c.add(Calendar.MINUTE, (int) minute); } return c.getTime(); } public static Date addMinutes(Date date, long minutes) { Calendar c = Calendar.getInstance(); c.setTimeInMillis(getMillis(date) + ((long) minutes) * 60 * 1000); return c.getTime(); } public static long getMillis(Date date) { Calendar c = Calendar.getInstance(); c.setTime(date); return c.getTimeInMillis(); } }