Unary minus operators
Synopses
Declared in <bdlt_date.h>
Return a DatetimeInterval object whose value is the negative of the specified time interval value. The behavior is undefined unless INT_MIN < value.days().
bdlt::DatetimeInterval
operator‐(DatetimeInterval const& value);
Return the date that is earlier by numDays from the specified date.
bdlt::Date
operator‐(
Date const& date,
int numDays);
Return the signed number of days between two dates.
int
operator‐(
Date const& lhs,
Date const& rhs);
Return the interval between two datetimes.
bdlt::DatetimeInterval
operator‐(
Datetime const& lhs,
Datetime const& rhs);
Return the difference of a datetime and a datetime interval.
bdlt::Datetime
operator‐(
Datetime const& lhs,
DatetimeInterval const& rhs);
Return the difference of a datetime and a time interval.
bdlt::Datetime
operator‐(
Datetime const& lhs,
bsls::TimeInterval const& rhs);
Return the difference between the specified lhs and rhs intervals.
bdlt::DatetimeInterval
operator‐(
DatetimeInterval const& lhs,
DatetimeInterval const& rhs);
Return a set containing the subtraction of the specified rhs set from the specified lhs set (i.e., a set containing elements that are in lhs, but not in rhs).
bdlt::DayOfWeekSet
operator‐(
DayOfWeekSet const& lhs,
DayOfWeekSet const& rhs);
Return the number of holiday codes between lhs and rhs.
std::ptrdiff_t
operator‐(
PackedCalendar_HolidayCodeConstIterator const& lhs,
PackedCalendar_HolidayCodeConstIterator const& rhs);
Return a Time value that is the difference between the specified lhs time and the specified rhs datetime interval.
bdlt::Time
operator‐(
Time const& lhs,
DatetimeInterval const& rhs);
Return a DatetimeInterval object initialized with the difference between the specified lhs and rhs time values.
bdlt::DatetimeInterval
operator‐(
Time const& lhs,
Time const& rhs);
Return Value
-
the negation of
value -
date earlier by
numDaysfromdate -
number of days from
rhstolhs -
a
DatetimeIntervalthat is the difference between the operands -
a
Datetimethat is the difference of the operands -
the difference between
lhsandrhs -
a set containing the subtraction of
rhsfromlhs -
the number of holiday codes between
lhsandrhs -
a
Timevalue that is the difference oflhsandrhs -
a
DatetimeIntervalinitialized with the difference oflhsandrhs
Parameters
Name |
Description |
value |
time interval to negate |
date |
base date |
numDays |
signed number of days to subtract |
lhs |
left‐hand date operand |
rhs |
right‐hand date operand |
Created with MrDocs