BloombergLP::bdlt::CalendarUtil::shiftModifiedFollowingIfValid

Load, into the specified result, the date of the chronologically earliest business day that is on or after the specified original date, unless a date cannot be found in the same month, in which case load the chronologically latest business day before the original date based on the specified calendar. Return 0 on success, and a non-zero value, without modifying *result, if the original date is not within the valid range of calendar or a valid business date cannot be found according to the above algorithm within the valid range of calendar.

Synopsis

Declared in <bdlt_calendarutil.h>

static
int
shiftModifiedFollowingIfValid(
    bdlt::Date* result,
    bdlt::Date const& original,
    bdlt::Calendar const& calendar);