code: private List<Locale> checkLocaleNames(List<Locale> locales) {
  
          if (locales == null) {
              return null;
          }
          List<Locale> result = new ArrayList<Locale>();
          Iterator<Locale> i = locales.iterator();
          while (i.hasNext()) {
              Locale locale = i.next();
              if (m_availableLocales.contains(locale)) {
                  result.add(locale);
              }
          }
          return result;
      }
docs: Returns a list of available locale names derived from the given locale names.<p>
  
  Each name in the given list is checked against the internal hash map of allowed locales,
  and is appended to the resulting list only if the locale exists.<p>
  
  @param locales List of locales to check
  @return list of available locales derived from the given locale names