Month SEPTEMBER
defines the singleton instance
for the month of September with 30 days.
This has the numeric value of 9.
SEPTEMBER
has the following syntax.
public static final Month SEPTEMBER
The following example shows how to use SEPTEMBER
.
import java.time.Month; //from w w w .j a va 2 s . c o m public class Main { public static void main(String[] args) { Month m = Month.SEPTEMBER; System.out.println(m.getValue()); System.out.println(m.name()); System.out.println(m.ordinal()); } }
The code above generates the following result.