fixnuta buga v remove_last (nesnizovala grow ptr, ktery tak ubiral znaky a nemenil...
[httpfs.git] / cache.h
blob1a4dcdcf6822e548bc4b73a531173b61def387d1
1 /*
2 Caching file system proxy
3 Copyright (C) 2004 Miklos Szeredi <miklos@szeredi.hu>
5 This program can be distributed under the terms of the GNU GPL.
6 See the file COPYING.
7 */
9 #include <fuse.h>
10 #include <fuse_opt.h>
12 #ifndef FUSE_VERSION
13 #define FUSE_VERSION (FUSE_MAJOR_VERSION * 10 + FUSE_MINOR_VERSION)
14 #endif
16 typedef struct fuse_cache_dirhandle *fuse_cache_dirh_t;
17 typedef int (*fuse_cache_dirfil_t) (fuse_cache_dirh_t h, const char *name,
18 const struct stat *stbuf);
20 struct fuse_cache_operations {
21 struct fuse_operations oper;
22 int (*cache_getdir) (const char *, fuse_cache_dirh_t, fuse_cache_dirfil_t);
25 struct fuse_operations *cache_init(struct fuse_cache_operations *oper);
26 int cache_parse_options(struct fuse_args *args);
27 void cache_add_attr(const char *path, const struct stat *stbuf, int weak);
28 void cache_invalidate(const char *path);