GetResourceUsageStatisticsJSON
Diagnostics, performance
Description
Returns one JSON object with structure, stream, image, font and cache statistics across documents owned by the library instance
Syntax
Delphi
Function TPDFlib.GetResourceUsageStatisticsJSON: WideString;Return values
A JSON object containing object and resource counts, estimated structure bytes, encoded and decoded stream bytes, parser and stream failures, peak decoded-stream size, and object, object-stream and display-list cache statistics
Remarks
estimatedBytes covers owned PDF object structures and excludes allocator metadata, renderer surfaces and third-party native allocations
operationDecodedBytes is reset automatically at the start of each tracked operation, while totalDecodedBytes continues until ResetResourceUsageStatistics is called
objectStreamCache includes current decoded payload and offset-table bytes, maxBytesPerDocument, and cumulative evictions alongside entries, hits and misses
displayListCache includes retained bytes, entry and byte limits, estimated replayCost, evictions, oversized bypasses, rejected incomplete captures and concurrent build contention