Class ExtraDateStrings
java.lang.Object
com.github.lgooddatepicker.zinternaltools.ExtraDateStrings
ExtraDateStrings, This class holds extra date strings. This includes: # Formats for parsing dates
in a particular language. # Overridden month names for particular locales. All the fields and
functions are static.
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final String[]
monthsNamesForLanguage_ru, This is a constant list of "standalone" month names, for the Russian locale. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic String[]
getDefaultStandaloneLongMonthNamesForLocale, This will return a list of capitalized, translated, standalone month names for the specified locale.static String[]
static ArrayList
<DateTimeFormatter> getExtraParsingFormatsForLocale, This will return a list of extra parsing formatters for the specified locale.static String[]
getFormattingMonthNamesArray
(Locale locale, boolean capitalize, boolean shortVersion) getFormattingMonthNamesArray, This returns an array with the translated, formatting version of the month names for the specified locale.
-
Field Details
-
monthsNamesForLanguage_ru
monthsNamesForLanguage_ru, This is a constant list of "standalone" month names, for the Russian locale. This was previously used to supply the Russian month names, but now that this class has a generalized solution for getting the standalone month names in all languages, this array should only be used for visual reference. This can be used for comparison to ensure that the general solution is functioning correctly.
-
-
Constructor Details
-
ExtraDateStrings
public ExtraDateStrings()
-
-
Method Details
-
getExtraParsingFormatsForLocale
getExtraParsingFormatsForLocale, This will return a list of extra parsing formatters for the specified locale. If no extra formatters are found, then this will return an empty list. (This will never return null.) -
getDefaultStandaloneLongMonthNamesForLocale
getDefaultStandaloneLongMonthNamesForLocale, This will return a list of capitalized, translated, standalone month names for the specified locale. This function will always return a list with 12 elements, and each element will always contain a string. This will never return a null array, or any null elements. Implementation note: it was previously required to override the month names in certain languages such as Russian, to get the proper grammar. At this point, a generalized solution has been implemented for all languages. It is assumed that this solution is working correctly, unless and until someone reports that it is not working correctly for their language. -
getDefaultStandaloneShortMonthNamesForLocale
-
getFormattingMonthNamesArray
public static String[] getFormattingMonthNamesArray(Locale locale, boolean capitalize, boolean shortVersion) getFormattingMonthNamesArray, This returns an array with the translated, formatting version of the month names for the specified locale. (The "formatting version" of the month names can be different from the standalone version in some locales, including Russian and Czech. The formatting version would be used in a formatted date, and the standalone version would be used if the month is being specified by itself.) capitalize: This specifies whether the month name should be capitalized or not capitalized. shortVersion: This specifies whether the month names should be the short, or long versions of the formatting month names.
-