2019-03-24 01:03:31 +00:00
|
|
|
#ifndef WSFS_ADAPTER_IMPL_FILESYSTEM_H
|
|
|
|
#define WSFS_ADAPTER_IMPL_FILESYSTEM_H
|
2019-02-05 23:58:51 +00:00
|
|
|
|
2019-02-09 02:08:02 +00:00
|
|
|
#ifndef __cplusplus
|
|
|
|
#include <stdbool.h>
|
|
|
|
#endif
|
|
|
|
|
2019-03-24 00:15:29 +00:00
|
|
|
#include "wsfs/adapter/impl/fuse_wrapper.h"
|
|
|
|
#include "wsfs/adapter/impl/operations.h"
|
2019-02-05 23:58:51 +00:00
|
|
|
|
2019-03-24 01:10:03 +00:00
|
|
|
#ifdef __cplusplus
|
|
|
|
extern "C"
|
|
|
|
{
|
|
|
|
#endif
|
|
|
|
|
2019-03-24 02:25:29 +00:00
|
|
|
struct jsonrpc_server;
|
2019-02-09 02:08:02 +00:00
|
|
|
|
2019-03-24 02:25:29 +00:00
|
|
|
struct filesystem
|
2019-02-05 23:58:51 +00:00
|
|
|
{
|
|
|
|
struct fuse_args args;
|
|
|
|
struct fuse_session * session;
|
|
|
|
struct fuse_buf buffer;
|
2019-03-24 02:25:29 +00:00
|
|
|
struct operations_context user_data;
|
2019-02-05 23:58:51 +00:00
|
|
|
};
|
|
|
|
|
2019-03-24 02:25:29 +00:00
|
|
|
extern bool filesystem_init(
|
|
|
|
struct filesystem * filesystem,
|
|
|
|
struct jsonrpc_server * rpc,
|
2019-02-05 23:58:51 +00:00
|
|
|
char * mount_point);
|
|
|
|
|
2019-03-24 02:25:29 +00:00
|
|
|
extern void filesystem_cleanup(
|
|
|
|
struct filesystem * filesystem);
|
2019-02-05 23:58:51 +00:00
|
|
|
|
2019-03-24 02:25:29 +00:00
|
|
|
extern int filesystem_get_fd(
|
|
|
|
struct filesystem * filesystem);
|
2019-02-05 23:58:51 +00:00
|
|
|
|
2019-03-24 02:25:29 +00:00
|
|
|
extern void filesystem_process_request(
|
|
|
|
struct filesystem * filesystem);
|
2019-02-05 23:58:51 +00:00
|
|
|
|
2019-02-09 02:08:02 +00:00
|
|
|
#ifdef __cplusplus
|
|
|
|
}
|
|
|
|
#endif
|
|
|
|
|
|
|
|
|
2019-02-05 23:58:51 +00:00
|
|
|
#endif
|