Bifrost SDK
Bifrost SDK documentation
FileUtils.h File Reference

File utilities. More...

Go to the source code of this file.

Namespaces

namespace  Bifrost
 
namespace  Bifrost::FileUtils
 

Functions

bool Bifrost::FileUtils::isAbsolute (Amino::StringView path)
 Checks if a path is absolute. More...
 
bool Bifrost::FileUtils::createDirectories (Amino::StringView path, Amino::String *errorMessage=nullptr)
 Creates the directories in path that do not exist. More...
 
bool Bifrost::FileUtils::currentPath (Amino::String &currentPath, Amino::String *errorMessage=nullptr)
 Returns the current path. More...
 
Amino::String Bifrost::FileUtils::extractParentPath (Amino::StringView path)
 Returns the parent path of path. The input is first processed by makePreferred. Then the extraction follows C++17 std::filesystem. More...
 
Amino::String Bifrost::FileUtils::makePreferred (Amino::StringView path)
 Convert directory separator characters in the given string to the operating system's preferred character. (For unix systems this is a forward slash, and for Windows, a backslash) More...
 
Amino::String Bifrost::FileUtils::filePath (Amino::StringView directory, Amino::StringView filename)
 Create a file path from a directory and an filename in an operating system / independent way. More...
 
Amino::String Bifrost::FileUtils::filename (Amino::StringView baseName, long long frame, Amino::StringView targetExtension)
 Construct a file name with the specified frame number and extension. If the file name contains # or @ they will be replaced with the given frame number. # will reserve 4 digits for the frame number, whereas @ will reserve just one. If a target file extension is specified it will be enforced, otherwise will be ignored. More...
 
Amino::String Bifrost::FileUtils::extractFilename (Amino::StringView filePath)
 Get the filename (with extension) from a file path. The input is first processed by makePreferred. Then the extraction follows C++17 std::filesystem. More...
 
bool Bifrost::FileUtils::filePathExists (Amino::StringView filePath, Amino::String *out_errorMessage=nullptr)
 Verify if a file path exists. More...
 
Amino::String Bifrost::FileUtils::getRelativePath (Amino::StringView path, Amino::StringView baseDirectory)
 Return the valid relative path of the input path with respect to baseDirectory. More...
 
bool Bifrost::FileUtils::exists (Amino::StringView path, Amino::String *errorMessage=nullptr)
 Verify if a path exists. More...
 
bool Bifrost::FileUtils::tempDirectoryPath (Amino::String &tempDirectoryPath, Amino::String *errorMessage=nullptr)
 Returns the directory location suitable for temporary files. More...
 
bool Bifrost::FileUtils::removeAll (Amino::StringView path, Amino::String *errorMessage=nullptr)
 

Detailed Description

File utilities.

Definition in file FileUtils.h.