32 #include <casacore/casa/aips.h> 33 #include <casacore/casa/OS/Path.h> 34 #include <casacore/casa/OS/Mutex.h> 35 #include <casacore/casa/BasicSL/String.h> 297 void getstat (
void* buf)
const;
325 #if !defined(AIPS_NOLARGEFILE) 327 # if !defined(_LARGEFILE64_SOURCE) 328 # define _LARGEFILE64_SOURCE 331 #if defined(AIPS_DARWIN) || defined(AIPS_BSD) 332 # define fileFSTAT fstat 333 # define fileLSTAT lstat 334 # define fileSTAT stat 335 # define fileSTATFS statfs 337 # define fileFSTAT fstat64 338 # define fileLSTAT lstat64 339 # define fileSTAT stat64 340 # define fileSTATFS statfs64 343 # define fileFSTAT fstat 344 # define fileLSTAT lstat 345 # define fileSTAT stat 346 # define fileSTATFS statfs uInt modifyTime() const
Return the time when the file was last modified in seconds since 00:00:00 GMT Jan 1...
long long Int64
Define the extra non-standard types used by Casacore (like proposed uSize, Size)
Bool isReadable() const
Check if the file is readable.
void setPermissions(uInt permissions)
Set permission with perm.
int mylstat(const char *path, void *buf) const
Define a function for lstat.
const Path & path() const
Returns the pathname of the file.
TableExprNode time(const TableExprNode &node)
Bool isWritable() const
Check if the file is writable.
String accessTimeString() const
Return the time when the file was last accessed as a 26-characters String of the form: Thu Feb 3 13:4...
Path itsPath
Full pathname of the file.
Bool isSymLink() const
Check if the file is a symbolic link.
virtual Int64 size() const
Return the size of the file.
Bool isDirectory(Bool followSymLink=True) const
Check if the file is a directory.
void touch()
Update access time and modification time of a file.
file does not exist but cannot be created
file does not exist and is creatable
static uInt uniqueSeqnr_p
A sequence number to generate unique file names.
Bool isCharacterSpecial() const
Check if the file is a character special file.
String getFSType() const
Return the filesystem type.
file exists and can be overwritten
Bool isExecutable() const
Check if the file is executable.
Bool isRegular(Bool followSymLink=True) const
Check if the file is a regular file.
Bool isSocket() const
Check if the file is a socket.
long groupID() const
Return the groupID of the file.
String modifyTimeString() const
Return the time when the file was last modified as a 26-characters String of the form: Thu Feb 3 13:4...
FileWriteStatus getWriteStatus() const
get write status of the file.
Bool exists() const
Check if the file exists.
file exists but cannot be overwritten
uInt statusChangeTime() const
Return the time when the file status was last changed in seconds since 00:00:00 GMT Jan 1...
Class to get file information and a base for other file classes.
bool Bool
Define the standard types used by Casacore.
uInt accessTime() const
Time related fucnctions: Return the time when the file was last accessed in seconds since 00:00:00 GM...
Wrapper around a pthreads mutex.
static Path newUniqueName(const String &directory, const String &prefix)
Create a new unique path name in the specified directory, with the specified prefix and random traili...
File & operator=(const File &that)
Assignment (copy semantics).
Bool canCreate() const
Check if a file can be created.
uInt readPermissions() const
Return the permissions as a decimal value.
String: the storage and methods of handling collections of characters.
void removeSymLinks()
This function is used by RegularFile and Directory to remove all the links which, when followed, ultimately resolve to a Directory or a RegularFile.
void getstat(void *buf) const
Get the lstat of this file.
Bool isPipe() const
Check if the file is a pipe.
long userID() const
Return the userID of the file.
Bool isBlockSpecial() const
Check if the file is a block special file.
this file contains all the compiler specific defines
String statusChangeTimeString() const
return the time when the file status was last changed as a 26-characters String of the form: Thu Feb ...
void checkTarget(Path &targetName, Bool overwrite, Bool forDirectory=False) const
Check if the new path for a copy or move is valid.
File()
Construct a File object whose Path is set to the current working directory.