Class PdfEncryptedPayloadFileSpecFactory

java.lang.Object
com.itextpdf.kernel.pdf.filespec.PdfEncryptedPayloadFileSpecFactory

public class PdfEncryptedPayloadFileSpecFactory extends Object
  • Constructor Details

    • PdfEncryptedPayloadFileSpecFactory

      public PdfEncryptedPayloadFileSpecFactory()
  • Method Details

    • create

      public static PdfFileSpec create (PdfDocument doc, byte[] fileStore, PdfEncryptedPayload encryptedPayload, PdfName mimeType, PdfDictionary fileParameter)
      Embed a encrypted payload to a PdfDocument.
      Parameters:
      doc - PdfDocument to add the file to
      fileStore - byte[] containing encrypted file
      encryptedPayload - the encrypted payload dictionary
      mimeType - mime-type of the file
      fileParameter - Pdfdictionary containing file parameters
      Returns:
      PdfFileSpec containing the file specification of the encrypted payload
    • create

      public static PdfFileSpec create (PdfDocument doc, byte[] fileStore, PdfEncryptedPayload encryptedPayload, PdfDictionary fileParameter)
      Embed a encrypted payload to a PdfDocument.
      Parameters:
      doc - PdfDocument to add the file to
      fileStore - byte[] containing the file
      encryptedPayload - the encrypted payload dictionary
      fileParameter - Pdfdictionary containing file parameters
      Returns:
      PdfFileSpec containing the file specification of the encrypted payload
    • create

      public static PdfFileSpec create (PdfDocument doc, byte[] fileStore, PdfEncryptedPayload encryptedPayload)
      Embed a encrypted payload to a PdfDocument.
      Parameters:
      doc - PdfDocument to add the file to
      fileStore - byte[] containing the file
      encryptedPayload - the encrypted payload dictionary
      Returns:
      PdfFileSpec containing the file specification of the encrypted payload
    • create

      public static PdfFileSpec create (PdfDocument doc, String filePath, PdfEncryptedPayload encryptedPayload, PdfName mimeType, PdfDictionary fileParameter) throws IOException
      Embed a encrypted payload to a PdfDocument.
      Parameters:
      doc - PdfDocument to add the file to
      filePath - path to the encrypted file
      encryptedPayload - the encrypted payload dictionary
      mimeType - mime-type of the file
      fileParameter - Pdfdictionary containing file parameters
      Returns:
      PdfFileSpec containing the file specification of the encrypted payload
      Throws:
      IOException - in case of any I/O error
    • create

      public static PdfFileSpec create (PdfDocument doc, String filePath, PdfEncryptedPayload encryptedPayload, PdfName mimeType) throws IOException
      Embed a encrypted payload to a PdfDocument.
      Parameters:
      doc - PdfDocument to add the file to
      filePath - path to the encrypted file
      encryptedPayload - the encrypted payload dictionary
      mimeType - mime-type of the file
      Returns:
      PdfFileSpec containing the file specification of the encrypted payload
      Throws:
      IOException - in case of any I/O error
    • create

      public static PdfFileSpec create (PdfDocument doc, String filePath, PdfEncryptedPayload encryptedPayload) throws IOException
      Embed a encrypted payload to a PdfDocument.
      Parameters:
      doc - PdfDocument to add the file to
      filePath - path to the encrypted file
      encryptedPayload - the encrypted payload dictionary
      Returns:
      PdfFileSpec containing the file specification of the encrypted payload
      Throws:
      IOException - in case of any I/O error
    • create

      public static PdfFileSpec create (PdfDocument doc, InputStream is, PdfEncryptedPayload encryptedPayload, PdfName mimeType, PdfDictionary fileParameter)
      Embed a encrypted payload to a PdfDocument.
      Parameters:
      doc - PdfDocument to add the file to
      is - stream containing encrypted file
      encryptedPayload - the encrypted payload dictionary
      mimeType - mime-type of the file
      fileParameter - Pdfdictionary containing file parameters
      Returns:
      PdfFileSpec containing the file specification of the encrypted payload
    • create

      public static PdfFileSpec create (PdfDocument doc, InputStream is, PdfEncryptedPayload encryptedPayload, PdfName mimeType)
      Embed a encrypted payload to a PdfDocument.
      Parameters:
      doc - PdfDocument to add the file to
      is - stream containing encrypted file
      encryptedPayload - the encrypted payload dictionary
      mimeType - mime-type of the file
      Returns:
      PdfFileSpec containing the file specification of the encrypted payload
    • create

      public static PdfFileSpec create (PdfDocument doc, InputStream is, PdfEncryptedPayload encryptedPayload)
      Embed a encrypted payload to a PdfDocument.
      Parameters:
      doc - PdfDocument to add the file to
      is - stream containing encrypted file
      encryptedPayload - the encrypted payload dictionary
      Returns:
      PdfFileSpec containing the file specification of the encrypted payload
    • wrap

      public static PdfFileSpec wrap (PdfDictionary dictionary)
    • generateDescription

      public static String generateDescription (PdfEncryptedPayload ep)
    • generateFileDisplay

      public static String generateFileDisplay (PdfEncryptedPayload ep)