Documentation
¶
Overview ¶
Package fscache implements a file system-based store.Cache.
Entries are stored as files in a directory under the user's OS cache directory by default. The cache location is configured via URL; see Open for details.
Users should call [fsCache.Close] on the cache when done to release resources promptly.
Index ¶
Constants ¶
View Source
const Scheme = "fscache" // url scheme for the file system cache
Variables ¶
Functions ¶
func Open ¶
Open creates a new file system cache from the provided URL.
The URL path sets the base directory (defaults to the user's OS cache dir if empty). The "appname" query parameter is required and specifies a subdirectory.
Examples:
fscache://?appname=myapp → <user cache dir>/myapp fscache:///tmp/cache?appname=myapp → /tmp/cache/myapp
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.