Class FilterHelper

java.lang.Object
org.apache.pdfbox.preflight.utils.FilterHelper

public final class FilterHelper extends Object
  • Field Details

    • ALLOWED_FILTERS

      private static final Set<String> ALLOWED_FILTERS
  • Constructor Details

    • FilterHelper

      private FilterHelper()
  • Method Details

    • isAuthorizedFilter

      public static void isAuthorizedFilter(PreflightContext context, String filter)
      This method checks if the filter is authorized for the PDF file according to the preflight document specification attribute. For example according to the PDF/A-1 specification, only the LZW filter is forbidden due to Copyright compatibility. Because of the PDF/A is based on the PDF1.4 specification, all filters that aren't declared in the PDF Reference Third Edition are rejected.
      Parameters:
      context - the preflight context
      filter - the filter to check
    • isAuthorizedFilterInPDFA

      public static void isAuthorizedFilterInPDFA(PreflightContext context, String filter)
      This method checks if the filter is authorized for a PDF/A file. According to the PDF/A-1 specification, only the LZW filter is forbidden due to Copyright compatibility. Because of the PDF/A is based on the PDF1.4 specification, all filters that aren't declared in the PDF Reference Third Edition are rejected.
      Parameters:
      context - the preflight context
      filter - the filter to check