DAWaitForRangeSourcePrefetch
Direct access functionality, Progressive loading, Synchronization
Description
Waits for a direct-access prefetch job to reach a terminal state
Syntax
Delphi
Function TPDFlib.DAWaitForRangeSourcePrefetch(FileHandle,
JobHandle: Integer; TimeoutMS: Cardinal= INFINITE): Integer;Parameters
| FileHandle | Direct-access handle returned by DAOpenFile or DAOpenFromStream whose reader is backed by TByteRangeStream |
|---|---|
| JobHandle | Job handle returned by DAStartRangeSourcePrefetch for the same file handle |
| TimeoutMS | Maximum wait in milliseconds; the default INFINITE waits until a terminal state is reached |
Return values
Returns a PDF_RANGE_PREFETCH_STATE_* terminal state, or zero for a timeout or invalid handle
Invalid handles set LastErrorCode to 401 while a timeout leaves it at zero