PdfEncryptionDetails

Inheritance: java.lang.Object

public class PdfEncryptionDetails

Contains details for a pdf encryption.

Constructors

ConstructorDescription
PdfEncryptionDetails(String userPassword, String ownerPassword, int permissions, PdfEncryptionAlgorithm encryptionAlgorithm)Initializes a new instance of the PdfEncryptionDetailsCore class.

Methods

MethodDescription
getUserPassword()Returns the user password.
setUserPassword(String value)Sets the user password.
getOwnerPassword()Returns the owner password.
setOwnerPassword(String value)Sets the owner password.
getPermissions()Returns the permissions.
setPermissions(int value)Sets the permissions.
getEncryptionAlgorithm()Returns the encryption mode.
setEncryptionAlgorithm(PdfEncryptionAlgorithm value)Sets the encryption mode.

PdfEncryptionDetails(String userPassword, String ownerPassword, int permissions, PdfEncryptionAlgorithm encryptionAlgorithm)

public PdfEncryptionDetails(String userPassword, String ownerPassword, int permissions, PdfEncryptionAlgorithm encryptionAlgorithm)

Initializes a new instance of the PdfEncryptionDetailsCore class.

Parameters:

ParameterTypeDescription
userPasswordjava.lang.StringThe user password.
ownerPasswordjava.lang.StringThe owner password.
permissionsintThe permissions.
encryptionAlgorithmPdfEncryptionAlgorithmThe encryption algorithm.

getUserPassword()

public String getUserPassword()

Returns the user password.

Opening the document with the correct user password (or opening a document that does not have a user password) allows additional operations to be performed according to the user access permissions specified in the document\u0432\u0402\u2122s encryption dictionary.

Returns: java.lang.String - The user password.

setUserPassword(String value)

public void setUserPassword(String value)

Sets the user password.

Opening the document with the correct user password (or opening a document that does not have a user password) allows additional operations to be performed according to the user access permissions specified in the document\u0432\u0402\u2122s encryption dictionary.

Parameters:

ParameterTypeDescription
valuejava.lang.StringThe user password.

getOwnerPassword()

public String getOwnerPassword()

Returns the owner password.

Opening the document with the correct owner password (assuming it is not the same as the user password) allows full (owner) access to the document. This unlimited access includes the ability to change the document\u0432\u0402\u2122s passwords and access permissions.

Returns: java.lang.String - The owner password.

setOwnerPassword(String value)

public void setOwnerPassword(String value)

Sets the owner password.

Opening the document with the correct owner password (assuming it is not the same as the user password) allows full (owner) access to the document. This unlimited access includes the ability to change the document\u0432\u0402\u2122s passwords and access permissions.

Parameters:

ParameterTypeDescription
valuejava.lang.StringThe owner password.

getPermissions()

public int getPermissions()

Returns the permissions.

Returns: int - The permissions.

setPermissions(int value)

public void setPermissions(int value)

Sets the permissions.

Parameters:

ParameterTypeDescription
valueintThe permissions.

getEncryptionAlgorithm()

public PdfEncryptionAlgorithm getEncryptionAlgorithm()

Returns the encryption mode.

Returns: PdfEncryptionAlgorithm - The encryption algorithm.

setEncryptionAlgorithm(PdfEncryptionAlgorithm value)

public void setEncryptionAlgorithm(PdfEncryptionAlgorithm value)

Sets the encryption mode.

Parameters:

ParameterTypeDescription
valuePdfEncryptionAlgorithmThe encryption algorithm.