Foxit PDF SDK
com.foxit.sdk.pdf.SecurityHandler Class Reference
Inheritance diagram for com.foxit.sdk.pdf.SecurityHandler:
com.foxit.sdk.common.Base com.foxit.sdk.pdf.CertificateSecurityHandler com.foxit.sdk.pdf.CustomSecurityHandler com.foxit.sdk.pdf.DRMSecurityHandler com.foxit.sdk.pdf.RMSSecurityHandler com.foxit.sdk.pdf.StdSecurityHandler

Public Member Functions

 SecurityHandler ()
 Constructor.

 
 SecurityHandler (SecurityHandler other)
 Constructor, with another security handler object.
More...
 
int getSecurityType ()
 Get the encryption type of current security handler.
More...
 
boolean isEmpty ()
 Check whether current object is empty or not.
More...
 

Static Public Attributes

static final int e_CipherAES = 2
 Use AES encryption algorithm, with the key length be 16 bytes (as AES-128) or 32 bytes (as AES-256, only supported in PDF 2.0).

 
static final int e_CipherNone = 0
 Not use encryption algorithm.

 
static final int e_CipherRC4 = 1
 Use RC4 encryption algorithm, with the key length between 5 bytes and 16 bytes.

 

Detailed Description

Class SecurityHandler is the base class that represents a security hander used for encrypting PDF document. It has following derived classes:

To set a security handler to a PDF document, please call function PDFDoc.setSecurityHandler , then the security handler will take effect in later saving process. To get the security handler used for a PDF document, please call function PDFDoc.setSecurityHandler .

See also
StdSecurityHandler
CertificateSecurityHandler
DRMSecurityHandler
CustomSecurityHandler
RMSSecurityHandler
PDFDoc

Constructor & Destructor Documentation

◆ SecurityHandler()

com.foxit.sdk.pdf.SecurityHandler.SecurityHandler ( SecurityHandler  other)

Constructor, with another security handler object.

Parameters
[in]otherAnother security handler object.

Member Function Documentation

◆ getSecurityType()

int com.foxit.sdk.pdf.SecurityHandler.getSecurityType ( )

Get the encryption type of current security handler.

Returns
The encryption type. If current security handler object does not represent any specified type of security handler, it would return com.foxit.sdk.pdf.PDFDoc.e_EncryptUnknown .

◆ isEmpty()

boolean com.foxit.sdk.pdf.SecurityHandler.isEmpty ( )

Check whether current object is empty or not.

When the current object is empty, that means current object is useless.

Returns
true means current object is empty, while false means not.