2#ifndef POSIX_POSIXFSWRAPPER_H
3#define POSIX_POSIXFSWRAPPER_H
SeekOrigin
seek origins
Definition stream.h:54
int64_t Position
typedefs
Definition stream.h:32
int64_t Size
Definition stream.h:34
AccessMode
access modes
Definition stream.h:38
int64_t Offset
Definition stream.h:33
AccessPattern
access prefered pattern
Definition stream.h:47
An URI object can split a Uniform Resource Identifier string into its components or build a string fr...
Definition uri.h:67
Internal filesystem wrapper for Posix.
Definition posixfswrapper.h:24
static bool CreateDirectory(const Util::String &path)
create a directory
Definition posixfswrapper.cc:430
static void Flush(Handle h)
flush a file
Definition posixfswrapper.cc:187
static void Seek(Handle h, IO::Stream::Offset offset, IO::Stream::SeekOrigin orig)
seek in a file
Definition posixfswrapper.cc:148
static char * Map(Handle h, IO::Stream::AccessMode accessMode, Handle &mappedHandle)
map file to virtual memory
Definition posixfswrapper.cc:118
static IO::Stream::Position Tell(Handle h)
get position in file
Definition posixfswrapper.cc:176
FILE * Handle
Definition posixfswrapper.h:26
static IO::FileTime GetFileWriteTime(const Util::String &path)
get the last write-access time stamp of a file
Definition posixfswrapper.cc:411
static Util::String CreateTemporaryFilename(const Util::String &path)
create a temporary file name
Definition posixfswrapper.cc:440
static IO::Stream::Size Read(Handle h, void *buf, IO::Stream::Size numBytes)
read from a file
Definition posixfswrapper.cc:98
static void SetFileWriteTime(const Util::String &path, IO::FileTime fileTime)
set the write-access time stamp of a file
Definition posixfswrapper.cc:401
static Util::String GetUserDirectory()
get path to the current user's home directory (for user: standard assign)
Definition posixfswrapper.cc:542
static Util::Array< Util::String > ListDirectories(const Util::String &dirPath, const Util::String &pattern)
list all subdirectories in a directory
Definition posixfswrapper.cc:494
static void SetReadOnly(const Util::String &path, bool readOnly)
set read-only status of a file
Definition posixfswrapper.cc:270
static Handle OpenFile(const Util::String &path, IO::Stream::AccessMode accessMode, IO::Stream::AccessPattern accessPattern)
open a file
Definition posixfswrapper.cc:39
static bool IsDeviceName(const Util::String &str)
return true when the string is a device name (e.g. "C:")
Definition posixfswrapper.cc:648
static bool IsReadOnly(const Util::String &path)
get read-only status of a file
Definition posixfswrapper.cc:296
static bool DirectoryExists(const Util::String &path)
return true if a directory exists
Definition posixfswrapper.cc:384
static Util::String GetTempDirectory()
get path to the current user's temp directory (for temp: standard assign)
Definition posixfswrapper.cc:555
static bool DeleteFile(const Util::String &path)
delete a file
Definition posixfswrapper.cc:336
static bool Eof(Handle h)
return true if at end-of-file
Definition posixfswrapper.cc:198
static bool ReplaceFile(const Util::String &source, const Util::String &target)
rename a file
Definition posixfswrapper.cc:346
static bool GetIOInfo(const IO::URI &uri, IO::IOStat &outInfo)
get file/folder io info via stat
Definition posixfswrapper.cc:245
static void Unmap(Handle mapHandle, char *buf)
unmap file
Definition posixfswrapper.cc:137
static bool FileExists(const Util::String &path)
return true if a file exists
Definition posixfswrapper.cc:367
static void CloseFile(Handle h)
close a file
Definition posixfswrapper.cc:70
static bool DeleteDirectory(const Util::String &path)
delete an empty directory
Definition posixfswrapper.cc:356
static Util::Array< Util::String > ListFiles(const Util::String &dirPath, const Util::String &pattern)
list all files in a directory
Definition posixfswrapper.cc:454
static IO::Stream::Size GetFileSize(Handle h)
get size of a file in bytes
Definition posixfswrapper.cc:214
static Util::String GetBinDirectory()
get path to the current bin directory (for bin: standard assign)
Definition posixfswrapper.cc:566
static Util::String GetHomeDirectory()
get path to the current application directory (for home: standard assign)
Definition posixfswrapper.cc:598
static bool IsLocked(const Util::String &path)
get locked status of file
Definition posixfswrapper.cc:321
Nebula's dynamic array class.
Definition array.h:60
@ Write
Definition filewatcher.h:47
Posix implemention of a read-many write-few lock.
Definition posixsysfunc.cc:21
Nebula's universal string class.
Definition String.cs:8