GregorianCalendar.GregorianCalendar

GregorianCalendar.GregorianCalendar

Class Overview | Class Members | This Package | All Packages

Syntax 1
public GregorianCalendar()
Description
Constructs a default GregorianCalendar using the current time in the default time zone with the default locale.



Syntax 2
public GregorianCalendar( TimeZone zone )
Parameters
zone
the given time zone.
Description
Constructs a GregorianCalendar based on the current time in the given time zone with the default locale.



Syntax 3
public GregorianCalendar( Locale aLocale )
Parameters
aLocale
the given locale.
Description
Constructs a GregorianCalendar based on the current time in the default time zone with the given locale.



Syntax 4
public GregorianCalendar( TimeZone zone, Locale aLocale )
Parameters
zone
the given time zone.
aLocale
the given locale.
Description
Constructs a GregorianCalendar based on the current time in the given time zone with the given locale.



Syntax 5
public GregorianCalendar( int year, int month, int date )
Parameters
year
the value used to set the YEAR time field in the calendar.
month
the value used to set the MONTH time field in the calendar. Month value is 0-based. e.g., 0 for January.
date
the value used to set the DATE time field in the calendar.
Description
Constructs a GregorianCalendar with the given date set in the default time zone with the default locale.



Syntax 6
public GregorianCalendar( int year, int month, int date, int hour, int minute )
Parameters
year
the value used to set the YEAR time field in the calendar.
month
the value used to set the MONTH time field in the calendar. Month value is 0-based. e.g., 0 for January.
date
the value used to set the DATE time field in the calendar.
hour
the value used to set the HOUR_OF_DAY time field in the calendar.
minute
the value used to set the MINUTE time field in the calendar.
Description
Constructs a GregorianCalendar with the given date and time set for the default time zone with the default locale.



Syntax 7
public GregorianCalendar( int year, int month, int date, int hour, int minute, int second )
Parameters
year
the value used to set the YEAR time field in the calendar.
month
the value used to set the MONTH time field in the calendar. Month value is 0-based. e.g., 0 for January.
date
the value used to set the DATE time field in the calendar.
hour
the value used to set the HOUR_OF_DAY time field in the calendar.
minute
the value used to set the MINUTE time field in the calendar.
second
the value used to set the SECOND time field in the calendar.
Description
Constructs a GregorianCalendar with the given date and time set for the default time zone with the default locale.