Class PdfAutoSweepTools

java.lang.Object
com.itextpdf.pdfcleanup.autosweep.PdfAutoSweepTools

public class PdfAutoSweepTools extends Object
Class that automatically extracts all regions of interest from a given PdfDocument and redacts them.
  • Constructor Summary

    Constructors
    Constructor
    Description
    Construct a new instance of PdfAutoSweepTools with a given ICleanupStrategy
  • Method Summary

    Modifier and Type
    Method
    Description
    getPdfCleanUpLocations(com.itextpdf.kernel.pdf.PdfDocument doc)
    Get all PdfCleanUpLocation objects from a given PdfDocument.
    getPdfCleanUpLocations(com.itextpdf.kernel.pdf.PdfPage page)
    Get all PdfCleanUpLocation objects from a given PdfPage.
    void
    highlight(com.itextpdf.kernel.pdf.PdfDocument pdfDocument)
    Highlight areas of interest in a given PdfDocument
    void
    highlight(com.itextpdf.kernel.pdf.PdfPage pdfPage)
    Highlight areas of interest in a given PdfPage
    void
    tentativeCleanUp(com.itextpdf.kernel.pdf.PdfDocument pdfDocument)
    Perform tentative cleanup of areas of interest on a given PdfDocument This method will add all redaction annotations to the given document, allowing the end-user to choose which redactions to keep or delete.
    void
    tentativeCleanUp(com.itextpdf.kernel.pdf.PdfPage pdfPage)
    Perform tentative cleanup of areas of interest on a given PdfPage This method will add all redaction annotations to the given page, allowing the end-user to choose which redactions to keep or delete.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • PdfAutoSweepTools

      public PdfAutoSweepTools (ICleanupStrategy strategy)
      Construct a new instance of PdfAutoSweepTools with a given ICleanupStrategy
      Parameters:
      strategy - the redaction strategy to be used
  • Method Details

    • highlight

      public void highlight (com.itextpdf.kernel.pdf.PdfDocument pdfDocument)
      Highlight areas of interest in a given PdfDocument
      Parameters:
      pdfDocument - the PdfDocument to be highlighted
    • highlight

      public void highlight (com.itextpdf.kernel.pdf.PdfPage pdfPage)
      Highlight areas of interest in a given PdfPage
      Parameters:
      pdfPage - the PdfPage to be highlighted
    • tentativeCleanUp

      public void tentativeCleanUp (com.itextpdf.kernel.pdf.PdfDocument pdfDocument)
      Perform tentative cleanup of areas of interest on a given PdfDocument This method will add all redaction annotations to the given document, allowing the end-user to choose which redactions to keep or delete.
      Parameters:
      pdfDocument - the document to clean up
    • tentativeCleanUp

      public void tentativeCleanUp (com.itextpdf.kernel.pdf.PdfPage pdfPage)
      Perform tentative cleanup of areas of interest on a given PdfPage This method will add all redaction annotations to the given page, allowing the end-user to choose which redactions to keep or delete.
      Parameters:
      pdfPage - the page to clean up
    • getPdfCleanUpLocations

      public List<PdfCleanUpLocation> getPdfCleanUpLocations (com.itextpdf.kernel.pdf.PdfPage page)
      Get all PdfCleanUpLocation objects from a given PdfPage.
      Parameters:
      page - the PdfPage to be processed
      Returns:
      a List of PdfCleanUpLocation objects
    • getPdfCleanUpLocations

      public List<PdfCleanUpLocation> getPdfCleanUpLocations (com.itextpdf.kernel.pdf.PdfDocument doc)
      Get all PdfCleanUpLocation objects from a given PdfDocument.
      Parameters:
      doc - the PdfDocument to be processed
      Returns:
      a List of PdfCleanUpLocation objects