#include <StkFilePath.h>
|
| FilePath (const std::string &file="") |
|
bool | operator== (const FilePath &fp) const |
|
void | setPath (const std::string &path) |
|
bool | hasParent () |
|
void | clear () |
|
bool | toParent () |
| Change the path one level up.
|
|
std::string | fullPath () const |
| Return the full path, including root drive/network address.
|
|
std::string | filePath () const |
| Return the file path only, without root drive/network address.
|
|
bool | exists () const |
|
bool | isDirectory () const |
|
bool | isAbsolute () const |
|
std::string | fileName () const |
|
std::string | directoryPath () const |
|
bool | getFilesInDirectory (std::vector< FilePath > &files) const |
|
FilePath | appendPath (const std::string &subPath) const |
| Returns new FilePath that includes "subPath".
|
|
std::string | fileExt () const |
| Returns the file extension, including the ".", for example ".cpp".
|
|
std::string | baseName () const |
| Returns file name without extension.
|
|
std::string | root () const |
|
bool | createDirectory () |
|
|
static std::string | fileName (const std::string &file) |
|
static std::string | baseName (const std::string &file) |
|
static std::string | dirPath (const std::string &file) |
|
static std::string | extension (const std::string &file) |
| Returns the file extension for the given path, including the ".", for example ".cpp".
|
|
static FilePath | getParent (const FilePath &p) |
|
static bool | fileExists (const std::string &file) |
|
static bool | isDirectory (const std::string &file) |
|
static bool | filesInDirectory (const FilePath &p, std::vector< FilePath > &files) |
|
static bool | createDirectory (const std::string &path) |
|
static FilePath | getCurrentPath () |
|
|
std::string | root_ |
|
std::vector< std::string > | path_elem_ |
|
bool | is_absolute_ |
|
FileInfo - Short description. Detailed description.
◆ baseName()
std::string FilePath::baseName |
( |
| ) |
const |
Returns file name without extension.
- Returns
◆ hasParent()
bool STK::FilePath::hasParent |
( |
| ) |
|
|
inline |
Check if the path has a parent directory. Note that this check is only meaningful if the path is absolute. For relative paths we assume that we can add .. and return true.
The documentation for this class was generated from the following files:
- Native/SilentToolkit/StkCore/StkFilePath.h
- Native/SilentToolkit/StkCore/StkFilePath.cpp