51 response_close_func response_close; |
53 response_close_func response_close; |
52 |
54 |
53 VFS_DIR parent; /* current directory */ |
55 VFS_DIR parent; /* current directory */ |
54 struct stat *stat; /* current stat object */ |
56 struct stat *stat; /* current stat object */ |
55 }; |
57 }; |
|
58 |
|
59 struct WebdavVFSOperation { |
|
60 WebdavBackend *dav; |
|
61 Request *rq; |
|
62 Session *sn; |
|
63 |
|
64 VFSContext *vfs; |
|
65 |
|
66 char *path; |
|
67 struct stat *stat; |
|
68 int stat_errno; |
|
69 }; |
|
70 |
|
71 enum WebdavVFSOpType { |
|
72 WEBDAV_VFS_MKDIR = 0, |
|
73 WEBDAV_VFS_DELETE |
|
74 }; |
|
75 |
|
76 typedef enum WebdavVFSOpType WebdavVFSOpType; |
|
77 |
|
78 typedef int(*vfs_op_func)(WebdavVFSRequest *, WSBool *); |
|
79 typedef int(*vfs_op_finish_func)(WebdavVFSRequest *, WSBool); |
56 |
80 |
57 /* |
81 /* |
58 * counts the number of backends |
82 * counts the number of backends |
59 */ |
83 */ |
60 size_t webdav_num_backends(WebdavBackend *dav); |
84 size_t webdav_num_backends(WebdavBackend *dav); |
99 |
123 |
100 int webdav_op_proppatch_close_resource( |
124 int webdav_op_proppatch_close_resource( |
101 WebdavOperation *op, |
125 WebdavOperation *op, |
102 WebdavResource *resource); |
126 WebdavResource *resource); |
103 |
127 |
|
128 |
|
129 WebdavVFSOperation* webdav_vfs_op( |
|
130 Session *sn, |
|
131 Request *rq, |
|
132 WebdavBackend *dav, |
|
133 WSBool precondition); |
|
134 |
|
135 int webdav_vfs_stat(WebdavVFSOperation *op); |
|
136 |
|
137 int webdav_vfs_op_do(WebdavVFSOperation *op, WebdavVFSOpType type); |
|
138 |
|
139 int webdav_vfs_unlink(WebdavVFSOperation *op); |
|
140 |
104 #ifdef __cplusplus |
141 #ifdef __cplusplus |
105 } |
142 } |
106 #endif |
143 #endif |
107 |
144 |
108 #endif /* OPERATION_H */ |
145 #endif /* OPERATION_H */ |