FPackageName::IsValidLongPackageName

Returns true if the path starts with a valid root (i.e. /Game/, /Engine/, etc) and contains no illegal characters.

Windows
MacOS
Linux

References

Module

CoreUObject

Header

/Engine/Source/Runtime/CoreUObject/Public/Misc/PackageName.h

Include

#include "Misc/PackageName.h"

Source

/Engine/Source/Runtime/CoreUObject/Private/Misc/PackageName.cpp

Syntax

static bool IsValidLongPackageName
(
    const FString & InLongPackageName,
    bool bIncludeReadOnlyRoots,
    FText * OutReason
)

Remarks

Returns true if the path starts with a valid root (i.e. /Game/, /Engine/, etc) and contains no illegal characters.

Returns

true if a valid long package name

Parameters

Parameter

Description

InLongPackageName

The package name to test

bIncludeReadOnlyRoots

If true, will include roots that you should not save to. (/Temp/, /Script/)

OutReason

When returning false, this will provide a description of what was wrong with the name.

Help shape the future of Unreal Engine documentation! Tell us how we're doing so we can serve you better.
Take our survey
Dismiss