DAGetRangeSourceDataAvailability

Direct access functionality, Progressive loading, Diagnostics

Description

Returns the same dependency and byte-range availability result as GetRangeSourceDataAvailability for a direct-access handle

Syntax

Delphi

Function TPDFlib.DAGetRangeSourceDataAvailability(FileHandle, DataKind,
  Index: Integer; Out Report: WideString): Integer;

Parameters

FileHandleA direct-access handle opened from a byte-range stream or URL
DataKindPDF_RANGE_DATA_PAGE, PDF_RANGE_DATA_FORM or PDF_RANGE_DATA_OBJECT
IndexA one-based page number, zero for the form query, or an indirect object number
ReportReceives the JSON dependency and byte-range report

Return values

-1The handle, source, arguments or PDF structure are invalid
0At least one required range is not yet available
1The complete dependency graph is available
2The form query completed and the document has no AcroForm

Remarks

The handle must be backed by TByteRangeStream

For a URL-backed handle, only ranges already retained by the byte-range cache are immediately available; the query never starts a network request

Missing ranges are reported without being read