man-pages/man3/Unix.LargeFile.3o.html
2021-03-31 01:06:50 +01:00

218 lines
3.1 KiB
HTML

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<HTML><HEAD><TITLE>Man page of Unix.LargeFile</TITLE>
</HEAD><BODY>
<H1>Unix.LargeFile</H1>
Section: OCaml library (3o)<BR>Updated: 2020-01-30<BR><A HREF="#index">Index</A>
<A HREF="/cgi-bin/man/man2html">Return to Main Contents</A><HR>
<A NAME="lbAB">&nbsp;</A>
<H2>NAME</H2>
Unix.LargeFile - File operations on large files.
<A NAME="lbAC">&nbsp;</A>
<H2>Module</H2>
Module Unix.LargeFile
<A NAME="lbAD">&nbsp;</A>
<H2>Documentation</H2>
<P>
Module
<B>LargeFile</B>
<BR>&nbsp;:&nbsp;
<B>sig end</B>
<P>
<P>
File operations on large files.
This sub-module provides 64-bit variants of the functions
<B>Unix.lseek</B>
(for positioning a file descriptor),
<B>Unix.truncate</B>
and
<B>Unix.ftruncate</B>
(for changing the size of a file),
and
<B>Unix.stat</B>
,
<B>Unix.lstat</B>
and
<B>Unix.fstat</B>
(for obtaining
information on files). These alternate functions represent
positions and sizes by 64-bit integers (type
<B>int64</B>
) instead of
regular integers (type
<B>int</B>
), thus allowing operating on files
whose sizes are greater than
<B>max_int</B>
.
<P>
<P>
<P>
<P>
<P>
<P>
<I>val lseek </I>
:
<B>Unix.file_descr -&gt; int64 -&gt; Unix.seek_command -&gt; int64</B>
<P>
See
<B>Unix.lseek</B>
.
<P>
<P>
<P>
<I>val truncate </I>
:
<B>string -&gt; int64 -&gt; unit</B>
<P>
See
<B>Unix.truncate</B>
.
<P>
<P>
<P>
<I>val ftruncate </I>
:
<B>Unix.file_descr -&gt; int64 -&gt; unit</B>
<P>
See
<B>Unix.ftruncate</B>
.
<P>
<P>
<I>type stats </I>
= {
<BR>&nbsp;st_dev&nbsp;:&nbsp;
<B>int</B>
; (* Device number
<BR>&nbsp;*)&nbsp;
<BR>&nbsp;st_ino&nbsp;:&nbsp;
<B>int</B>
; (* Inode number
<BR>&nbsp;*)&nbsp;
<BR>&nbsp;st_kind&nbsp;:&nbsp;
<B>Unix.file_kind</B>
; (* Kind of the file
<BR>&nbsp;*)&nbsp;
<BR>&nbsp;st_perm&nbsp;:&nbsp;
<B>Unix.file_perm</B>
; (* Access rights
<BR>&nbsp;*)&nbsp;
<BR>&nbsp;st_nlink&nbsp;:&nbsp;
<B>int</B>
; (* Number of links
<BR>&nbsp;*)&nbsp;
<BR>&nbsp;st_uid&nbsp;:&nbsp;
<B>int</B>
; (* User id of the owner
<BR>&nbsp;*)&nbsp;
<BR>&nbsp;st_gid&nbsp;:&nbsp;
<B>int</B>
; (* Group ID of the file's group
<BR>&nbsp;*)&nbsp;
<BR>&nbsp;st_rdev&nbsp;:&nbsp;
<B>int</B>
; (* Device ID (if special file)
<BR>&nbsp;*)&nbsp;
<BR>&nbsp;st_size&nbsp;:&nbsp;
<B>int64</B>
; (* Size in bytes
<BR>&nbsp;*)&nbsp;
<BR>&nbsp;st_atime&nbsp;:&nbsp;
<B>float</B>
; (* Last access time
<BR>&nbsp;*)&nbsp;
<BR>&nbsp;st_mtime&nbsp;:&nbsp;
<B>float</B>
; (* Last modification time
<BR>&nbsp;*)&nbsp;
<BR>&nbsp;st_ctime&nbsp;:&nbsp;
<B>float</B>
; (* Last status change time
<BR>&nbsp;*)&nbsp;
<BR>&nbsp;}
<P>
<P>
<P>
<P>
<P>
<I>val stat </I>
:
<B>string -&gt; stats</B>
<P>
<P>
<P>
<P>
<I>val lstat </I>
:
<B>string -&gt; stats</B>
<P>
<P>
<P>
<P>
<I>val fstat </I>
:
<B>Unix.file_descr -&gt; stats</B>
<P>
<P>
<P>
<P>
<HR>
<A NAME="index">&nbsp;</A><H2>Index</H2>
<DL>
<DT id="1"><A HREF="#lbAB">NAME</A><DD>
<DT id="2"><A HREF="#lbAC">Module</A><DD>
<DT id="3"><A HREF="#lbAD">Documentation</A><DD>
</DL>
<HR>
This document was created by
<A HREF="/cgi-bin/man/man2html">man2html</A>,
using the manual pages.<BR>
Time: 00:05:59 GMT, March 31, 2021
</BODY>
</HTML>