/** * Retrieves the {@link ResourceBundle} for the specified baseName * and locale, if such exists. If the baseName or locale is null * or if the locale argument cannot be converted to a {@link Locale}, * then this will return null. * @param baseName base name * @param loc locale * @return resource bundle */ protected ResourceBundle getBundle(String baseName, Object loc) { Locale locale = (loc == null) ? getLocale() : toLocale(loc); if (baseName == null || locale == null) { return null; } return ResourceBundle.getBundle(baseName, locale); }
Locale locale = (loc == null) ? getLocale() : toLocale(loc); if (locale == null || bundles == null || bundles.length == 0)