List of usage examples for java.time YearMonth now
public static YearMonth now()
From source file:Main.java
public static void main(String[] args) { YearMonth y = YearMonth.now(); System.out.println(y.lengthOfMonth()); }
From source file:Main.java
public static void main(String[] args) { YearMonth y = YearMonth.now(); int m = y.getMonthValue(); System.out.println(m); }
From source file:Main.java
public static void main(String[] args) { YearMonth y = YearMonth.now(); System.out.println(y); }
From source file:Main.java
public static void main(String[] args) { YearMonth y = YearMonth.now(); int m = y.getYear(); System.out.println(m); }
From source file:Main.java
public static void main(String[] args) { YearMonth y = YearMonth.now(); YearMonth s = y.plusMonths(3); System.out.println(s); }
From source file:Main.java
public static void main(String[] args) { YearMonth y = YearMonth.now(); System.out.println(y.lengthOfYear()); }
From source file:Main.java
public static void main(String[] args) { YearMonth y = YearMonth.now(); YearMonth s = y.withYear(2013); System.out.println(s); }
From source file:Main.java
public static void main(String[] args) { YearMonth y = YearMonth.now(); YearMonth s = y.minusMonths(12); System.out.println(s); }
From source file:Main.java
public static void main(String[] args) { YearMonth y = YearMonth.now(); YearMonth s = y.minusYears(12); System.out.println(s); }
From source file:Main.java
public static void main(String[] args) { YearMonth y = YearMonth.now(); System.out.println(y.isLeapYear()); }