Foxit PDF RDK

Public Member Functions | Public Attributes | List of all members
StdEncryptData Class Reference
Inheritance diagram for StdEncryptData:

## Public Member Functions
| constructor ()
| Constructor.
| constructor (is_encrypt_metadata, user_permissions, cipher, key_length)
| Constructor, with parameters. More...
| Set (is_encrypt_metadata, user_permissions, cipher, key_length)
| Set value. More...
Public Member Functions inherited from NativeObjectWrapper
| constructor (r)
| GetPointerAsNumber ()

## Public Attributes
| cipher
| Cipher type. Please refer to values starting from SecurityHandler.e_CipherRC4 and this should be one of these values except SecurityHandler.e_CipherNone.
| 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.
| key_length
| The key length, in bytes. More...
| 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.

Examples
  /Users/ec2-user/gitlab-runner/builds/E-xKdhDo/0/foxit/sdk/mobile/gsdk-doc-auto-build/harmony_nodejs/input/Index.js.

## Member Function Documentation

## ◆ constructor()

StdEncryptData.constructor | ( | is_encrypt_metadata | ,
|  | user_permissions | ,
|  | cipher | ,
|  | key_length |
| ) |  |

Constructor, with parameters.

Parameters

  [in] | is_encrypt_metadata | true means to encrypt metadata, and false means not to encrypt metadata.
  [in] | user_permissions | The user permissions. Please refer to values starting from PDFDoc.e_PermPrint and this should be one or combination of these values.
  [in] | cipher | Cipher type. Please refer to values starting from SecurityHandler.e_CipherRC4 and this should be one of these values except SecurityHandler.e_CipherNone.
  [in] | key_length | The key length, in bytes. For SecurityHandler.e_CipherRC4 cipher, this value should be between 5 and 16. The preferred one should be 16. For SecurityHandler.e_CipherAES cipher, this value should be 16 (as AES-128) or 32 (as AES-256, only supported in PDF 2.0).

## ◆ Set()

StdEncryptData.Set | ( | is_encrypt_metadata | ,
|  | user_permissions | ,
|  | cipher | ,
|  | key_length |
| ) |  |

Set value.

Parameters

  [in] | is_encrypt_metadata | true means to encrypt metadata, and false means not to encrypt metadata.
  [in] | user_permissions | The user permissions. Please refer to values starting from PDFDoc.e_PermPrint and this should be one or combination of these values.
  [in] | cipher | Cipher type. Please refer to values starting from SecurityHandler.e_CipherRC4 and this should be one of these values except SecurityHandler.e_CipherNone.
  [in] | key_length | The key length, in bytes. For SecurityHandler.e_CipherRC4 cipher, this value should be between 5 and 16. The preferred one should be 16. For SecurityHandler.e_CipherAES cipher, this value should be 16 (as AES-128) or 32 (as AES-256, only supported in PDF 2.0).

Returns
  None.

Examples
  /Users/ec2-user/gitlab-runner/builds/E-xKdhDo/0/foxit/sdk/mobile/gsdk-doc-auto-build/harmony_nodejs/input/Index.js.

## Member Data Documentation

## ◆ key_length

StdEncryptData.key_length

The key length, in bytes.

- For SecurityHandler.e_CipherRC4 cipher, this value should be between 5 and 16. The preferred one should be 16.
- For SecurityHandler.e_CipherAES cipher, this value should be 16 (as AES-128) or 32 (as AES-256, only supported in PDF 2.0).

Examples
  /Users/ec2-user/gitlab-runner/builds/E-xKdhDo/0/foxit/sdk/mobile/gsdk-doc-auto-build/harmony_nodejs/input/Index.js.