AWS SDK for C++
AWS SDK for C++
|
Classes | |
class | Directory |
struct | DirectoryEntry |
class | DirectoryTree |
Typedefs | |
typedef std::function< bool(const DirectoryTree *, const DirectoryEntry &)> | DirectoryEntryVisitor |
Enumerations | |
enum class | FileType { None , File , Symlink , Directory } |
Functions | |
AWS_CORE_API Aws::String | GetHomeDirectory () |
AWS_CORE_API Aws::String | GetExecutableDirectory () |
AWS_CORE_API bool | CreateDirectoryIfNotExists (const char *path, bool createParentDirs=false) |
Creates directory if it doesn't exist. Returns true if the directory was created or already exists. False for failure. | |
AWS_CORE_API bool | RemoveDirectoryIfExists (const char *path) |
AWS_CORE_API bool | RemoveFileIfExists (const char *fileName) |
AWS_CORE_API bool | RelocateFileOrDirectory (const char *from, const char *to) |
AWS_CORE_API bool | DeepCopyDirectory (const char *from, const char *to) |
AWS_CORE_API bool | DeepDeleteDirectory (const char *toDelete) |
AWS_CORE_API Aws::String | CreateTempFilePath () |
AWS_CORE_API Aws::UniquePtr< Directory > | OpenDirectory (const Aws::String &path, const Aws::String &relativePath="") |
AWS_CORE_API Aws::String | Join (const Aws::String &leftSegment, const Aws::String &rightSegment) |
AWS_CORE_API Aws::String | Join (char delimiter, const Aws::String &leftSegment, const Aws::String &rightSegment) |
Variables | |
static const char | PATH_DELIM = '/' |
typedef std::function<bool(const DirectoryTree*, const DirectoryEntry&)> Aws::FileSystem::DirectoryEntryVisitor |
Visitor for a Directory Tree traversal. Return true to continue the traversal, false to exit the traversal immediately.
Definition at line 169 of file FileSystem.h.
|
strong |
Type of directory entry encountered.
Enumerator | |
---|---|
None | |
File | |
Symlink | |
Directory |
Definition at line 95 of file FileSystem.h.
AWS_CORE_API bool Aws::FileSystem::CreateDirectoryIfNotExists | ( | const char * | path, |
bool | createParentDirs = false |
||
) |
Creates directory if it doesn't exist. Returns true if the directory was created or already exists. False for failure.
path,the | absolute path of the directory. |
createParentDirs,if | true, then this function will create missing directories on the path like linux command: mkdir -p |
AWS_CORE_API Aws::String Aws::FileSystem::CreateTempFilePath | ( | ) |
Computes a unique tmp file path
AWS_CORE_API bool Aws::FileSystem::DeepCopyDirectory | ( | const char * | from, |
const char * | to | ||
) |
Copies a directory and all of its contents.
AWS_CORE_API bool Aws::FileSystem::DeepDeleteDirectory | ( | const char * | toDelete | ) |
Deletes a directory and all of its contents.
AWS_CORE_API Aws::String Aws::FileSystem::GetExecutableDirectory | ( | ) |
Returns the directory path for the directory containing the currently running executable
AWS_CORE_API Aws::String Aws::FileSystem::GetHomeDirectory | ( | ) |
Returns the directory path for the home dir env variable
AWS_CORE_API Aws::String Aws::FileSystem::Join | ( | char | delimiter, |
const Aws::String & | leftSegment, | ||
const Aws::String & | rightSegment | ||
) |
Joins the leftSegment and rightSegment of a path together using the specified delimiter. e.g. with delimiter & C:\users\name\ and .aws becomes C:\users\name&.aws
AWS_CORE_API Aws::String Aws::FileSystem::Join | ( | const Aws::String & | leftSegment, |
const Aws::String & | rightSegment | ||
) |
Joins the leftSegment and rightSegment of a path together using platform specific delimiter. e.g. C:\users\name\ and .aws becomes C:\users\name.aws
AWS_CORE_API Aws::UniquePtr< Directory > Aws::FileSystem::OpenDirectory | ( | const Aws::String & | path, |
const Aws::String & | relativePath = "" |
||
) |
Opens a directory for traversal.
AWS_CORE_API bool Aws::FileSystem::RelocateFileOrDirectory | ( | const char * | from, |
const char * | to | ||
) |
Moves the file. Returns true on success
AWS_CORE_API bool Aws::FileSystem::RemoveDirectoryIfExists | ( | const char * | path | ) |
Creates directory if it doesn't exist. Returns true if the directory was created or already exists. False for failure.
AWS_CORE_API bool Aws::FileSystem::RemoveFileIfExists | ( | const char * | fileName | ) |
Deletes file if it exists. Returns true if file doesn't exist or on success.
|
static |
Definition at line 24 of file FileSystem.h.