Interface LanguageLabelContainer

  • All Superinterfaces:
    All Known Subinterfaces:
    FormLanguageLabelContainer, WebsiteLanguageLabelContainer

    public interface LanguageLabelContainer
    extends Identifiable
    Website and language specific container for language labels. Several containers exist: one system-wide container per locale, which can be identified by its website id being -1 and several website- and locale-specific containers which contain only overridden language labels that were edited via the user interface.
    • Method Detail

      • getLocale

        String getLocale()
        The locale assigned to this container. For example en_US.
        the locale for which this container contains language labels
      • setLocale

        void setLocale​(String locale)
        Sets the locale for this language label container
        locale - the string representation of the locale
      • getLanguageLabels

        List<LanguageLabel> getLanguageLabels()
        The list of all language labels in this container
        the list of all language labels in this container
      • setLanguageLabels

        void setLanguageLabels​(List<LanguageLabel> languageLabels)
        Sets the list of LanguageLabels in this container.
        languageLabels - the list of LanguageLabels in this container
      • getLanguageLabel

        LanguageLabel getLanguageLabel​(String key)
        Returns the language label matching the given key.
        key - the key to lookup
        The LanguageLabel, or null if the key didn't match anything.
      • addOrUpdateLanguageLabel

        LanguageLabel addOrUpdateLanguageLabel​(String key,
                                               String value)
        Creates a new language label or updates an existing one with the specified key an value.
        key - the key of the language label to update or to create
        value - the value of the language label to update or to create
        the language label in question