add -fPIC option to the C compiler, required in f31
[vsys.git] / inotify.mli
1 (*
2  * Copyright (C) 2006 Vincent Hanquez <vincent@snarc.org>
3  *
4  * This program is free software; you can redistribute it and/or modify
5  * it under the terms of the GNU Lesser General Public License as published
6  * by the Free Software Foundation; version 2 only.
7  *
8  * This program is distributed in the hope that it will be useful,
9  * but WITHOUT ANY WARRANTY; without even the implied warranty of
10  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
11  * GNU General Public License for more details.
12  *
13  * Inotify OCaml binding
14  *)
15
16 type select_event =
17 | S_Access
18 | S_Attrib
19 | S_Close_write
20 | S_Close_nowrite
21 | S_Create
22 | S_Delete
23 | S_Delete_self
24 | S_Modify
25 | S_Move_self
26 | S_Moved_from
27 | S_Moved_to
28 | S_Open
29 | S_Dont_follow
30 | S_Mask_add
31 | S_Oneshot
32 | S_Onlydir
33 | S_Move
34 | S_Close
35 | S_All
36
37 type type_event =
38 | Access
39 | Attrib
40 | Close_write
41 | Close_nowrite
42 | Create
43 | Delete
44 | Delete_self
45 | Modify
46 | Move_self
47 | Moved_from
48 | Moved_to
49 | Open
50 | Ignored
51 | Isdir
52 | Q_overflow
53 | Unmount
54
55 type wd
56 type event = wd * type_event list * int32 * string option
57
58 val int_of_wd : wd -> int
59 val string_of_event : type_event -> string
60
61 val init : unit -> Unix.file_descr
62 val add_watch : Unix.file_descr -> string -> select_event list -> wd
63 val rm_watch : Unix.file_descr -> wd -> unit
64 val read : Unix.file_descr -> event list