Class ProductConfigRulesSetup

  • Direct Known Subclasses:
    ProductConfigRulesCPSSetup

    @SystemSetup(extension="sapproductconfigrules")
    public class ProductConfigRulesSetup
    extends AbstractSystemSetup
    This Setup implementation loads multiple language files for the CPQ rules implementation. It is expected, that the language files are delivered as properties file, following the file name format sapproductconfigrules-impexsupport_[two character language code].properties, and are placed in the resources/localization folder. The properties files are used as parameter sets for the essential Impex file ( essentialdata-sapproductconfigrules_languages.impex).
    • Constructor Detail

      • ProductConfigRulesSetup

        public ProductConfigRulesSetup()
    • Method Detail

      • processEssentialFiles

        @SystemSetup(type=ESSENTIAL,
                     process=ALL)
        public void processEssentialFiles​(SystemSetupContext context)
        The method processes first the base definitions for the CPQ rules, and updates the definitions values with the language specific property files. Each language property file will trigger an import for the language essential Impex.
        Parameters:
        context - System context, provided by the initialize or update run
      • getBasedir

        protected java.lang.String getBasedir()
      • getImpexParameterMap

        protected ImpexMacroParameterData getImpexParameterMap​(SystemSetupContext context,
                                                               java.nio.file.Path localeFile,
                                                               java.util.Map<java.lang.String,​java.lang.String> defaultParameters)
      • getPropertyFileAsMap

        protected java.util.Map<java.lang.String,​java.lang.String> getPropertyFileAsMap​(SystemSetupContext context,
                                                                                              java.nio.file.Path localeFile)
      • extractLocaleOutOfFileName

        protected java.lang.String extractLocaleOutOfFileName​(java.lang.String fileName)
      • getListOfLanguageFiles

        protected java.util.List<java.nio.file.Path> getListOfLanguageFiles​(java.lang.String basedir,
                                                                            SystemSetupContext context)
      • getLocaleFileRegex

        protected java.lang.String getLocaleFileRegex()
      • getLocaleFileLanguageRegex

        protected java.lang.String getLocaleFileLanguageRegex()
      • getExtensionName

        protected java.lang.String getExtensionName()
      • setFlexibleSearchService

        public void setFlexibleSearchService​(FlexibleSearchService flexibleSearchService)
      • setImpexImporter

        public void setImpexImporter​(ImpExSystemSetup impexImporter)