java.time.YearMonth.plus(TemporalAmount amountToAdd)


java.time.YearMonth.plus(TemporalAmount amountToAdd)

package com.codingdict;

import java.time.Period;
import java.time.YearMonth;

public class YearMonthDemo {
   public static void main(String[] args) {

      YearMonth date = YearMonth.parse("2017-12");
      YearMonth date1 = date.plus(Period.of(10,0,0));
      System.out.println(date1);  
   }
}