utility to load with cache logic More...
#include "ZFCache.h"
Go to the source code of this file.
Classes | |
class | ZFIOCache |
cache config and holder for ZFIOCacheLoad More... | |
class | ZFIOCacheLoadTask |
io load task More... | |
Functions | |
zfautoT< ZFTaskId > | ZFIOCacheLoad (const ZFInput &src, const ZFListener &callback, const ZFListener &loadImpl=(zft_zfnull)) |
load contents with cache logic | |
utility to load with cache logic
|
extern |
load contents with cache logic
useful to load contents from slow src input (http for example), load src to local temp file and load it in background thread, use ZFIOCache to config the cache logic
callback's param0 would be the result object if success, param1 would be a ZFResultType indicates load result
the loadImpl's param0 would be a ZFInput points to local cache file or original src, param1 would be the original src input, and should set ZFArgs::result to non null object as result, which would passed to callback