Foxit PDF Conversion SDK

Public Member Functions | List of all members
com.foxit.sdk.common.fxcrt.FileWriterCallback Class Reference

File writing interface. More...

## Public Member Functions
boolean | flush ()
| Flush internal buffer of the file. More...
int | getSize ()
| Get total size of the file. More...
void | release ()
| Called when to release everything.
boolean | writeBlock (byte[] pData, int offset, long size)
| Write a block data. More...

## Detailed Description

File writing interface.

## Member Function Documentation

## ◆ flush()

boolean com.foxit.sdk.common.fxcrt.FileWriterCallback.flush | ( |  | ) |

Flush internal buffer of the file.

Returns
  true means success, while false means failure.

## ◆ getSize()

int com.foxit.sdk.common.fxcrt.FileWriterCallback.getSize | ( |  | ) |

Get total size of the file.

Returns
  File size, in bytes. Implementation can return 0 for any error.

## ◆ writeBlock()

boolean com.foxit.sdk.common.fxcrt.FileWriterCallback.writeBlock | ( | byte [] | pData,
|  | int | offset,
|  | long | size
| ) |  |

Write a block data.

Parameters

  [in] | pData | The block data.
  [in] | offset | Byte offset from beginning of the file
  [in] | size | The length in bytes of the block data.

Returns
  true means success, while false means failure.