source: box/trunk/lib/common/EventWatchFilesystemObject.h @ 217

Revision 217, 1.3 KB checked in by martin, 6 years ago (diff)

Set svn:eol-style as appropriate for all files

  • Property svn:eol-style set to native
Line 
1// --------------------------------------------------------------------------
2//
3// File
4//              Name:    EventWatchFilesystemObject.h
5//              Purpose: WaitForEvent compatible object for watching directories
6//              Created: 12/3/04
7//
8// --------------------------------------------------------------------------
9
10#ifndef EVENTWATCHFILESYSTEMOBJECT__H
11#define EVENTWATCHFILESYSTEMOBJECT__H
12
13#ifdef HAVE_KQUEUE
14        #include <sys/event.h>
15#endif
16
17
18// --------------------------------------------------------------------------
19//
20// Class
21//              Name:    EventWatchFilesystemObject
22//              Purpose: WaitForEvent compatible object for watching files and directories
23//              Created: 12/3/04
24//
25// --------------------------------------------------------------------------
26class EventWatchFilesystemObject
27{
28public:
29        EventWatchFilesystemObject(const char *Filename);
30        ~EventWatchFilesystemObject();
31        EventWatchFilesystemObject(const EventWatchFilesystemObject &rToCopy);
32private:
33        // Assignment not allowed
34        EventWatchFilesystemObject &operator=(const EventWatchFilesystemObject &);
35public:
36
37#ifdef HAVE_KQUEUE
38        void FillInKEvent(struct kevent &rEvent, int Flags = 0) const;
39#else
40        void FillInPoll(int &fd, short &events, int Flags = 0) const;
41#endif
42
43private:
44        int mDescriptor;
45};
46
47#endif // EventWatchFilesystemObject__H
48
Note: See TracBrowser for help on using the repository browser.