source: FTPfs/curlftpfs-0.9.1/cache.h @ 136

Last change on this file since 136 was 10, checked in by zsjheng, 17 years ago
File size: 1.1 KB
RevLine 
[10]1#ifndef __CURLFTPFS_CACHE_H__
2#define __CURLFTPFS_CACHE_H__
3
4/*
5    Caching file system proxy
6    Copyright (C) 2004  Miklos Szeredi <miklos@szeredi.hu>
7
8    This program can be distributed under the terms of the GNU GPL.
9    See the file COPYING.
10*/
11
12#include <fuse.h>
13#include <fuse_opt.h>
14
15#ifndef FUSE_VERSION
16#define FUSE_VERSION (FUSE_MAJOR_VERSION * 10 + FUSE_MINOR_VERSION)
17#endif
18
19typedef struct fuse_cache_dirhandle *fuse_cache_dirh_t;
20typedef int (*fuse_cache_dirfil_t) (fuse_cache_dirh_t h, const char *name,
21                                    const struct stat *stbuf);
22
23struct fuse_cache_operations {
24    struct fuse_operations oper;
25    int (*cache_getdir) (const char *, fuse_cache_dirh_t, fuse_cache_dirfil_t);
26};
27
28struct fuse_operations *cache_init(struct fuse_cache_operations *oper);
29int cache_parse_options(struct fuse_args *args);
30void cache_add_attr(const char *path, const struct stat *stbuf);
31void cache_add_dir(const char *path, char **dir);
32void cache_add_link(const char *path, const char *link, size_t size);
33
34#endif   /* __CURLFTPFS_CACHE_H__ */
Note: See TracBrowser for help on using the repository browser.