THPDFMappedFileStatistics 记录
报告内存映射文件源在加载期间收集的配置、几何、映射、缓存与传输遥测
声明
THPDFMappedFileStatistics= record
FileSize: Int64;
ConfiguredWindowSize: Int64;
ConfiguredCacheWindowCount: Integer;
WindowSize: Int64;
CacheWindowCount: Integer;
MappedByteLimit: Int64;
CurrentMappedBytes: Int64;
PeakMappedBytes: Int64;
GeometryChangeCount: Int64;
SequentialReadCalls: Int64;
RandomReadCalls: Int64;
AdaptiveGeometry: Boolean;
SequentialGeometryActive: Boolean;
RandomGeometryActive: Boolean;
ReadCalls: Int64;
BytesRead: Int64;
MapCount: Int64;
CacheHits: Int64;
FallbackReadCalls: Int64;
FallbackBytes: Int64;
DirectTransferCalls: Int64;
DirectTransferBytes: Int64;
end;
单元
HPDFObjs
字段
| 字段 | 用途 |
|---|---|
FileSize | 被映射源文件的大小(字节) |
ConfiguredWindowSize | 通过 LocalFileMappingWindowSize 配置的窗口大小 |
ConfiguredCacheWindowCount | 通过 LocalFileMappingCacheWindows 配置的常驻窗口数 |
WindowSize | 该源实际生效的窗口大小 |
CacheWindowCount | 窗口缓存当前持有的窗口数 |
MappedByteLimit | 源同时保持映射的字节数上限 |
CurrentMappedBytes | 当前映射的字节数 |
PeakMappedBytes | 整个加载过程中映射字节的峰值 |
GeometryChangeCount | 自适应几何切换窗口布局的次数 |
SequentialReadCalls | 被归类为顺序访问的读取请求数 |
RandomReadCalls | 被归类为随机访问的读取请求数 |
AdaptiveGeometry | 源启用了自适应几何选择时为 True |
SequentialGeometryActive | 顺序窗口几何处于活动状态时为 True |
RandomGeometryActive | 随机访问窗口几何处于活动状态时为 True |
ReadCalls | 通过映射源服务的读取请求总数 |
BytesRead | 这些读取交付的字节总数 |
MapCount | 文件视图映射进窗口的次数 |
CacheHits | 由已常驻窗口满足的读取数 |
FallbackReadCalls | 回退为窗口缓存之外普通文件读取的次数 |
FallbackBytes | 回退读取交付的字节数 |
DirectTransferCalls | 绕过窗口缓存的流到流直接传输次数 |
DirectTransferBytes | 直接传输移动的字节数 |
使用说明
- 用
THotPDF.GetLastMappedFileStatistics读取该记录;只有最近一次加载确实使用了内存映射时才返回 True - 加载之前用
LocalFileMappingWindowSize、LocalFileMappingCacheWindows和LocalFileMappingAdaptiveGeometry调整几何参数 SequentialGeometryActive和RandomGeometryActive是当前模式的互斥快照