12typedef struct VFSDir VFSDir;
13typedef struct VFSVFS VFSVFS;
14typedef struct VFSVFS_WeakRef VFSVFS_WeakRef;
17#define _sti_VFSVFS _sti_object
18#define SType_VFSVFS VFSVFS*
19#define STStorageType_VFSVFS VFSVFS*
20#define STypeArg_VFSVFS(type, val) stgeneric(object, (ObjInst*)objInstCheckClass(VFSVFS, val))
21#define STypeArgPtr_VFSVFS(type, val) (stgeneric*)objInstCheckClassPtr(VFSVFS, val)
22#define STypeCheckedArg_VFSVFS(type, val) stType(type), stArg(type, val)
23#define STypeCheckedPtrArg_VFSVFS(type, val) stType(type), stArgPtr(type, val)
25typedef struct VFSVFS_ClassIf {
31 flags_t (*flags)(_In_
void* self);
33 _Ret_opt_valid_
File* (*open)(_In_
void* self, _In_opt_ strref path, flags_t flags);
35 bool (*setTimes)(_In_
void* self, _In_opt_ strref path, int64 modified, int64 accessed);
36 bool (*createDir)(_In_
void* self, _In_opt_ strref path);
37 bool (*removeDir)(_In_
void* self, _In_opt_ strref path);
38 bool (*deleteFile)(_In_
void* self, _In_opt_ strref path);
39 bool (*rename)(_In_
void* self, _In_opt_ strref oldpath, _In_opt_ strref newpath);
40 bool (*getFSPath)(_In_
void* self, _Inout_
string* out, _In_opt_ strref path);
41 bool (*searchInit)(_In_
void* self, _Out_
FSSearchIter* iter, _In_opt_ strref path, _In_opt_ strref pattern,
bool stat);
42 bool (*searchValid)(_In_
void* self, _In_
FSSearchIter* iter);
43 bool (*searchNext)(_In_
void* self, _Inout_
FSSearchIter* iter);
44 void (*searchFinish)(_In_
void* self, _Inout_
FSSearchIter* iter);
46extern VFSVFS_ClassIf VFSVFS_ClassIf_tmpl;
48typedef struct VFSVFS {
62#define VFSVFS(inst) objInstCheckClass(VFSVFS, inst)
63#define VFSVFSNone ((VFSVFS*)NULL)
65typedef struct VFSVFS_WeakRef {
68 void* _is_VFSVFS_WeakRef;
69 void* _is_ObjInst_WeakRef;
74#define VFSVFS_WeakRef(inst) objWeakRefCheckClass(VFSVFS, inst)
78#define vfsvfsCreate(vfs, rootpath) VFSVFS_create(VFS(vfs), rootpath)
83#define vfsvfsFlags(self) (self)->_->flags(VFSVFS(self))
87#define vfsvfsOpen(self, path, flags) (self)->_->open(VFSVFS(self), path, flags)
89#define vfsvfsStat(self, path, stat) (self)->_->stat(VFSVFS(self), path, stat)
91#define vfsvfsSetTimes(self, path, modified, accessed) (self)->_->setTimes(VFSVFS(self), path, modified, accessed)
93#define vfsvfsCreateDir(self, path) (self)->_->createDir(VFSVFS(self), path)
95#define vfsvfsRemoveDir(self, path) (self)->_->removeDir(VFSVFS(self), path)
97#define vfsvfsDeleteFile(self, path) (self)->_->deleteFile(VFSVFS(self), path)
99#define vfsvfsRename(self, oldpath, newpath) (self)->_->rename(VFSVFS(self), oldpath, newpath)
101#define vfsvfsGetFSPath(self, out, path) (self)->_->getFSPath(VFSVFS(self), out, path)
103#define vfsvfsSearchInit(self, iter, path, pattern, stat) (self)->_->searchInit(VFSVFS(self), iter, path, pattern, stat)
105#define vfsvfsSearchValid(self, iter) (self)->_->searchValid(VFSVFS(self), iter)
107#define vfsvfsSearchNext(self, iter) (self)->_->searchNext(VFSVFS(self), iter)
109#define vfsvfsSearchFinish(self, iter) (self)->_->searchFinish(VFSVFS(self), iter)
#define saDeclarePtr(name)
enum FSPathStatEnum FSPathStat
@ FS_Nonexistent
Path does not exist.
#define _objfactory_guaranteed
CX Struct System - Introspectable, serializable POD structures in C.
CX Object System - Object-oriented programming in C.