libtransistor
A userland library for the Nintendo Switch
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros
fs.h
Go to the documentation of this file.
1 
26 #pragma once
27 
28 #ifdef __cplusplus
29 extern "C" {
30 #endif
31 
32 #include<libtransistor/types.h>
34 
35 #include<sys/stat.h>
36 
60 
82 result_t trn_fs_mount(const char *name, trn_inode_t root);
83 
84 // The rest of those functions should probably not be directly used. Instead,
85 // use the standard posix calls of the same name...
86 // Maybe we should still document them
87 result_t trn_fs_realpath(const char *path, char **resolved_path);
88 result_t trn_fs_open(int *fd, const char *path, int flags);
89 result_t trn_fs_opendir(trn_dir_t *dir, const char *path);
90 result_t trn_fs_mkdir(const char *path);
91 result_t trn_fs_rename(const char *oldpath, const char *newpath);
92 result_t trn_fs_unlink(const char *path);
93 result_t trn_fs_rmdir(const char *path);
94 result_t trn_fs_chdir(const char *path);
95 result_t trn_fs_stat(const char *path, struct stat *st);
96 
97 #ifdef __cplusplus
98 }
99 #endif
Definition: inode.h:33
Various system types.
result_t trn_fs_mount(const char *name, trn_inode_t root)
Mount a filesystem.
uint32_t result_t
Function result.
Definition: types.h:51
Definition: inode.h:17
Inode structures and functions for virtual filesystem.
result_t trn_fs_set_root(trn_inode_t *new_root)
Change filesystem root.