< prev index next >

src/java.base/share/classes/java/text/DateFormatSymbols.java

Print this page




 145      * @exception  java.util.MissingResourceException
 146      *             if the resources for the specified locale cannot be
 147      *             found or cannot be loaded.
 148      */
 149     public DateFormatSymbols(Locale locale)
 150     {
 151         initializeData(locale);
 152     }
 153 
 154     /**
 155      * Constructs an uninitialized DateFormatSymbols.
 156      */
 157     private DateFormatSymbols(boolean flag) {
 158     }
 159 
 160     /**
 161      * Era strings. For example: "AD" and "BC".  An array of 2 strings,
 162      * indexed by <code>Calendar.BC</code> and <code>Calendar.AD</code>.
 163      * @serial
 164      */
 165     String eras[] = null;
 166 
 167     /**
 168      * Month strings. For example: "January", "February", etc.  An array
 169      * of 13 strings (some calendars have 13 months), indexed by
 170      * <code>Calendar.JANUARY</code>, <code>Calendar.FEBRUARY</code>, etc.
 171      * @serial
 172      */
 173     String months[] = null;
 174 
 175     /**
 176      * Short month strings. For example: "Jan", "Feb", etc.  An array of
 177      * 13 strings (some calendars have 13 months), indexed by
 178      * <code>Calendar.JANUARY</code>, <code>Calendar.FEBRUARY</code>, etc.
 179 
 180      * @serial
 181      */
 182     String shortMonths[] = null;
 183 
 184     /**
 185      * Weekday strings. For example: "Sunday", "Monday", etc.  An array
 186      * of 8 strings, indexed by <code>Calendar.SUNDAY</code>,
 187      * <code>Calendar.MONDAY</code>, etc.
 188      * The element <code>weekdays[0]</code> is ignored.
 189      * @serial
 190      */
 191     String weekdays[] = null;
 192 
 193     /**
 194      * Short weekday strings. For example: "Sun", "Mon", etc.  An array
 195      * of 8 strings, indexed by <code>Calendar.SUNDAY</code>,
 196      * <code>Calendar.MONDAY</code>, etc.
 197      * The element <code>shortWeekdays[0]</code> is ignored.
 198      * @serial
 199      */
 200     String shortWeekdays[] = null;
 201 
 202     /**
 203      * AM and PM strings. For example: "AM" and "PM".  An array of
 204      * 2 strings, indexed by <code>Calendar.AM</code> and
 205      * <code>Calendar.PM</code>.
 206      * @serial
 207      */
 208     String ampms[] = null;
 209 
 210     /**
 211      * Localized names of time zones in this locale.  This is a
 212      * two-dimensional array of strings of size <em>n</em> by <em>m</em>,
 213      * where <em>m</em> is at least 5.  Each of the <em>n</em> rows is an
 214      * entry containing the localized names for a single <code>TimeZone</code>.
 215      * Each such row contains (with <code>i</code> ranging from
 216      * 0..<em>n</em>-1):
 217      * <ul>
 218      * <li><code>zoneStrings[i][0]</code> - time zone ID</li>
 219      * <li><code>zoneStrings[i][1]</code> - long name of zone in standard
 220      * time</li>
 221      * <li><code>zoneStrings[i][2]</code> - short name of zone in
 222      * standard time</li>
 223      * <li><code>zoneStrings[i][3]</code> - long name of zone in daylight
 224      * saving time</li>
 225      * <li><code>zoneStrings[i][4]</code> - short name of zone in daylight
 226      * saving time</li>
 227      * </ul>
 228      * The zone ID is <em>not</em> localized; it's one of the valid IDs of
 229      * the {@link java.util.TimeZone TimeZone} class that are not
 230      * <a href="../util/TimeZone.html#CustomID">custom IDs</a>.
 231      * All other entries are localized names.
 232      * @see java.util.TimeZone
 233      * @serial
 234      */
 235     String zoneStrings[][] = null;
 236 
 237     /**
 238      * Indicates that zoneStrings is set externally with setZoneStrings() method.
 239      */
 240     transient boolean isZoneStringsSet = false;
 241 
 242     /**
 243      * Unlocalized date-time pattern characters. For example: 'y', 'd', etc.
 244      * All locales use the same these unlocalized pattern characters.
 245      */
 246     static final String  patternChars = "GyMdkHmsSEDFwWahKzZYuXL";
 247 
 248     static final int PATTERN_ERA                  =  0; // G
 249     static final int PATTERN_YEAR                 =  1; // y
 250     static final int PATTERN_MONTH                =  2; // M
 251     static final int PATTERN_DAY_OF_MONTH         =  3; // d
 252     static final int PATTERN_HOUR_OF_DAY1         =  4; // k
 253     static final int PATTERN_HOUR_OF_DAY0         =  5; // H
 254     static final int PATTERN_MINUTE               =  6; // m
 255     static final int PATTERN_SECOND               =  7; // s




 145      * @exception  java.util.MissingResourceException
 146      *             if the resources for the specified locale cannot be
 147      *             found or cannot be loaded.
 148      */
 149     public DateFormatSymbols(Locale locale)
 150     {
 151         initializeData(locale);
 152     }
 153 
 154     /**
 155      * Constructs an uninitialized DateFormatSymbols.
 156      */
 157     private DateFormatSymbols(boolean flag) {
 158     }
 159 
 160     /**
 161      * Era strings. For example: "AD" and "BC".  An array of 2 strings,
 162      * indexed by <code>Calendar.BC</code> and <code>Calendar.AD</code>.
 163      * @serial
 164      */
 165     String[] eras = null;
 166 
 167     /**
 168      * Month strings. For example: "January", "February", etc.  An array
 169      * of 13 strings (some calendars have 13 months), indexed by
 170      * <code>Calendar.JANUARY</code>, <code>Calendar.FEBRUARY</code>, etc.
 171      * @serial
 172      */
 173     String[] months = null;
 174 
 175     /**
 176      * Short month strings. For example: "Jan", "Feb", etc.  An array of
 177      * 13 strings (some calendars have 13 months), indexed by
 178      * <code>Calendar.JANUARY</code>, <code>Calendar.FEBRUARY</code>, etc.
 179 
 180      * @serial
 181      */
 182     String[] shortMonths = null;
 183 
 184     /**
 185      * Weekday strings. For example: "Sunday", "Monday", etc.  An array
 186      * of 8 strings, indexed by <code>Calendar.SUNDAY</code>,
 187      * <code>Calendar.MONDAY</code>, etc.
 188      * The element <code>weekdays[0]</code> is ignored.
 189      * @serial
 190      */
 191     String[] weekdays = null;
 192 
 193     /**
 194      * Short weekday strings. For example: "Sun", "Mon", etc.  An array
 195      * of 8 strings, indexed by <code>Calendar.SUNDAY</code>,
 196      * <code>Calendar.MONDAY</code>, etc.
 197      * The element <code>shortWeekdays[0]</code> is ignored.
 198      * @serial
 199      */
 200     String[] shortWeekdays = null;
 201 
 202     /**
 203      * AM and PM strings. For example: "AM" and "PM".  An array of
 204      * 2 strings, indexed by <code>Calendar.AM</code> and
 205      * <code>Calendar.PM</code>.
 206      * @serial
 207      */
 208     String[] ampms = null;
 209 
 210     /**
 211      * Localized names of time zones in this locale.  This is a
 212      * two-dimensional array of strings of size <em>n</em> by <em>m</em>,
 213      * where <em>m</em> is at least 5.  Each of the <em>n</em> rows is an
 214      * entry containing the localized names for a single <code>TimeZone</code>.
 215      * Each such row contains (with <code>i</code> ranging from
 216      * 0..<em>n</em>-1):
 217      * <ul>
 218      * <li><code>zoneStrings[i][0]</code> - time zone ID</li>
 219      * <li><code>zoneStrings[i][1]</code> - long name of zone in standard
 220      * time</li>
 221      * <li><code>zoneStrings[i][2]</code> - short name of zone in
 222      * standard time</li>
 223      * <li><code>zoneStrings[i][3]</code> - long name of zone in daylight
 224      * saving time</li>
 225      * <li><code>zoneStrings[i][4]</code> - short name of zone in daylight
 226      * saving time</li>
 227      * </ul>
 228      * The zone ID is <em>not</em> localized; it's one of the valid IDs of
 229      * the {@link java.util.TimeZone TimeZone} class that are not
 230      * <a href="../util/TimeZone.html#CustomID">custom IDs</a>.
 231      * All other entries are localized names.
 232      * @see java.util.TimeZone
 233      * @serial
 234      */
 235     String[][] zoneStrings = null;
 236 
 237     /**
 238      * Indicates that zoneStrings is set externally with setZoneStrings() method.
 239      */
 240     transient boolean isZoneStringsSet = false;
 241 
 242     /**
 243      * Unlocalized date-time pattern characters. For example: 'y', 'd', etc.
 244      * All locales use the same these unlocalized pattern characters.
 245      */
 246     static final String  patternChars = "GyMdkHmsSEDFwWahKzZYuXL";
 247 
 248     static final int PATTERN_ERA                  =  0; // G
 249     static final int PATTERN_YEAR                 =  1; // y
 250     static final int PATTERN_MONTH                =  2; // M
 251     static final int PATTERN_DAY_OF_MONTH         =  3; // d
 252     static final int PATTERN_HOUR_OF_DAY1         =  4; // k
 253     static final int PATTERN_HOUR_OF_DAY0         =  5; // H
 254     static final int PATTERN_MINUTE               =  6; // m
 255     static final int PATTERN_SECOND               =  7; // s


< prev index next >