Duration.subtractFrom

Subtracts this duration from the specified temporal object. !(p) This returns a temporal object of the same observable type as the input with this duration subtracted. !(p) In most cases, it is clearer to reverse the calling pattern by using {@link Temporal#minus(TemporalAmount)}. !(pre) // these two lines are equivalent, but the second approach is recommended dateTime = thisDuration.subtractFrom(dateTime); dateTime = dateTime.minus(thisDuration); </pre> !(p) The calculation will subtract the seconds, then nanos. Only non-zero amounts will be added. !(p) This instance is immutable and unaffected by this method call.

@param temporal the temporal object to adjust, not null @return an object of the same type with the adjustment made, not null @throws DateTimeException if unable to subtract @throws ArithmeticException if numeric overflow occurs

class Duration
override
subtractFrom

Meta