Foxit PDF SDK

Public Member Functions | Static Public Member Functions | List of all members
com.foxit.sdk.common.Codec Class Reference
Inheritance diagram for com.foxit.sdk.common.Codec:

## Public Member Functions
synchronized void | delete ()
| Clean up related C++ resources immediately. More...
Public Member Functions inherited from com.foxit.sdk.common.Base
synchronized void | delete ()
| Clean up related C++ resources immediately. More...

## Static Public Member Functions
static byte [] | base64Decode (byte[] encoded_data_buffer)
| Decode the encoded data buffer by Base64 algorithm. More...
static byte [] | base64Encode (byte[] data_buffer)
| Encode the source data buffer by Base64 algorithm. More...
static byte [] | flateCompress (byte[] data_buffer)
| Compress the source data buffer by DEFLATE algorithm. More...
static byte [] | flateDecompress (byte[] compressed_data_buffer)
| Decompress the compressed data buffer by DEFLATE algorithm. More...

## Detailed Description

This class provides utility functions such as encoding or compression. Foxit PDF SDK library should has been initialized successfully by function Library.initialize before calling any function of this class.

## Member Function Documentation

## ◆ base64Decode()

static byte[] com.foxit.sdk.common.Codec.base64Decode | ( | byte [] | encoded_data_buffer | ) |
| static

Decode the encoded data buffer by Base64 algorithm.

Parameters

  [in] | encoded_data_buffer | The encoded source data buffer.

Returns
  The decoded data.

## ◆ base64Encode()

static byte[] com.foxit.sdk.common.Codec.base64Encode | ( | byte [] | data_buffer | ) |
| static

Encode the source data buffer by Base64 algorithm.

Parameters

  [in] | data_buffer | The raw source data buffer.

Returns
  The encoded data.

## ◆ delete()

synchronized void com.foxit.sdk.common.Codec.delete | ( |  | ) |

Clean up related C++ resources immediately.

Returns
  None.

Note
  Once this function is called, current object cannot be used anymore.

## ◆ flateCompress()

static byte[] com.foxit.sdk.common.Codec.flateCompress | ( | byte [] | data_buffer | ) |
| static

Compress the source data buffer by DEFLATE algorithm.

Parameters

  [in] | data_buffer | The raw source data buffer.

Returns
  The compressed data.

## ◆ flateDecompress()

static byte[] com.foxit.sdk.common.Codec.flateDecompress | ( | byte [] | compressed_data_buffer | ) |
| static

Decompress the compressed data buffer by DEFLATE algorithm.

Parameters

  [in] | compressed_data_buffer | The compressed source data buffer.

Returns
  The decompressed data.