MCPcopy Create free account
hub / github.com/apache/impala / AddDays

Method AddDays

be/src/runtime/date-value.cc:314–321  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

312}
313
314DateValue DateValue::AddDays(int64_t days) const {
315 if (UNLIKELY(!IsValid()
316 || days < MIN_DAYS_SINCE_EPOCH - days_since_epoch_
317 || days > MAX_DAYS_SINCE_EPOCH - days_since_epoch_)) {
318 return DateValue();
319 }
320 return DateValue(days_since_epoch_ + days);
321}
322
323DateValue DateValue::AddMonths(int64_t months, bool keep_last_day) const {
324 if (UNLIKELY(!IsValid())) return DateValue();

Callers 7

NextDayMethod · 0.80
AddSubDaysMethod · 0.80
AddSubWeeksMethod · 0.80
GoBackToWeekdayFunction · 0.80
TESTFunction · 0.80
CheckOverlapForDateFunction · 0.80
InsertForGTMethod · 0.80

Calls 1

DateValueClass · 0.70

Tested by 2

TESTFunction · 0.64
CheckOverlapForDateFunction · 0.64