예제 #1
0
  /**
   * Returns the language ID of the locale of this service context's current user.
   *
   * @return the language ID
   */
  public String getLanguageId() {
    if (_languageId != null) {
      return _languageId;
    }

    return LocaleUtil.toLanguageId(LocaleUtil.getMostRelevantLocale());
  }
예제 #2
0
  public Locale getLocale() {
    Locale locale = (Locale) _attributes.get(LOCALE);

    if (locale == null) {
      locale = LocaleUtil.getMostRelevantLocale();
    }

    return locale;
  }
예제 #3
0
 @Override
 public String getDescriptiveName() throws PortalException {
   return getDescriptiveName(LocaleUtil.getMostRelevantLocale());
 }