Navigation
Unreal Engine C++ API Reference > Runtime > CoreUObject > Misc
References
Module | CoreUObject |
Header | /Engine/Source/Runtime/CoreUObject/Public/Misc/PackagePath.h |
Include | #include "Misc/PackagePath.h" |
Syntax
class FPackagePath
Remarks
Internal class only; not used by blueprints. This class is only used in the CoreUObject linker layer and (optionally) as an argument to LoadPackage
Specifies a path to the contents of a UPackage that can be loaded from disk (or other persistent storage) through IPackageResourceManager Package contents are requested from the PackageResourceManager by FPackagePath and EPackageSegment FPackagePaths are stored internally in one of a few options necessary to maintain their construction arguments without losing data const FPackagePaths can still be mutated to be stored as another internal type const FPackagePaths can still be mutated to indicate which header extension was found for them on disk (It is illegal to have multiple packages on disk with the same PackagePath but different header extensions)
Constructors
Type | Name | Description | |
---|---|---|---|
![]() |
FPackagePath () |
Construct an empty PackagePath | |
![]() |
FPackagePath
(
const FPackagePath& Other |
||
![]() |
FPackagePath
(
FPackagePath&& Other |
Functions
Type | Name | Description | |
---|---|---|---|
![]() ![]() |
void | AppendLocalBaseFilenameWithPath
(
FStringBuilderBase& Builder |
Append the Local (path,basename) of this PackagePath if known or available, or take no action if not |
![]() ![]() |
void | AppendLocalFullPath
(
FStringBuilderBase& Builder, |
Version of AppendLocalFullPath that takes a PackageSegment, otherwise same behavior as parameterless version |
![]() ![]() |
void | AppendLocalFullPath
(
FStringBuilderBase& Builder |
Append the full relative LocalPath (path,basename,extension) |
![]() ![]() |
void | AppendPackageName
(
FStringBuilderBase& Builder |
Append the PackageName indicated by this PackagePath if known or available, or take no action if not |
![]() |
void | Empty () |
Free this PackagePath's data and set it to an empty PackagePath |
![]() ![]() |
FPackagePath | FromLocalPath
(
FStringView InFilename |
Construct a PackagePath from a LocalPath string |
![]() ![]() |
FPackagePath | FromLocalPath
(
FStringView InFilename, |
Version of FromLocalPath that also returns the PackageSegment matching the Filename's extension |
![]() ![]() |
FPackagePath | FromMountedComponents
(
FStringView PackageNameRoot, |
Construct a PackagePath from the components of a MountedPath |
![]() ![]() |
FPackagePath | FromPackageNameChecked
(
FStringView InPackageName |
Construct a PackagePath from a LongPackageName StringView, FName, or TCHAR* |
![]() ![]() |
FPackagePath | FromPackageNameChecked
(
FName InPackageName |
|
![]() ![]() |
FPackagePath | FromPackageNameChecked
(
const TCHAR* InPackageName |
|
![]() ![]() |
FPackagePath | FromPackageNameUnchecked
(
FName InPackageName |
Construct a PackagePath from a known valid LongPackageName FName |
![]() ![]() |
FStringView | Return the custom string if this PackagePath is using HeaderExtension=EPackageExtension::Custom, otherwise return an empty string | |
![]() ![]() |
FString | GetDebugName
(
EPackageSegment PackageSegment |
Version of GetDebugName that takes a PackageSegment, otherwise same behavior as parameterless version For EPackageSegment::Header, HeaderExtension is not indicated. |
![]() ![]() |
FString | GetDebugName () |
Returns a descriptor of this PackagePath, usable for an identifier in warning and log messages. |
![]() ![]() |
FText | Returns GetDebugName converted to FText | |
![]() ![]() |
FText | GetDebugNameText
(
EPackageSegment PackageSegment |
Version of GetDebugNameText that takes a PackageSegment, otherwise same behavior as parameterless version |
![]() ![]() |
FString | Returns a descriptor of this PackagePath for the given segment, with extension. | |
![]() ![]() |
FString | GetDebugNameWithExtension
(
EPackageSegment PackageSegment |
Version of GetDebugNameWithExtension that takes a PackageSegment, otherwise same behavior as parameterless version |
![]() ![]() |
EPackageExtension | GetExtension
(
EPackageSegment PackageSegment, |
Report the extension this PackagePath uses for the given segment |
![]() ![]() |
FStringView | GetExtensionString
(
EPackageSegment PackageSegment |
Report the extension string this PackagePath uses for the given segment. |
![]() ![]() |
const TCHAR * | Get the folder name from which all external actors paths are created | |
![]() ![]() |
const TCHAR * | Get the folder name from which all external objects paths are created | |
![]() ![]() |
EPackageExtension | Return the HeaderExtension | |
![]() ![]() |
FString | Return the Local (path,basename) of this PackagePath if known or available, or empty string if not | |
![]() ![]() |
FString | Return the full LocalPath (path,basename,extension) | |
![]() ![]() |
FString | GetLocalFullPath
(
EPackageSegment PackageSegment |
Version of GetLocalFullPath that takes a PackageSegment, otherwise same behavior as parameterless version |
![]() ![]() |
const TCHAR * | Get the string identifying optional segments | |
![]() ![]() |
FName | Return as an FName the PackageName indicated by this PackagePath if known or available, or NAME_None if not | |
![]() ![]() |
FString | Return the PackageName indicated by this PackagePath if known or available, or empty string if not | |
![]() ![]() |
FString | Returns the PackageName if available, otherwise the LocalPath | |
![]() ![]() |
TConstArrayView< EPackageExtension > | GetPossibleExtensions
(
EPackageSegment PackageSegment |
Report the EPackageExtensions this PackagePath should look for on disk |
![]() ![]() |
bool | HasLocalPath () |
Return true if and only if GetLocalBaseFilenameWithPath returns non-empty |
![]() ![]() |
bool | Return true if and only if GetPackageName returns non-empty | |
![]() ![]() |
bool | IsEmpty () |
Return whether this is a PackagePath with no path information and can never identify a package on disk |
![]() ![]() |
bool | Return whether a mount point has been found for this PackagePath | |
![]() ![]() |
EPackageExtension | ParseExtension
(
FStringView Filename, |
Parse the extension from a filepath and convert it to an EPackageExtension. |
![]() ![]() |
void | SetHeaderExtension
(
EPackageExtension Extension, |
Set the HeaderExtension to use, including a custom string if Extension is EPackageExtension::Custom |
![]() ![]() |
bool | TryFromMountedName
(
FStringView InPackageNameOrHeaderFilePath, |
Construct a PackagePath from a LocalPath or PackageName string, assuming the given LocalPath or PackageName is in a directory that is mounted (aka registered with FPackageName::MountPointExists) |
![]() ![]() |
bool | TryFromPackageName
(
FName InPackageName, |
|
![]() ![]() |
bool | TryFromPackageName
(
FStringView InPackageName, |
Attempt to construct a PackagePath from a LongPackageName StringView, FName, or TCHAR* |
![]() ![]() |
bool | TryFromPackageName
(
const TCHAR* InPackageName, |
|
![]() ![]() |
bool | TryMatchCase
(
const FPackagePath& SourcePackagePath, |
Set the capitalization of a PackagePath to match the given string |
Operators
Type | Name | Description | |
---|---|---|---|
![]() ![]() |
bool | operator!=
(
const FPackagePath& Other |
|
![]() |
FPackagePath & | operator=
(
const FPackagePath& Other |
|
![]() |
FPackagePath & | operator=
(
FPackagePath&& Other |
|
![]() ![]() |
bool | operator==
(
const FPackagePath& Other |
Comparsion operators. |
Enums
Type | Name | Description | |
---|---|---|---|
![]() |
EPackageIdType |