Rolls this interval on a given date.

@param date Date instance to add to
342268
public void add(Date date) {
    final Calendar cal = Calendar.getInstance();
    cal.setTime(date);
    add(cal);
    date.setTime(cal.getTime().getTime());
  }
636136
function(date) {
        var minDate = this.cfg.getProperty(DEF_CFG.MINDATE.key),
            maxDate = this.cfg.getProperty(DEF_CFG.MAXDATE.key),
            dm = DateMath;
        
        if (minDate) {
            minDate = dm.clearTime(minDate);
        } 
        if (maxDate) {
            maxDate = dm.clearTime(maxDate);
        }
    
        var clearedDate = new Date(date.getTime());
        clearedDate = dm.clearTime(clearedDate);
    
        return ((minDate && clearedDate.getTime() < minDate.getTime()) || (maxDate && clearedDate.getTime() > maxDate.getTime()));
    }
1146944
public void setDate(Date date)
    {
        String dateString = "";
        if (date != null)
    		dateString = dateFormat.format(date);
        jTextField2.setText(dateString);
        jCalendarButton1.setTargetDate(date);
    }
58235
public void setDate(final Date date) {
		if (date == null) {
			setPartialDate(null, null, null);
		} else {
			Calendar cal = Calendar.getInstance();
			cal.setTime(date);
			Integer year = cal.get(Calendar.YEAR);
			Integer month = cal.get(Calendar.MONTH) + 1;
			Integer day = cal.get(Calendar.DAY_OF_MONTH);
			setPartialDate(day, month, year);
		}
	}
764971
public static Date add(DateUnit dateUnit, int amount, Date date) {
        return Date.from(date.toInstant().plus(amount, create(dateUnit)));
    }
1104088
public final void setCurrentBalanceDate(final Date pCurrentBalanceDate) {
    if (pCurrentBalanceDate == null) {
      this.currentBalanceDate = null;
    } else {
      this.currentBalanceDate = new Date(pCurrentBalanceDate.getTime());
    }
  }
684248
private void setCorrectDay(Calendar date) {

        if (monthHasNotDay(date)) {
            date.set(Calendar.DAY_OF_MONTH, date.getActualMaximum(Calendar.DAY_OF_MONTH));
        } else {
            date.set(Calendar.DAY_OF_MONTH, m_dayOfMonth);
        }
    }
542567
public void setDate(Date date) {
		for (int i = 0; i < 4; i++) {
			((JDateChooser) components[i]).setDate(date);
		}
	}
1290751
function(date) {
        var tooEarly = this.minDate && date < this.minDate,
            tooLate = this.maxDate && date > this.maxDate;

        if (this.method == 'between') {
            if (tooEarly)
                return true;
            if (tooLate)
                return false;
        } else if (this.method == 'before') {
            if (tooLate)
                return false;
        } else if (this.method == 'after') {
            if (tooEarly)
                return true;
            this.add(date);
            return false;
        }

        return this.add(date);

    }
191079
public final boolean add(final Date date) {
        if (!this.isUtc() && this.getTimeZone() == null) {
            /* If list hasn't been initialized yet use defaults from the first added date element */
            if (date instanceof DateTime) {
                DateTime dateTime = (DateTime) date;
                if (dateTime.isUtc()) {
                    this.setUtc(true);
                } else {
                    this.setTimeZone(dateTime.getTimeZone());
                }
            }
        }
        if (date instanceof DateTime) {
            DateTime dateTime = (DateTime) date;
            if (isUtc()) {
                dateTime.setUtc(true);
            } else {
                dateTime.setTimeZone(getTimeZone());
            }
        } else if (!Value.DATE.equals(getType())) {
            final DateTime dateTime = new DateTime(date);
            dateTime.setTimeZone(getTimeZone());
            return dates.add(dateTime);
        }
        return dates.add(date);
    }
474246
public static Date offsetDate(Date date, int calendarUnit, int dateOffset) {
        if (date == null) {
            return null;
        }

        Calendar ca = Calendar.getInstance();
        ca.setTime(date);
        ca.add(calendarUnit, dateOffset);

        return ca.getTime();
    }
361774
protected void setDate(Date date, boolean firePropertyChange) {
		Date oldDate = this.date;
		this.date = date;

		if (date == null) {
			setText("");
		} else {
			String formattedDate = dateFormatter.format(date);
			try {
				setText(formattedDate);
			} catch (RuntimeException e) {
				e.printStackTrace();
			}
		}
		if (date != null && dateUtil.checkDate(date)) {
			setForeground(Color.BLACK);

		}

		if (firePropertyChange) {
			firePropertyChange("date", oldDate, date);
		}
	}
1250870
private static Date rollGetDate(Calendar calendar, int days) {
		Calendar easterSunday = (Calendar) calendar.clone();
		easterSunday.add(Calendar.DATE, days);
		return easterSunday.getTime();
	}
582944
public void setDate(Date date) {
		Date oldDate = calendar.getTime();
		calendar.setTime(date);
		int year = calendar.get(Calendar.YEAR);
		int month = calendar.get(Calendar.MONTH);
		int day = calendar.get(Calendar.DAY_OF_MONTH);

		yearChooser.setYear(year);
		monthChooser.setMonth(month);
		dayChooser.setCalendar(calendar);
		dayChooser.setDay(day);

		firePropertyChange("date", oldDate, date);
	}
223999
public void setExpirationDateString(String date) throws ParseException {
        if (StringUtils.isBlank(date)) {
            expirationDate = null;
            return;
        }

        expirationDate = dateFormat.parse(date);
    }
241927
private Date addDays(final Date date, final int days) {
        final Calendar cal = Calendar.getInstance();
        cal.setTime(date);
        cal.add(Calendar.DATE, days); //minus number would decrement the days
        return cal.getTime();
    }
771159
def rollforward(self, date):
        """"""
        if self.onOffset(date):
            return date
        else:
            return date + QuarterEnd(month=self.month)