#include <Iguana/Utilities/classlib/iobase/IOStatus.h>
Public Types | |
enum | { FlagUniqueValid = 1 } |
enum | Type { TypeUnknown, TypeFile, TypeDirectory, TypeSocket, TypeSymlink, TypeNetworkSpecial, TypeBlockDev, TypeCharDev, TypeFIFO, TypeVolumeId, TypeMessageQueue, TypeSemaphore, TypeSharedMem, TypeMemoryObject } |
File types. More... | |
Public Member Functions | |
void | clear (void) |
bool | fill (const char *name, bool traverseLinks=true) |
bool | fill (IOFD fd) |
Public Attributes | |
FileAcl | m_acl |
Time | m_atime |
Time | m_ctime |
unsigned | m_flags |
unsigned | m_links |
Time | m_mtime |
IOOffset | m_size |
Type | m_type |
unsigned | m_unique [3] |
Using this information has limited value because of two reasons: not all systems provide meaningful values for all the fields, and many of the fields are not accurate.
Deductions from the file's owner and the access mode bits should be avoided: they do not work on ACL-based filesystems neither on UNIX nor on Windows. Instead use the more targeted queries such as Filename::isWritable() or File::times(). These usually return correct results.
Getting this information is not efficient on all systems. This is another reason to avoid this class unless the application knows what it is doing (e.g. choosing to be unportable for performance reasons).
Definition at line 40 of file IOStatus.h.
anonymous enum |
Definition at line 63 of file IOStatus.h.
00063 { 00064 FlagUniqueValid = 1 //< #m_unique is valid. 00065 };
enum lat::IOStatus::Type |
File types.
TypeUnknown | |
TypeFile | |
TypeDirectory | |
TypeSocket | |
TypeSymlink | |
TypeNetworkSpecial | |
TypeBlockDev | |
TypeCharDev | |
TypeFIFO | |
TypeVolumeId | |
TypeMessageQueue | |
TypeSemaphore | |
TypeSharedMem | |
TypeMemoryObject |
Definition at line 45 of file IOStatus.h.
00046 { 00047 TypeUnknown, //< Unknown or unsupported. 00048 TypeFile, //< Regular file. 00049 TypeDirectory, //< Directory. 00050 TypeSocket, //< Socket. 00051 TypeSymlink, //< Symbolic link. 00052 TypeNetworkSpecial, //< Network special file. 00053 TypeBlockDev, //< Block device. 00054 TypeCharDev, //< Character device. 00055 TypeFIFO, //< FIFO (named or anonymous pipe). 00056 TypeVolumeId, //< Volume label. 00057 TypeMessageQueue, //< Message queue as a file type. 00058 TypeSemaphore, //< Semaphore as a file type. 00059 TypeSharedMem, //< Shared memory as a file type. 00060 TypeMemoryObject //< Typed memory object as a file type. 00061 };
Definition at line 72 of file IOStatus.h.
Definition at line 69 of file IOStatus.h.
Definition at line 67 of file IOStatus.h.
unsigned lat::IOStatus::m_flags |
Definition at line 74 of file IOStatus.h.
unsigned lat::IOStatus::m_links |
Definition at line 77 of file IOStatus.h.
Definition at line 68 of file IOStatus.h.
Definition at line 78 of file IOStatus.h.
Definition at line 71 of file IOStatus.h.
unsigned lat::IOStatus::m_unique[3] |
Definition at line 75 of file IOStatus.h.