Class DefaultMappingLineConfiguration
- java.lang.Object
-
- de.hybris.platform.importcockpit.services.config.mapping.impl.DefaultMappingLineConfiguration
-
- All Implemented Interfaces:
UIComponentConfiguration
,MappingLineConfiguration
public class DefaultMappingLineConfiguration extends java.lang.Object implements MappingLineConfiguration
-
-
Constructor Summary
Constructors Constructor Description DefaultMappingLineConfiguration(java.util.List<Property> importProps)
DefaultMappingLineConfiguration(java.util.Map<java.lang.String,java.lang.String> editorMap, java.util.Map<java.lang.String,java.lang.Boolean> visibilityMap, java.util.Map<java.lang.String,java.util.Map<java.lang.String,java.lang.String>> params, java.util.List<Property> importProps, java.util.List<SpecialTranslator> specialTranslators)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.String
getEditorCode(java.lang.String propertyQualifier)
Returns the code of the editor that should be used for the mapping mappingLineModel display in the mapping area.java.util.List<Property>
getImportProperties()
Returns the import properties as configured in the XML config file.java.util.List<java.lang.String>
getImportPropertiesQualifiers()
Returns a list if property descriptors configured in the "import properties" section in the mapping mappingLineModel XML config files.protected Property
getImportProperty(java.lang.String propertyQualifier)
Find a named property from the import propertiesjava.util.Map<java.lang.String,java.lang.String>
getParameterMap(java.lang.String propertyQualifier)
Returns a map of parameter qualifiers and their values as configured in the XML config file.java.util.List<SpecialTranslator>
getSpecialTranslators()
java.lang.String
getTranslator(java.lang.String propertyQualifier)
Returns the value of the "translator" parameter of the specified property qualifier config.boolean
isAllowNull(java.lang.String propertyQualifier)
Returns true if there is allownull=true parameter configured for the given property qualifier.boolean
isEditorVisible(java.lang.String propertyQualifier)
Returns true if the editor is set to be visible in the xml config file
-
-
-
Constructor Detail
-
DefaultMappingLineConfiguration
public DefaultMappingLineConfiguration(java.util.List<Property> importProps)
-
DefaultMappingLineConfiguration
public DefaultMappingLineConfiguration(java.util.Map<java.lang.String,java.lang.String> editorMap, java.util.Map<java.lang.String,java.lang.Boolean> visibilityMap, java.util.Map<java.lang.String,java.util.Map<java.lang.String,java.lang.String>> params, java.util.List<Property> importProps, java.util.List<SpecialTranslator> specialTranslators)
-
-
Method Detail
-
getEditorCode
public java.lang.String getEditorCode(java.lang.String propertyQualifier)
Description copied from interface:MappingLineConfiguration
Returns the code of the editor that should be used for the mapping mappingLineModel display in the mapping area.- Specified by:
getEditorCode
in interfaceMappingLineConfiguration
- Returns:
- editor code
-
isEditorVisible
public boolean isEditorVisible(java.lang.String propertyQualifier)
Description copied from interface:MappingLineConfiguration
Returns true if the editor is set to be visible in the xml config file- Specified by:
isEditorVisible
in interfaceMappingLineConfiguration
- Returns:
- true if the editor is configured to be visible in the xml config file
-
getParameterMap
public java.util.Map<java.lang.String,java.lang.String> getParameterMap(java.lang.String propertyQualifier)
Description copied from interface:MappingLineConfiguration
Returns a map of parameter qualifiers and their values as configured in the XML config file.- Specified by:
getParameterMap
in interfaceMappingLineConfiguration
- Returns:
- map of parameter qualifiers and values
-
getImportProperties
public java.util.List<Property> getImportProperties()
Description copied from interface:MappingLineConfiguration
Returns the import properties as configured in the XML config file.- Specified by:
getImportProperties
in interfaceMappingLineConfiguration
- Returns:
- list of import properties as Property objects (can contain translator or allowNull specifications)
-
getSpecialTranslators
public java.util.List<SpecialTranslator> getSpecialTranslators()
- Specified by:
getSpecialTranslators
in interfaceMappingLineConfiguration
- Returns:
- all translators of a type (Media have the translator @media)
-
getTranslator
public java.lang.String getTranslator(java.lang.String propertyQualifier)
Description copied from interface:MappingLineConfiguration
Returns the value of the "translator" parameter of the specified property qualifier config. If there is no "translator" parameter defined, null is returned.- Specified by:
getTranslator
in interfaceMappingLineConfiguration
- Returns:
- qualified class name of the translator
-
isAllowNull
public boolean isAllowNull(java.lang.String propertyQualifier)
Description copied from interface:MappingLineConfiguration
Returns true if there is allownull=true parameter configured for the given property qualifier.- Specified by:
isAllowNull
in interfaceMappingLineConfiguration
- Returns:
- true if the parameter allownull is existent and set to "true", false otherwise
-
getImportProperty
protected Property getImportProperty(java.lang.String propertyQualifier)
Find a named property from the import properties- Parameters:
propertyQualifier
- The qualifier of the property to lookup- Returns:
- The property as specified by @propertyQualifier, null if not found.
-
getImportPropertiesQualifiers
public java.util.List<java.lang.String> getImportPropertiesQualifiers()
Description copied from interface:MappingLineConfiguration
Returns a list if property descriptors configured in the "import properties" section in the mapping mappingLineModel XML config files. These properties will be handled by the Import cockpit as mandatory mapping lines.- Specified by:
getImportPropertiesQualifiers
in interfaceMappingLineConfiguration
- Returns:
- list of property descriptor qualifiers as specified in the XML config file
-
-