Here you can find the source of addDays2Date(Date d, int days)
public static Date addDays2Date(Date d, int days)
//package com.java2s; //License from project: Open Source License import java.util.Calendar; import java.util.Date; public class Main { private static final Calendar calendar = Calendar.getInstance(); public static Date addDays2Date(Date d, int days) { calendar.clear();/*from w ww . jav a 2 s .c o m*/ calendar.setTime(d); calendar.add(Calendar.DAY_OF_MONTH, days); return calendar.getTime(); } }