Class PdfCleanUpTool

java.lang.Object
com.itextpdf.pdfcleanup.PdfCleanUpTool

public class PdfCleanUpTool extends Object
Represents the main mechanism for cleaning a PDF document.
  • Constructor Details

    • PdfCleanUpTool

      public PdfCleanUpTool (com.itextpdf.kernel.pdf.PdfDocument pdfDocument)
      Creates a PdfCleanUpTool object. No regions for erasing are specified. Use addCleanupLocation(PdfCleanUpLocation) method to set regions to be erased from the document.
      Parameters:
      pdfDocument - A PdfDocument object representing the document to which redaction applies.
    • PdfCleanUpTool

      public PdfCleanUpTool (com.itextpdf.kernel.pdf.PdfDocument pdfDocument, boolean cleanRedactAnnotations, CleanUpProperties properties)
      Creates a PdfCleanUpTool object. If cleanRedactAnnotations is true, regions to be erased are extracted from the redact annotations contained inside the given document. Those redact annotations will be removed from the resultant document. If cleanRedactAnnotations is false, then no regions for erasing are specified. In that case use addCleanupLocation(PdfCleanUpLocation) method to set regions to be erased from the document.
      Parameters:
      pdfDocument - A PdfDocument object representing the document to which redaction applies.
      cleanRedactAnnotations - if true - regions to be erased are extracted from the redact annotations contained
      properties - additional properties for clean-up process inside the given document.
    • PdfCleanUpTool

      public PdfCleanUpTool (com.itextpdf.kernel.pdf.PdfDocument pdfDocument, List<PdfCleanUpLocation> cleanUpLocations, CleanUpProperties properties)
      Creates a PdfCleanUpTool object based on the given List of PdfCleanUpLocations representing regions to be erased from the document.
      Parameters:
      cleanUpLocations - list of locations to be cleaned up PdfCleanUpLocation
      pdfDocument - a PdfDocument object representing the document to which redaction applies.
      properties - additional properties for clean-up process
  • Method Details