THPDFCacheAdmissionPolicy Record
Describes the admission policy of one render cache layer: enablement, adaptive frequency mode and entry, total-byte and per-entry byte ceilings
Declaration
THPDFCacheAdmissionPolicy= record
Enabled: boolean;
AdaptiveAdmission: boolean;
MaxEntries: Integer;
MaxTotalBytes: Int64;
MaxEntryBytes: Int64;
end;
Unit
HPDFDoc
Fields
| Field | Purpose |
|---|---|
Enabled | Turns admission control on for the layer; an enabled policy must carry positive limits or validation raises ERangeError |
AdaptiveAdmission | Enables frequency-based adaptive admission so rarely reused entries are refused instead of evicted later |
MaxEntries | Maximum cached entries, validated from 0 to 1000000; for the raster layer it mirrors RenderCacheCapacity |
MaxTotalBytes | Maximum total cached bytes; for the decoded-image layer it mirrors ImageCacheMaxBytes |
MaxEntryBytes | Maximum size of a single cacheable item; must not exceed MaxTotalBytes, and the raw-compressed layer restricts it to 4096-16777216 bytes |
Usage notes
- Configure one record per
THPDFCacheLayerKindthroughTHotPDF.SetCacheAdmissionPolicy; the values are validated and applied at once - Read the active configuration back with
THotPDF.GetCacheAdmissionPolicy, which copies the stored policy for the requested layer - Use
THotPDF.GetCacheAdmissionStatisticsto compare these limits against live hit, miss and eviction counters