Java Calendar MILLISECOND
Syntax
Calendar.MILLISECOND has the following syntax.
public static final int MILLISECOND
Example
In the following code shows how to use Calendar.MILLISECOND field.
import java.util.Calendar;
import java.util.GregorianCalendar;
// w w w . j av a 2s .c o m
public class Main {
public static void main(String[] args) {
Calendar cal = new GregorianCalendar();
System.out.println(cal.get(Calendar.MILLISECOND));
}
}
The code above generates the following result.
Home »
Java Tutorial »
java.util »
Java Tutorial »
java.util »