SkinFileCache class

Disk cache of self-contained skin files, keyed by skin id + version: <cacheRoot>/digia-engage-skins/<safeSkinId>/<version>/index.html.

A hit touches the file's mtime; every write evicts oldest-mtime entries until the total is under the cap. Writes go to a temp file with an atomic rename. Reads never throw: a failure is a miss and the host falls back to the CDN.

Constructors

SkinFileCache(Future<Directory> cacheRoot(), {int maxBytes = skinCacheMaxBytes})

Properties

hashCode → int
The hash code for this object.
no setterinherited
maxBytes → int
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited

Methods

isComplete(String skinId, int version) → Future<bool>
lookup(String bundleUrl) → Future<CachedAsset?>
The cached skin for bundleUrl, or null on any miss or failure.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
store(String skinId, int version, List<int> bytes) → Future<bool>
Stores one downloaded skin file, then evicts oldest-mtime entries until under the cap. Returns false (and publishes nothing) when the bytes are empty or over the per-file max.
toString() → String
A string representation of this object.
inherited

Operators

operator ==(Object other) → bool
The equality operator.
inherited