Foxit PDF SDK
foxit::pdf::StdEncryptData Class Reference

Public Member Functions

 StdEncryptData ()
 Constructor.
 
 StdEncryptData (bool is_encrypt_metadata, uint32 user_permissions, SecurityHandler::CipherType cipher, int key_length)
 Constructor, with parameters. More...
 
 StdEncryptData (const StdEncryptData &other)
 Constructor, with another standard encrypt data object. More...
 
bool operator!= (const StdEncryptData &other) const
 Not equal operator. More...
 
StdEncryptDataoperator= (const StdEncryptData &other)
 Assign operator. More...
 
bool operator== (const StdEncryptData &other) const
 Equal operator. More...
 
void Set (bool is_encrypt_metadata, uint32 user_permissions, SecurityHandler::CipherType cipher, int key_length)
 Set value. More...
 

Public Attributes

SecurityHandler::CipherType cipher
 Cipher type. Please refer to values starting from SecurityHandler::e_CipherRC4 and this should be one of these values except SecurityHandler::e_CipherNone.
 
bool is_encrypt_metadata
 A boolean value to decide whether to encrypt metadata or not. true means to encrypt metadata, and false means not to encrypt metadata.
 
int key_length
 The key length, in bytes. More...
 
uint32 user_permissions
 The user permissions. Please refer to values starting from PDFDoc::e_PermPrint and this should be one or combination of these values.
 

Detailed Description

This class represents some data used for class StdSecurityHandler.

Constructor & Destructor Documentation

◆ StdEncryptData() [1/2]

foxit::pdf::StdEncryptData::StdEncryptData ( bool  is_encrypt_metadata,
uint32  user_permissions,
SecurityHandler::CipherType  cipher,
int  key_length 
)
inline

Constructor, with parameters.

Parameters
[in]is_encrypt_metadatatrue means to encrypt metadata, and false means not to encrypt metadata.
[in]user_permissionsThe user permissions. Please refer to values starting from PDFDoc::e_PermPrint and this should be one or combination of these values.
[in]cipherCipher type. Please refer to values starting from SecurityHandler::e_CipherRC4 and this should be one of these values except SecurityHandler::e_CipherNone.
[in]key_lengthThe key length, in bytes.

◆ StdEncryptData() [2/2]

foxit::pdf::StdEncryptData::StdEncryptData ( const StdEncryptData other)
inline

Constructor, with another standard encrypt data object.

Parameters
[in]otherAnother standard encrypt data object.

Member Function Documentation

◆ operator!=()

bool foxit::pdf::StdEncryptData::operator!= ( const StdEncryptData other) const
inline

Not equal operator.

Parameters
[in]otherAnother standard encrypt data object. This function will check if current object is not equal to this one.
Returns
true means not equal, while false means equal.

◆ operator=()

StdEncryptData& foxit::pdf::StdEncryptData::operator= ( const StdEncryptData other)
inline

Assign operator.

Parameters
[in]otherAnother standard encrypt data object, whose value would be assigned to current object.
Returns
Reference to current object itself.

◆ operator==()

bool foxit::pdf::StdEncryptData::operator== ( const StdEncryptData other) const
inline

Equal operator.

Parameters
[in]otherAnother standard encrypt data object. This function will check if current object is equal to this one.
Returns
true means equal, while false means not equal.

◆ Set()

void foxit::pdf::StdEncryptData::Set ( bool  is_encrypt_metadata,
uint32  user_permissions,
SecurityHandler::CipherType  cipher,
int  key_length 
)
inline

Set value.

Parameters
[in]is_encrypt_metadatatrue means to encrypt metadata, and false means not to encrypt metadata.
[in]user_permissionsThe user permissions. Please refer to values starting from PDFDoc::e_PermPrint and this should be one or combination of these values.
[in]cipherCipher type. Please refer to values starting from SecurityHandler::e_CipherRC4 and this should be one of these values except SecurityHandler::e_CipherNone.
[in]key_lengthThe key length, in bytes.
Returns
None.

Member Data Documentation

◆ key_length

int foxit::pdf::StdEncryptData::key_length

The key length, in bytes.