FileSystem.open

Open a file.

Open flags are available in fi.flags. The following rules apply.

- If O_CREAT is used and the file doesn't exist, create() is called.

- Access modes (O_RDONLY, O_WRONLY, O_RDWR, O_EXEC, O_SEARCH) should be used by the filesystem to check if the operation is permitted. If the -o default_permissions mount option is given, this check is already done by the kernel before calling open() and may thus be omitted by the filesystem.

Filesystem may store an arbitrary file handle (pointer, index, etc.) in fi.fh, and use this in other all other file operations (read, write, flush, release, fsync).

Filesystem may also implement stateless file I/O and not store anything in fi.fh.

There are also some flags (direct_io, keep_cache) which the filesystem may set in fi, to change the way the file is opened. See fuse_file_info (ffi_t) structure for more details.

If this request is answered with an error code of ENOTSUP and FUSE_CAP_NO_OPEN_SUPPORT is set in fuse_conn_info.capable, this is treated as success and future calls to open will also succeed without being send to the filesystem process.

class FileSystem
@null
void
open
(
string path
,)

Meta