Crinit::CacheStore
Manages content-addressed local caching for remote assets based on SHA-256 digests.
Constants
SHA256_PATTERN = /\A[0-9a-fA-F]{64}\z/
Constructors
from_config(config : Config) : CacheStore
SourceClass methods
default_base_cache_dir
SourceValidates whether a string matches standard 64-character hexadecimal SHA-256 formatting.
Instance methods
cache_dir
SourceRetrieves the path to the cached asset, or nil if absent or corrupted.
Checks whether an asset with the given SHA-256 is present and uncorrupted in the cache.