Interface MappingModel

  • All Known Implementing Classes:
    DefaultMappingModel

    public interface MappingModel
    A MappingModel is the basic data structure that defines which columns from a column oriented data source are mapped into hybris data types. A mapping consists of a base type, an impex import mode and several entries of type MappingLineModel.
    • Method Detail

      • isCatalogVersionOption

        boolean isCatalogVersionOption()
        Return if a user want to set the catalog version manually or not for each subtype
      • setCatalogVersionOption

        void setCatalogVersionOption​(boolean isCatalogVersionSelected)
        Set the option for the catalog version
        Parameters:
        isCatalogVersionSelected -
      • getBaseTypeModel

        ComposedTypeModel getBaseTypeModel()
        Returns the base type for this mapping. This will be the base for the import. Example: Product.
        Returns:
        base type
      • setBaseTypeModel

        void setBaseTypeModel​(ComposedTypeModel baseTypeModel)
        Sets the base type for this mapping. This will be the base for the import. Example: Product.
        Parameters:
        baseTypeModel -
      • getImpexImportMode

        ImpexImportMode getImpexImportMode()
        Returns the import impexImportMode that is used for this mapping. Example: INSERT or UPDATE
        Returns:
        impexImportMode ImpexImportMode
      • setImpexImportMode

        void setImpexImportMode​(ImpexImportMode impexImportMode)
        Returns the import impexImportMode that is used for this mapping. Example: INSERT or UPDATE
        Parameters:
        impexImportMode - ImpexImportMode
      • getEntries

        java.util.List<MappingLineModel> getEntries()
        Returns a list of MappingLineModel entries, which represent single hybris attributes and their assignments to source values.
        Returns:
        list of mapping lines
      • setEntries

        void setEntries​(java.util.List<MappingLineModel> entries)
        Sets a list of MappingLineModel entries, which represent single hybris attributes and their assignments to source values.
        Parameters:
        entries - list of mapping lines
      • addEntry

        boolean addEntry​(MappingLineModel mappingLineModel)
        Adds a mapping mappingLineModel entry to the list of mapping lines if not already in the list.
        Parameters:
        mappingLineModel - the new mappingLineModel
        Returns:
        true if a new entry was added, false if the mapping mappingLineModel was already in the list
      • getCatalogVersion

        CatalogVersionModel getCatalogVersion()
        Returns the catalog version that is used for import.
        Returns:
        catalog version
      • setCatalogVersion

        void setCatalogVersion​(CatalogVersionModel catalogVersion)
        Sets the catalog version that is used for import.
        Parameters:
        catalogVersion -
      • getValidationResult

        ValidationResult getValidationResult()
        Returns the validation result if this mapping was already validated.
        Returns:
        validation result
      • setValidationResult

        void setValidationResult​(ValidationResult validationResult)
        Sets the validation result to the mapping.
        Parameters:
        validationResult -
      • deepCopy

        MappingModel deepCopy()
        Makes a deep copy of the mapping. Used for the mapping load function.
        Returns:
        a deep copy of the mapping: also a MappingModel object
      • setManualUniqueOption

        void setManualUniqueOption​(boolean isManualUniqueOption)
        Sets the manual unique attribute handling option.
        Parameters:
        isManualUniqueOption - true if unique attribute should be managed manually
      • isManualUniqueOption

        boolean isManualUniqueOption()
        Returns the manual unique attribute handling option value.
        Returns:
        true if unique attribute should be managed manually