Here you can find the source of getDateAdd(Date date, int amount)
public static Date getDateAdd(Date date, int amount)
//package com.java2s; import java.util.Calendar; import java.util.Date; import java.util.GregorianCalendar; public class Main { public static Date getDateAdd(Date date, int amount) { Calendar cal = new GregorianCalendar(); cal.setTime(date);/*from w w w .j av a2s .c om*/ cal.add(GregorianCalendar.DATE, amount); return cal.getTime(); } }