xs.yearMonthDuration.subtract( value as xs.yearMonthDuration ) as xs.yearMonthDuration
Subtracts one xs.yearMonthDuration from another. Returns an xs.yearMonthDuration.
Parameters | |
---|---|
value | A year month duration. |
const v1 = xs.yearMonthDuration("P3Y7M"); const v2 = xs.yearMonthDuration("P1Y4M"); v1.subtract(v2)