Class DefaultTypeSystemLocalizationHelper

java.lang.Object
com.hybris.backoffice.cockpitng.dataaccess.facades.type.DefaultTypeSystemLocalizationHelper
All Implemented Interfaces:
TypeSystemLocalizationHelper

public class DefaultTypeSystemLocalizationHelper extends Object implements TypeSystemLocalizationHelper
Provides localization for Types & Attributes.

Loads localization for all TypeModel on first localizeType(TypeModel, DataType.Builder) call. All AttributeDescriptorModel localizations are loaded on first localizeAttribute(AttributeDescriptorModel, DataAttribute.Builder)

Localizations are loaded for all UI locales CockpitLocaleService.getAllUILocales().

  • Constructor Details

    • DefaultTypeSystemLocalizationHelper

      public DefaultTypeSystemLocalizationHelper()
  • Method Details

    • localizeAttribute

      public void localizeAttribute(AttributeDescriptorModel attributeDescriptorModel, com.hybris.cockpitng.dataaccess.facades.type.DataAttribute.Builder attrBuilder)
      Description copied from interface: TypeSystemLocalizationHelper
      Provides localization for AttributeDescriptorModel
      Specified by:
      localizeAttribute in interface TypeSystemLocalizationHelper
      Parameters:
      attributeDescriptorModel - attribute to be localized
      attrBuilder - builder that will be updated with localized labels
    • localizeType

      public void localizeType(TypeModel platformType, com.hybris.cockpitng.dataaccess.facades.type.DataType.Builder typeBuilder)
      Description copied from interface: TypeSystemLocalizationHelper
      Provides localization for TypeModel
      Specified by:
      localizeType in interface TypeSystemLocalizationHelper
      Parameters:
      platformType - type to be localized
      typeBuilder - builder that will be updated with localized labels
    • findAttributeLocalization

      protected Map<Locale,String> findAttributeLocalization(AttributeDescriptorModel attributeDescriptor, String attributeName)
    • findTypeLocalization

      protected Map<Locale,String> findTypeLocalization(TypeModel type)
    • loadAttributeLocalization

      protected com.google.common.collect.Table<String,String,com.google.common.collect.Table<String,Locale,String>> loadAttributeLocalization()
    • loadTypeLocalization

      protected com.google.common.collect.Table<String,Locale,String> loadTypeLocalization()
    • loadLocalesMap

      protected Map<String,Locale> loadLocalesMap()
    • getCockpitLocaleService

      protected com.hybris.cockpitng.i18n.CockpitLocaleService getCockpitLocaleService()
    • getFlexibleSearchService

      protected FlexibleSearchService getFlexibleSearchService()
    • setCockpitLocaleService

      public void setCockpitLocaleService(com.hybris.cockpitng.i18n.CockpitLocaleService cockpitLocaleService)
    • setFlexibleSearchService

      public void setFlexibleSearchService(FlexibleSearchService flexibleSearchService)