UDocumentation UE5.7 10.02.2026 (Source)
API documentation for Unreal Engine 5.7
VerseScope.h
Go to the documentation of this file.
1// Copyright Epic Games, Inc. All Rights Reserved.
2#pragma once
3
7
8namespace uLang
9{
10
11// Describes the origin and visibility of Verse code
12// This mirrors EVerseScope in VerseScope.h in the Projects module.
13enum class EVerseScope : uint8_t
14{
15 PublicAPI, // Created by Epic and only public definitions will be visible to public users
16 InternalAPI, // Created by Epic and is entirely hidden from public users
17 PublicUser, // Created by a public user
18 InternalUser, // Created by an Epic internal user
19};
20
21static inline bool IsPublicScope(EVerseScope VerseScope)
22{
23 switch (VerseScope)
24 {
26 case EVerseScope::PublicUser: return true;
28 case EVerseScope::InternalUser: return false;
29 default: ULANG_UNREACHABLE();
30 }
31}
32
33static inline const char* ToString(EVerseScope VerseScope)
34{
35 switch (VerseScope)
36 {
37 case EVerseScope::PublicAPI: return "PublicAPI";
38 case EVerseScope::InternalAPI: return "InternalAPI";
39 case EVerseScope::PublicUser: return "PublicUser";
40 case EVerseScope::InternalUser: return "InternalUser";
41 default: ULANG_UNREACHABLE();
42 }
43}
44
45static inline TOptional<EVerseScope> ToVerseScope(const CUTF8StringView& String)
46{
47 if (String == "PublicAPI")
48 {
49 return { EVerseScope::PublicAPI };
50 }
51 else if (String == "InternalAPI")
52 {
53 return { EVerseScope::InternalAPI };
54 }
55 else if (String == "PublicUser")
56 {
57 return { EVerseScope::PublicUser };
58 }
59 else if (String == "InternalUser")
60 {
62 }
63 else
64 {
65 return {};
66 }
67}
68
69}
UE_FORCEINLINE_HINT TSharedRef< CastToType, Mode > StaticCastSharedRef(TSharedRef< CastFromType, Mode > const &InSharedRef)
Definition SharedPointer.h:127
#define ULANG_UNREACHABLE()
Definition Common.h:243
Definition VerseScope.h:13
FString ToString(uint16 Value)
Definition PathFollowingComponent.cpp:82
Definition VVMEngineEnvironment.h:23
EVerseScope
Definition VerseScope.h:14
Definition Optional.h:131