78 |
static final long serialVersionUID = -8125100834729963327L; |
static final long serialVersionUID = -8125100834729963327L; |
79 |
|
|
80 |
/** |
/** |
81 |
* The name of the resource bundle. |
* The name of the resource bundle. Used only by getBundle() |
82 |
*/ |
*/ |
83 |
private static final String bundleName = "gnu.java.locale.Calendar"; |
private static final String bundleName = "gnu.java.locale.Calendar"; |
84 |
|
|
85 |
/** |
/** |
86 |
|
* get resource bundle: |
87 |
|
* The resources should be loaded via this method only. Iff an application |
88 |
|
* uses this method, the resourcebundle is required. --Fridi. |
89 |
|
*/ |
90 |
|
private static ResourceBundle getBundle(Locale locale) |
91 |
|
{ |
92 |
|
return ResourceBundle.getBundle(bundleName, locale); |
93 |
|
} |
94 |
|
|
95 |
|
/** |
96 |
* Constructs a new GregorianCalender representing the current |
* Constructs a new GregorianCalender representing the current |
97 |
* time, using the default time zone and the default locale. |
* time, using the default time zone and the default locale. |
98 |
*/ |
*/ |
130 |
public GregorianCalendar(TimeZone zone, Locale locale) |
public GregorianCalendar(TimeZone zone, Locale locale) |
131 |
{ |
{ |
132 |
super(zone, locale); |
super(zone, locale); |
133 |
ResourceBundle rb = ResourceBundle.getBundle(bundleName, locale); |
ResourceBundle rb = getBundle(locale); |
134 |
gregorianCutover = ((Date) rb.getObject("gregorianCutOver")).getTime(); |
gregorianCutover = ((Date) rb.getObject("gregorianCutOver")).getTime(); |
135 |
setTimeInMillis(System.currentTimeMillis()); |
setTimeInMillis(System.currentTimeMillis()); |
136 |
} |
} |