PSPDFInstantDocumentCacheEntry
Objective-C
@protocol PSPDFInstantDocumentCacheEntry <NSObject>
Swift
protocol InstantDocumentCacheEntry : NSObjectProtocol
A snapshot of the disk cache entry for a certain document identifier.
Keeping these objects around after their creation does not do any harm. As snapshots, however, they do not track
changes to the disk cache over time. Because the overallDiskSpace
is typically dominated by the size of the PDF — not
the annotation data stored in any layer — its order of magnitude should be fairly stable, though. Notable exceptions
would be scratch-pad style documents that contain mostly empty pages, or documents with many layers containing loads
of annotations each.
-
The document identifier corresponding to this cache entry.
Declaration
Objective-C
@property (nonatomic, readonly) NSString *_Nonnull documentIdentifier;
Swift
var documentIdentifier: String { get }
-
The disk space (in bytes) occupied by the document and all its downloaded layers.
Declaration
Objective-C
@property (nonatomic, readonly) unsigned long long overallDiskSpace;
Swift
var overallDiskSpace: UInt64 { get }
-
The names of all downloaded layers — may be empty!
Declaration
Objective-C
@property (nonatomic, readonly) NSSet<NSString *> *_Nonnull downloadedLayerNames;
Swift
var downloadedLayerNames: Set<String> { get }
-
Diagnostic information about the receiver.
Declaration
Objective-C
@property (nonatomic, readonly) PSPDFInstantCacheEntryState entryState;
Swift
var entryState: InstantCacheEntryState { get }