foxit::pdf::DRMEncryptData Class Reference

Public Member Functions

 DRMEncryptData (bool is_encrypt_metadata, const String &sub_filter, SecurityHandler::CipherType cipher, int key_length, bool is_owner, uint32 user_permissions)
 Constructor, with parameters. More...
 
 DRMEncryptData ()
 Constructor.
 
 DRMEncryptData (const DRMEncryptData &other)
 Constructor, with another DRM encrypt data object. More...
 
 ~DRMEncryptData ()
 Destructor.
 
bool operator!= (const DRMEncryptData &other) const
 Not equal operator. More...
 
DRMEncryptDataoperator= (const DRMEncryptData &other)
 Assign operator. More...
 
bool operator== (const DRMEncryptData &other) const
 Equal operator. More...
 
void Set (bool is_encrypt_metadata, const String &sub_filter, SecurityHandler::CipherType cipher, int key_length, bool is_owner, uint32 user_permissions)
 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.
 
bool is_owner
 A boolean value to decide whether current user is owner or not. true means current user is owner, and false means current user is not owner.
 
int key_length
 The key length, in bytes.
For SecurityHandler::e_CipherRC4 cipher, this value should be between 5 and 16.
For SecurityHandler::e_CipherAES cipher, this value should be 16 or 32.
 
String sub_filter
 The sub filter of PDF document.
 
uint32 user_permissions
 The user permissions. Please refer to values starting from PDFDoc::e_PermPrint and this can be one or combination of these values.
 

Detailed Description

This class represents some data used for class DRMSecurityHandler.

Constructor & Destructor Documentation

◆ DRMEncryptData() [1/2]

foxit::pdf::DRMEncryptData::DRMEncryptData ( bool  is_encrypt_metadata,
const String sub_filter,
SecurityHandler::CipherType  cipher,
int  key_length,
bool  is_owner,
uint32  user_permissions 
)
inline

Constructor, with parameters.

Parameters
[in]is_encrypt_metadatatrue means to encrypt metadata, and false means not to encrypt metadata
[in]sub_filterThe sub filter of PDF document.
[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.
For SecurityHandler::e_CipherRC4 cipher, this value should be between 5 and 16.
For SecurityHandler::e_CipherAES cipher, this value should be 16 or 32.
[in]is_ownertrue means current user is owner, and false means current user is not owner.
[in]user_permissionsThe user permissions. Please refer to values starting from PDFDoc::e_PermPrint and this can be one or combination of these values.

◆ DRMEncryptData() [2/2]

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

Constructor, with another DRM encrypt data object.

Parameters
[in]otherAnother DRM encrypt data object.

Member Function Documentation

◆ operator!=()

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

Not equal operator.

Parameters
[in]otherAnother DRM 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=()

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

Assign operator.

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

◆ operator==()

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

Equal operator.

Parameters
[in]otherAnother DRM 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::DRMEncryptData::Set ( bool  is_encrypt_metadata,
const String sub_filter,
SecurityHandler::CipherType  cipher,
int  key_length,
bool  is_owner,
uint32  user_permissions 
)
inline

Set value.

Parameters
[in]is_encrypt_metadatatrue means to encrypt metadata, and false means not to encrypt metadata
[in]sub_filterThe sub filter of PDF document.
[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.
For SecurityHandler::e_CipherRC4 cipher, this value should be between 5 and 16.
For SecurityHandler::e_CipherAES cipher, this value should be 16 or 32.
[in]is_ownertrue means current user is owner, and false means current user is not owner.
[in]user_permissionsThe user permissions. Please refer to values starting from PDFDoc::e_PermPrint and this can be one or combination of these values.
Returns
None.

Foxit Software Corporation Logo
@2019 Foxit Software Incorporated. All rights reserved.