Go to the documentation of this file.00001 #ifndef WIBBLE_SYS_FILELOCK_H
00002 #define WIBBLE_SYS_FILELOCK_H
00003
00004 #include <fcntl.h>
00005
00006 namespace wibble {
00007 namespace sys {
00008 namespace fs {
00009
00015 struct FileLock
00016 {
00017 int fd;
00018 struct flock lock;
00019
00030 FileLock(int fd, short l_type, short l_whence=SEEK_SET, off_t l_start=0, off_t l_len=0);
00031
00035 ~FileLock();
00036
00037 private:
00038
00039 FileLock(const FileLock&);
00040 FileLock& operator=(const FileLock&);
00041 };
00042
00043 }
00044 }
00045 }
00046
00047
00048 #endif