Class DefaultConfigurationPersistingStrategy<CONFIG extends UIComponentConfiguration,JAXBCLASS>

java.lang.Object
de.hybris.platform.cockpit.services.config.impl.DefaultConfigurationPersistingStrategy<CONFIG,JAXBCLASS>
All Implemented Interfaces:
ConfigurationPersistingStrategy<CONFIG>
Direct Known Subclasses:
AdvancedSearchConfigurationPersistingStrategy, DashboardPersistingStrategy, EditorConfigurationPersistingStrategy, ListViewConfigurationPersistingStrategy

public class DefaultConfigurationPersistingStrategy<CONFIG extends UIComponentConfiguration,JAXBCLASS> extends Object implements ConfigurationPersistingStrategy<CONFIG>
  • Constructor Details

    • DefaultConfigurationPersistingStrategy

      public DefaultConfigurationPersistingStrategy()
  • Method Details

    • updateJaxb

      public JAXBCLASS updateJaxb(CONFIG configuration)
      Converts/updates given configuration to the corresponding JAXB class - this method must be overriden by subclass!
      Parameters:
      configuration - the java configuration
      Returns:
      the corresponding JAXB class
    • persistComponentConfiguration

      public void persistComponentConfiguration(CONFIG configuration, UserModel user, ObjectTemplate objectTemplate, String code)
      Description copied from interface: ConfigurationPersistingStrategy
      Stores the configuration according to the strategy implementation
      Specified by:
      persistComponentConfiguration in interface ConfigurationPersistingStrategy<CONFIG extends UIComponentConfiguration>
      Parameters:
      configuration - the configuration to store
      user - the user the configuration should be valid for
      objectTemplate - the object template the configuration should be valid for
      code - the component code of the configuration
    • checkPermissions

      protected boolean checkPermissions(UserModel user)
    • storeConfigurationMedia

      protected void storeConfigurationMedia(PrincipalModel principal, String xmlContent, String code, String objectTemplateCode, String factoryBeanId)
    • getComponentClass

      public Class<CONFIG> getComponentClass()
      Description copied from interface: ConfigurationPersistingStrategy
      Provides the class this strategy is valid for. Used for mapping strategies to classes via spring.
      Specified by:
      getComponentClass in interface ConfigurationPersistingStrategy<CONFIG extends UIComponentConfiguration>
      Returns:
      the class of the configuration which this strategy can handle
    • createXml

      public String createXml(JAXBCLASS root)
    • setJaxbClass

      public void setJaxbClass(Class<JAXBCLASS> jaxbClass)
    • getComponentClassName

      public String getComponentClassName()
    • setComponentClassName

      public void setComponentClassName(String componentClass)
    • getConfigurationFactory

      public String getConfigurationFactory()
    • setConfigurationFactory

      public void setConfigurationFactory(String factory)
    • getRootJaxbElement

      protected JAXBCLASS getRootJaxbElement(CONFIG config)
    • getJaxbElement

      protected Object getJaxbElement(CONFIG config, Object element)
    • setSchemaResource

      public void setSchemaResource(org.springframework.core.io.Resource schemaResource)
    • getModelService

      public ModelService getModelService()
    • setModelService

      public void setModelService(ModelService modelService)
    • getMediaService

      public MediaService getMediaService()
    • setMediaService

      public void setMediaService(MediaService mediaService)
    • setUiAccessRightService

      public void setUiAccessRightService(UIAccessRightService uiAccessRightService)
    • getCockpitUIComponentConfigurationDao

      public CockpitUIComponentConfigurationDao getCockpitUIComponentConfigurationDao()
    • setCockpitUIComponentConfigurationDao

      public void setCockpitUIComponentConfigurationDao(CockpitUIComponentConfigurationDao cockpitConfigurationDao)
    • setJaxbContextCache

      public void setJaxbContextCache(JAXBContextCache jaxbContextCache)