Class WorkbookMandatoryColumnsValidator

  • All Implemented Interfaces:
    WorkbookValidator

    public class WorkbookMandatoryColumnsValidator
    extends java.lang.Object
    implements WorkbookValidator
    Default excel validator which checks whether all mandatory columns are selected for each excel sheet. If mandatory column is localized then column for current language is required.
    • Field Detail

      • VALIDATION_MESSAGE_HEADER

        public static final java.lang.String VALIDATION_MESSAGE_HEADER
        See Also:
        Constant Field Values
      • VALIDATION_MESSAGE_DESCRIPTION

        public static final java.lang.String VALIDATION_MESSAGE_DESCRIPTION
        See Also:
        Constant Field Values
    • Constructor Detail

      • WorkbookMandatoryColumnsValidator

        public WorkbookMandatoryColumnsValidator()
    • Method Detail

      • validate

        public java.util.List<ExcelValidationResult> validate​(org.apache.poi.ss.usermodel.Workbook workbook)
        Description copied from interface: WorkbookValidator
        Validates workbook. If workbook doesn't have validation issues then empty list should be returned.
        Specified by:
        validate in interface WorkbookValidator
        Returns:
        list of validation results. If workbook doesn't have validation issues then empty list should be returned.
      • validateSheet

        protected java.util.Optional<ExcelValidationResult> validateSheet​(org.apache.poi.ss.usermodel.Sheet typeSystemSheet,
                                                                          org.apache.poi.ss.usermodel.Sheet sheet)
      • getAttributeDisplayedName

        protected java.lang.String getAttributeDisplayedName​(AttributeDescriptorModel attributeDescriptor)
      • findAllMandatoryFields

        public java.util.Set<AttributeDescriptorModel> findAllMandatoryFields​(java.lang.String typeCode)
      • hasNotDefaultValue

        @Deprecated(since="1808",
                    forRemoval=true)
        protected boolean hasNotDefaultValue​(AttributeDescriptorModel attributeDescriptorModel)
        Deprecated, for removal: This API element is subject to removal in a future version.
        since 1808. Use DefaultValueCheckingFilter instead
      • getTypeService

        @Deprecated(since="1808",
                    forRemoval=true)
        public TypeService getTypeService()
        Deprecated, for removal: This API element is subject to removal in a future version.
        since 1808.
      • setTypeService

        @Deprecated(since="1808",
                    forRemoval=true)
        public void setTypeService​(TypeService typeService)
        Deprecated, for removal: This API element is subject to removal in a future version.
        since 1808.
      • setCommonI18NService

        public void setCommonI18NService​(CommonI18NService commonI18NService)
      • getExcelTemplateService

        @Deprecated(since="1808",
                    forRemoval=true)
        public ExcelTemplateService getExcelTemplateService()
        Deprecated, for removal: This API element is subject to removal in a future version.
        since 1808.
      • setExcelTemplateService

        @Deprecated(since="1808",
                    forRemoval=true)
        public void setExcelTemplateService​(ExcelTemplateService excelTemplateService)
        Deprecated, for removal: This API element is subject to removal in a future version.
        since 1808.
      • setExcelWorkbookService

        public void setExcelWorkbookService​(ExcelWorkbookService excelWorkbookService)
      • setExcelSheetService

        public void setExcelSheetService​(ExcelSheetService excelSheetService)