Duration - 無(wú)創(chuàng)建接口,會(huì)在Integer類(lèi)型數(shù)據(jù)調(diào)用日期/時(shí)間類(lèi)型數(shù)據(jù)時(shí)返回
定義Duration:<Integer>.years;
<Integer>.months;
<Integer>.days;
<Integer>.hours;
<Integer>.minutes;
例:
> Date date = "2019-01-01" > date = date + 1.months //返回:2019-02-01