Class PdfOcrFileUtil

java.lang.Object
com.itextpdf.pdfocr.util.PdfOcrFileUtil

public final class PdfOcrFileUtil extends Object
Utility class for working with files.
  • Method Details

    • writeToTextFile

      public static void writeToTextFile (String path, String data)
      Writes provided String to text file using provided path.
      Parameters:
      path - path as String to file to be created
      data - text data in required format as String
    • getTempFilePath

      public static String getTempFilePath (String name, String extension) throws IOException
      Gets path to temp file in current system temporary directory.
      Parameters:
      name - temp file name
      extension - temp file extension
      Returns:
      path to temp file in the system temporary directory
      Throws:
      IOException - when temp file cannot be obtained