java 获取当前年度

比较简单的一种写法:

String.valueOf(Calendar.getInstance().get(Calendar.YEAR));

输出为:2019

猜你喜欢

转载自www.cnblogs.com/shangyangyang/p/11392421.html