Date.clamp

If date is prior to min_date, sets date equal to min_date. If date falls after max_date, sets date equal to max_date. Otherwise, date is unchanged. Either of min_date and max_date may be NULL. All non-NULL dates must be valid.

class Date
void
clamp

Parameters

minDate Date

minimum accepted value for date

maxDate Date

maximum accepted value for date