Interface MappingLineService
-
- All Known Implementing Classes:
DefaultMappingLineService
public interface MappingLineService
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description MappingLineModeladdCollectionEntry(CollectionMappingLine mappingLineModel)Adds an additional entry mappingLineModel to a collection mapping mappingLineModel.MappingLineModelgenerateAtomicMappingLine(ItemAttributePropertyDescriptor propertyDescriptor)Generates an Atomic type mapping line model based on the attribute property descriptorMappingLineModelgenerateComposedMappingLine(ItemAttributePropertyDescriptor propertyDescriptor, boolean generateSubLines)Generates a composed mapping mappingLineModel based on the property descriptorbooleangenerateMappedSubMappingLines(MappingLineModel mappingLineModel, java.util.Collection<ItemModel> items)Generates new sub mapping lines for the items given.MappingLineModelgenerateMappingLine(PropertyDescriptor propertyDescriptor)Generates a mapping line model based on the property descriptor.MappingLineModelgenerateProductAttributeMappingLine(java.lang.String translator, java.lang.String translatorQualifier)Generate a specific translator for type Product (@ClassificationAttributeTranslator)MappingLineModelgenerateTranslatorMappingLine(ClassificationClassModel classificationClass, ClassificationAttributeModel classificationAttribute, java.lang.String translator)Generate a translator mapping mappingLineModelMappingLineModelgenerateTranslatorMappingLine(java.lang.String translatorQualifier, java.lang.String translator)Generate a translator mapping mappingLineModelMappingLineModelgenerateVirtualMappingLine(SourceColumnModel sourceColumn)Generates a so called "virtual" mapping line model after a source column has been dropped into the mapping view without a target attribute specified.booleanisLineOfDateType(MappingLineModel mappingLineModel)Checks if the mapping mappingLineModel refers to an attribute of a date type (like Product.onlineDate, Product.offlineDate etc.)booleanisLineOfNumberType(MappingLineModel mappingLineModel)Checks if the mapping mappingLineModel refers to an attribute of a number type (like integer, double etc.).
-
-
-
Method Detail
-
generateMappingLine
MappingLineModel generateMappingLine(PropertyDescriptor propertyDescriptor)
Generates a mapping line model based on the property descriptor.- Parameters:
propertyDescriptor- property descriptor- Returns:
- mapping mappingLineModel
-
generateAtomicMappingLine
MappingLineModel generateAtomicMappingLine(ItemAttributePropertyDescriptor propertyDescriptor)
Generates an Atomic type mapping line model based on the attribute property descriptor- Parameters:
propertyDescriptor-- Returns:
- An AtomicTypeMapping line(model)
-
generateVirtualMappingLine
MappingLineModel generateVirtualMappingLine(SourceColumnModel sourceColumn)
Generates a so called "virtual" mapping line model after a source column has been dropped into the mapping view without a target attribute specified. In this case it is still not clear what type of mapping line model (localized, composed, basic etc.) will be used until the tartet attribute is chosen and dropped into the mapping view. Once a target attribute is dropped, the virtual mapping model is replaced by the related mapping line model.- Parameters:
sourceColumn-- Returns:
- virtual mapping mappingLineModel
-
generateMappedSubMappingLines
boolean generateMappedSubMappingLines(MappingLineModel mappingLineModel, java.util.Collection<ItemModel> items)
Generates new sub mapping lines for the items given. This method is used by the UI editors for collection and composed mapping lines: The referenced object in the editor provides the items that specify the object, and the sub lines are created for these items.- Parameters:
mappingLineModel-items-- Returns:
- true if any new sub lines were added
-
generateComposedMappingLine
MappingLineModel generateComposedMappingLine(ItemAttributePropertyDescriptor propertyDescriptor, boolean generateSubLines)
Generates a composed mapping mappingLineModel based on the property descriptor- Parameters:
propertyDescriptor-generateSubLines-- Returns:
- A composed mappingLine with or without sub lines
-
generateTranslatorMappingLine
MappingLineModel generateTranslatorMappingLine(java.lang.String translatorQualifier, java.lang.String translator)
Generate a translator mapping mappingLineModel- Parameters:
translatorQualifier- for example '@media'translator- for @media it is "de.hybris.platform.impex.jalo.media.MediaDataTranslator"- Returns:
- a translator mapping mappingLineModel
-
generateTranslatorMappingLine
MappingLineModel generateTranslatorMappingLine(ClassificationClassModel classificationClass, ClassificationAttributeModel classificationAttribute, java.lang.String translator)
Generate a translator mapping mappingLineModel- Parameters:
classificationClass-classificationAttribute-translator- for @media it is "de.hybris.platform.impex.jalo.media.MediaDataTranslator"- Returns:
- a translator mapping mappingLineModel
-
generateProductAttributeMappingLine
MappingLineModel generateProductAttributeMappingLine(java.lang.String translator, java.lang.String translatorQualifier)
Generate a specific translator for type Product (@ClassificationAttributeTranslator)- Parameters:
translator- translatortranslatorQualifier- translator qualifier- Returns:
- translator mappingLine
-
addCollectionEntry
MappingLineModel addCollectionEntry(CollectionMappingLine mappingLineModel)
Adds an additional entry mappingLineModel to a collection mapping mappingLineModel.- Parameters:
mappingLineModel- collection mappingLineModel- Returns:
- mapping line
-
isLineOfNumberType
boolean isLineOfNumberType(MappingLineModel mappingLineModel)
Checks if the mapping mappingLineModel refers to an attribute of a number type (like integer, double etc.).- Parameters:
mappingLineModel- MappingLineModel- Returns:
- true if the mapping mappingLineModel represents an attribute of a number type
-
isLineOfDateType
boolean isLineOfDateType(MappingLineModel mappingLineModel)
Checks if the mapping mappingLineModel refers to an attribute of a date type (like Product.onlineDate, Product.offlineDate etc.)- Parameters:
mappingLineModel- MappingLineModel- Returns:
- true if the mapping mappingLineModel represents an attribute of a date type
-
-