Here you can find the source of getDateAfter(Date d, int day)
public static Date getDateAfter(Date d, int day)
//package com.java2s; import java.util.Calendar; import java.util.Date; public class Main { public static Date getDateAfter(Date d, int day) { Calendar now = Calendar.getInstance(); now.setTime(d);// www .j a v a2 s . co m now.set(Calendar.DATE, now.get(Calendar.DATE) + day); return now.getTime(); } }