Ark Server API (ASA) - Wiki
|
#include <PathViews.h>
Public Member Functions | |
UE_DEPRECATED (4.25, "FPathViews::GetBaseFilename(InPath, bRemovePath) has been superseded by " "FPathViews::GetBaseFilename(InPath) and FPathViews::GetBaseFilenameWithPath(InPath).") static FStringView GetBaseFilename(const FStringView &InPath | |
Public Attributes | |
bool | bRemovePath |
Definition at line 13 of file PathViews.h.
|
inlinestatic |
Appends each suffix argument to the path in the builder and ensures that there is a separator between them.
Examples: ("", "") -> "" ("A", "") -> "A/" ("", "B") -> "B" ("/", "B") -> "/B" ("A", "B") -> "A/B" ("A/", "B") -> "A/B" ("A\\", "B") -> "A\B" ("A/B", "C/D") -> "A/B/C/D" ("A/", "B", "C/", "D") -> "A/B/C/D"
Builder | A possibly-empty path that may end in a separator. |
Args | Arguments that can write to a string builder and do not start with a separator. |
Definition at line 167 of file PathViews.h.
|
static |
If AppendPath is a relative path, append it as a relative path onto InOutPath. If AppendPath is absolute, reset InOutPath and replace it with RelPath. Handles presence or absence of terminating separator in BasePath. Does not interpret . or ..; each occurrence of these in either path will remain in the combined InOutPath.
|
static |
Replaces the pre-existing file extension of a filename.
InPath | A valid file path with a pre-existing extension. |
InNewExtension | The new extension to use (prefixing with a '.' is optional) |
|
static |
Collapses redundant paths like "/./" and "SkipDir/..". FPaths::CollapseRelativeDirectories() equivalent.
|
static |
Return true if the given paths are the same path (with exceptions noted below). Case-insensitive / is treated as equal to \ Presence or absence of terminating separator (/) is ignored in the comparison. Directory elements of . and .. are currently not interpreted and are treated as literal characters. Callers should not rely on this behavior as it may be corrected in the future. callers should instead conform the paths before calling. Relative paths and absolute paths are not resolved, and relative paths will never equal absolute paths. Callers should not rely on this behavior as it may be corrected in the future; callers should instead conform the paths before calling. Examples: ("../A/B.C", "../A/B.C") -> true ("../A/B", "../A/B.C") -> false ("../A/", "../A/") -> true ("../A/", "../A") -> true ("d:/root/Engine/", "d:\root\Engine") -> true (../../../Engine/Content", "d:/root/Engine/Content") -> false (d:/root/Engine/..", "d:/root") -> false (d:/root/Engine/./Content", "d:/root/Engine/Content") -> false
|
static |
Returns the portion of the path after the last separator and before the last dot.
Examples: (Using '/' but '\' is valid too.) "A/B/C.D" -> "C" "A/B/C" -> "C" "A/B/" -> "" "A" -> "A"
|
static |
Returns the portion of the path before the last dot.
Examples: (Using '/' but '\' is valid too.) "A/B/C.D" -> "A/B/C" "A/B/C" -> "A/B/C" "A/B/" -> "A/B/" "A" -> "A"
|
static |
Returns the portion of the path after the last separator.
Examples: (Using '/' but '\' is valid too.) "A/B/C.D" -> "C.D" "A/B/C" -> "C" "A/B/" -> "" "A" -> "A"
|
static |
Returns the portion of the path after the last dot following the last separator, optionally including the dot.
Examples: (Using '/' but '\' is valid too.) "A/B.C.D" -> "D" (bIncludeDot=false) or ".D" (bIncludeDot=true) "A/B/C.D" -> "D" (bIncludeDot=false) or ".D" (bIncludeDot=true) "A/B/.D" -> "D" (bIncludeDot=false) or ".D" (bIncludeDot=true) ".D" -> "D" (bIncludeDot=false) or ".D" (bIncludeDot=true) "A/B/C" -> "" "A.B/C" -> "" "A.B/" -> "" "A" -> ""
bIncludeDot | Whether to include the leading dot in the returned view. |
|
static |
Returns the name of the mount point in a path Removes starting forward slash and Classes_ prefix if bInWithoutSlashes is true Example: "/Classes_A/Textures" returns "A" and sets bOutHadClassesPrefix=true if bInWithoutSlashes is true returns "/Classes_A" otherwise and sets bOutHadClassesPrefix=false
|
static |
Returns the portion of the path before the last separator.
Examples: (Using '/' but '\' is valid too.) "A/B/C.D" -> "A/B" "A/B/C" -> "A/B" "A/B/" -> "A/B" "A" -> ""
|
static |
Returns the last non-empty path component.
Examples: (Using '/' but '\' is valid too.) "A/B/C.D" -> "C.D" "A/B/C" -> "C" "A/B/" -> "B" "A" -> "A"
|
static |
Return whether Parent is a parent path of (or is equal to) Child. Case-insensitive / is treated as equal to \ Presence or absence of terminating separator (/) is ignored in the comparison. Directory elements of . and .. are currently not interpreted and are treated as literal characters. Callers should not rely on this behavior as it may be corrected in the future. callers should instead conform the paths before calling. Relative paths and absolute paths are not resolved, and relative paths will never equal absolute paths. Callers should not rely on this behavior as it may be corrected in the future; callers should instead conform the paths before calling. Examples: ("../A", "../A/B") -> true ("../A/", "../A\B") -> true ("../A", "../A/") -> true ("../A", ".././A/") -> false ("d:/root/Engine", "../../../Engine") -> false
Parent | An absolute path that may be a parent path of Child. |
Child | An absolute path that may be a child path of Parent. |
|
static |
Return whether the given relative or absolute path is a leaf path - has no separators.
Examples: (Using '/' but '\' functions the same way) A -> true A/ -> true D:/ -> true / -> true // -> true A/B -> false D:/A -> false //A -> false
|
static |
Return whether the given path is a relativepath - does not start with a separator or volume:. Returns true for empty paths.
Return whether the given character is a path-separator character (/ or )
|
static |
Splits InPath into individual directory components, and calls ComponentVisitor on each.
Examples: "A/B.C" -> {"A", "B.C"} "A/B/C" -> {"A", "B", "C"} "../../A/B/C.D" -> {"..", "..", "A", "B", "C.D" }
|
static |
Return true if the the first path is lexicographically less than the second path (with caveats noted below). Case-insensitive / is treated as equal to \ Presence or absence of terminating separator (/) is ignored in the comparison. Directory elements of . and .. are currently not interpreted and are treated as literal characters. Callers should not rely on this behavior as it may be corrected in the future. callers should instead conform the paths before calling. Relative paths and absolute paths are not resolved, and relative paths will never equal absolute paths. Callers should not rely on this behavior as it may be corrected in the future; callers should instead conform the paths before calling. Examples: ("../A/B.C", "../A/B.C") -> false (they are equal) ("../A/B", "../A/B.C") -> true (a string is greater than any prefix of itself) ("../A/", "../A/") -> false (they are equal) ("../A/", "../A") -> false (they are equal) ("../A", "../A/") -> false (they are equal) ("d:/root/Engine/", "d:\root\Engine") -> false (they are equal) (../../../Engine/Content", "d:/root/Engine/Content") -> true ('.' is less than 'd') (d:/root/Engine/..", "d:/root") -> false (A string is greater than any prefix of itself) (d:/root/Engine/./Content", "d:/root/Engine/Content") -> false
|
static |
Normalize and remove trailing slash unless the preceding character is '/' or ':'
|
static |
Convert \ to / and do platform-specific normalization
|
static |
Removes duplicate forward slashes, e.g. "a/b//c////f.e" -> "a/b/c/f.e"
|
static |
Splits a path into three parts, any of which may be empty: the path, the clean name, and the extension.
Examples: (Using '/' but '\' is valid too.) "A/B/C.D" -> ("A/B", "C", "D") "A/B/C" -> ("A/B", "C", "") "A/B/" -> ("A/B", "", "") "A/B/.D" -> ("A/B", "", "D") "A/B.C.D" -> ("A", "B.C", "D") "A" -> ("", "A", "") "A.D" -> ("", "A", "D") ".D" -> ("", "", "D")
OutPath | [out] Receives the path portion of the input string, excluding the trailing separator. |
OutName | [out] Receives the name portion of the input string. |
OutExt | [out] Receives the extension portion of the input string, excluding the dot. |
|
static |
Split the given absolute or relative path into its topmost directory and the relative path from that directory. Directory elements of . and .. are currently not interpreted and are treated as literal characters. Callers should not rely on this behavior as it may be corrected in the future. callers should instead conform the paths before calling.
InPath | The path to split. |
OutFirstComponent | Receives the first directory element in the path, or InPath if it is a leaf path. |
OutRemainder | Receives the relative path from OutFirstComponent to InPath, or empty if InPath is a leaf path. |
|
static |
Convert to absolute using explicit BasePath, normalize and append. FPaths::ConvertRelativePathToFull() equivalent.
|
static |
Convert to absolute using process BaseDir(), normalize and append. FPaths::ConvertRelativePathToFull() equivalent.
|
static |
Convert to absolute using process BaseDir() and normalize inlined. FPaths::ConvertRelativePathToFull() equivalent.
|
static |
Convert to absolute using explicit BasePath and normalize inlined. FPaths::ConvertRelativePathToFull() equivalent.
|
static |
Check whether Parent is a parent path of Child and report the relative path if so. Case-insensitive / is treated as equal to \ Presence or absence of terminating separator (/) is ignored in the comparison. Directory elements of . and .. are currently not interpreted and are treated as literal characters. Callers should not rely on this behavior as it may be corrected in the future. callers should instead conform the paths before calling. Relative paths and absolute paths are not resolved, and relative paths will never equal absolute paths. Callers should not rely on this behavior as it may be corrected in the future; callers should instead conform the paths before calling. Examples: ("../A/B", "../A") -> (true, "B") ("../A\B", "../A/") -> (true, "B") ("../A/", "../A") -> (true, "") (".././A/", "../A") -> (false, "") ("../../../Engine", "d:/root/Engine") -> (false, "")
Child | An absolute path that may be a child path of Parent. |
Parent | An absolute path that may be a parent path of Child. |
OutRelPath | Receives the relative path from Parent to Child, or empty if Parent is not a parent of Child. |
FPathViews::UE_DEPRECATED | ( | 4. | 25, |
"FPathViews::GetBaseFilename(InPath, bRemovePath) has been superseded by " "FPathViews::GetBaseFilename(InPath) and FPathViews::GetBaseFilenameWithPath(InPath)." | ) const & |
Returns the portion of the path before the last dot and optionally after the last separator.
bool FPathViews::bRemovePath |
Definition at line 58 of file PathViews.h.