/Engine/Source/Runtime/CoreUObject/Public/Misc/PackageName.h
Tries to convert the supplied relative or absolute filename to a long package name/path starting with a root like /game This works on both package names and directories, and it does not validate that it actually exists on disk.
Returns true if the supplied filename properly maps to one of the long package roots.
static bool TryConvertFilenameToLongPackageName ( const [FString](API\Runtime\Core\Containers\FString) & InFilename, [FString](API\Runtime\Core\Containers\FString) & OutPackageName, [FString](API\Runtime\Core\Containers\FString) * OutFailureReason )