aboutsummaryrefslogtreecommitdiffstats
path: root/lib/kernel/doc/src/file.xml
AgeCommit message (Collapse)Author
2011-06-20Add more specs and typesHans Bolinder
An incorrect spec, rpc:yield/1, has been fixed.
2011-05-11Use Erlang specs and types for documentationHans Bolinder
2010-12-10Fix a couple typos in filename encoding docsTuncer Ayaz
2010-12-01Add documentation about raw filenames and Unicode file name translation modePatrik Nyblom
2010-10-14Add the {encoding, _} options to file:open/2's modesKostis Sagonas
Although the {encoding, encoding()} set of options is documented in the manual page of the 'file' module, they do not appear in the Mode description on that page nor in the mode() type declaration. The patch adds this information in both the code of the module and the documentation of the module. To avoid duplication, the declaration of the encoding() type is added to the 'unicode' module where it most probably belongs. While at it, added a proper declaration for posix(), took out the now superfluous information about the types of file:open/2 from the erl_bif_types module, and corrected the return type of file:open/2 so that it corresponds to the published documentation.
2010-06-11Correct trivial typos in file manualTuncer Ayaz
Signed-off-by: Tuncer Ayaz <[email protected]>
2010-06-04Support opening files in exclusive modeMichael Santos
Add an option that atomically tests for the existence of a file and creates it if the file does not exist, by passing the O_EXCL flag to open() on Unix and CREATE_NEW flag on Windows. Support for O_EXCL varies across platforms and filesystems. {ok, Fd} = file:open("/tmp/foo", [write,exclusive]), {error, eexist} = file:open("/tmp/foo", [write,exclusive]).
2010-05-20Add file:advise/4 - a wrapper to the POSIX syscall posix_fadviseFilipe David Manana
Useful for informing the Operating System about the access pattern for a file's data, so that it can adapt the caching strategy to maximize disk IO performance.
2010-05-20Add file:datasync/1 for syncing file contents onlyFilipe David Manana
file:datasync/1 invokes the POSIX system call "int fdatasync(int fd)". This system call is similar to "fsync" but, unlike fsync, it does not update the metadata associated with the file (like the access time for example). It's used by many DBMSs (MySQL and SQLite of example) to increase disk IO performance, as it avoids disk seeks and disk write operations compared to fsync. More details on it at: http://linux.die.net/man/2/fdatasync An example, from the MySQL source: http://bazaar.launchpad.net/~mysql/mysql-server/mysql-5.1-telco-6.1/annotate/head%3A/mysys/my_sync.c#L61 This new function just calls fsync on systems not implementing fdatasync.
2010-03-19kernel: document the file:change_mode/2 functionAndrey Pampukha
2009-12-03Corrected CR and LF clarification in file:read_line, removed extra backslash.Patrik Nyblom
2009-11-20The R13B03 release.OTP_R13B03Erlang/OTP