java.time.YearMonth.now() 方法示例 java.time.YearMonth.minusYears() 方法示例 java.time.YearMonth.now(Clock clock) java.time.YearMonth.now() 方法示例 package com.codingdict; import java.time.YearMonth; public class YearMonthDemo { public static void main(String[] args) { YearMonth date = YearMonth.now(); System.out.println(date); } } java.time.YearMonth.minusYears() 方法示例 java.time.YearMonth.now(Clock clock)