DirCacheBase

Base class for a simple directory store.

Constructors

this
this(string cacheDir, ICacheHost cacheHost)
Undocumented in source.

Members

Functions

add
void add(string key, string sourcePath)
Undocumented in source. Be warned that the author may not have intended to support it.
extract
void extract(string key, string targetPath, bool delegate(string) pathFilter)
Undocumented in source. Be warned that the author may not have intended to support it.
getEntries
string[] getEntries()
Undocumented in source. Be warned that the author may not have intended to support it.
haveEntry
bool haveEntry(string key)
Undocumented in source. Be warned that the author may not have intended to support it.
listFiles
string[] listFiles(string key)
Undocumented in source. Be warned that the author may not have intended to support it.
optimizeKey
void optimizeKey(string key)
Undocumented in source.
remove
void remove(string key)
Undocumented in source. Be warned that the author may not have intended to support it.

Inherited Members

From DCache

cacheDir
string cacheDir;

Directory which will hold the cached builds.

host
ICacheHost host;

Callback interface.

name
string name [@property getter]

Get name of this cache engine.

getEntries
string[] getEntries()

Get a list of keys for all cached entries.

haveEntry
bool haveEntry(string key)

Check if an entry with the given key exists.

listFiles
string[] listFiles(string key)

Get the full file listing for the given cache entry. Forward slashes only.

add
void add(string key, string sourcePath)

Add files from a directory. This operation is destructive: the cache implementation is allowed to modify the source directory.

extract
void extract(string key, string targetPath, bool delegate(string) pathFilter)

Extract a cache entry to a target directory, with a filter for root files/directories.

remove
void remove(string key)

Delete a cache entry.

finalize
void finalize()

Close the cache. Called after all operations are completed and the cache is no longer immediately needed.

optimize
void optimize()

Optimize the cache (minimize disk space). This operation can be very slow (and should display progress).

verify
void verify()

Verify cache integrity.

cp
void cp(string src, string dst, bool silent)

Utility function (copy file or directory)

Meta