Foxit PDF Conversion SDK

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

File reading interface. More...

## Public Member Functions
int | getSize ()
| Get total size of the file. More...
boolean | readBlock (byte[] buffer, int offset, long size)
| Read a data block from the file. More...
void | release ()
| Called when to release everything. More...

## Detailed Description

File reading interface.

## Member Function Documentation

## ◆ getSize()

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

Get total size of the file.

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

## ◆ readBlock()

boolean com.foxit.sdk.common.fxcrt.FileReaderCallback.readBlock | ( | byte [] | buffer,
|  | int | offset,
|  | long | size
| ) |  |

Read a data block from the file.

Parameters

  [in,out] | buffer | Pointer to a buffer receiving read data
  [in] | offset | Byte offset from beginning of the file
  [in] | size | Number of bytes for the block.

Returns
  true means success, and false means failure.

## ◆ release()

void com.foxit.sdk.common.fxcrt.FileReaderCallback.release | ( |  | ) |

Called when to release everything.

Returns
  None.