* Get all locales that your application supports, all the bundles that you have provided.
* @return supported locales
*/
public Collection<Locale> getSupportedLocales() {
Set<Locale> supportedLocales = new HashSet<Locale>();
final TranslationService translationService = TemplateUtil.getTranslationService();
final Collection<String> locales = translationService.getSupportedLocales();
for (String localeKey : locales) {
localeKey = localeKey == null ? DEFAULT : localeKey;
supportedLocales.add(new Locale(localeKey, translationService.getTranslation(localeKey)));
}
return supportedLocales;
}