|
Time\Duration::negateReturns the duration with the opposite sign Description
public Time\Duration Time\Duration::negate()
Returns a duration of the same length with the opposite sign: a positive duration becomes negative, and a negative duration becomes positive. Negating a duration of zero returns a duration of zero, which is never negative. ParametersThis function has no parameters. Return ValuesReturns a new Time\Duration object. ExamplesExample #1 Time\Duration::negate example The above example will output: bool(true) bool(false) bool(false) See Also
|