UDocumentation UE5.7 10.02.2026 (Source)
API documentation for Unreal Engine 5.7
ProjectManager.h
Go to the documentation of this file.
1// Copyright Epic Games, Inc. All Rights Reserved.
2
3#pragma once
4
5#include "CoreMinimal.h"
7
9
13class FProjectManager final : public IProjectManager
14{
15public:
17
19 virtual const FProjectDescriptor *GetCurrentProject() const override;
20 virtual bool LoadProjectFile( const FString& ProjectFile ) override;
21 virtual bool LoadModulesForProject( const ELoadingPhase::Type LoadingPhase ) override;
22 virtual FLoadingModulesForPhaseEvent& OnLoadingPhaseComplete() override { return OnLoadingPhaseCompleteEvent; }
23 virtual bool SubstituteModule(const FString& OriginalModuleName, const FString& NewModuleName) override;
24#if !IS_MONOLITHIC
26#endif
27 virtual const FString& GetAutoLoadProjectFileName() override;
28 virtual bool SignSampleProject(const FString& FilePath, const FString& Category, FText& OutFailReason) override;
29 virtual bool QueryStatusForProject(const FString& FilePath, FProjectStatus& OutProjectStatus) const override;
31 virtual void UpdateSupportedTargetPlatformsForProject(const FString& FilePath, const FName& InPlatformName, const bool bIsSupported) override;
32 virtual void UpdateSupportedTargetPlatformsForCurrentProject(const FName& InPlatformName, const bool bIsSupported) override;
33 virtual void ClearSupportedTargetPlatformsForProject(const FString& FilePath) override;
35 virtual FOnTargetPlatformsForCurrentProjectChangedEvent& OnTargetPlatformsForCurrentProjectChanged() override { return OnTargetPlatformsForCurrentProjectChangedEvent; }
36 virtual bool HasDefaultPluginSettings() const override;
37 virtual bool SetPluginEnabled(const FString& PluginName, bool bEnabled, FText& OutFailReason) override;
38 virtual bool RemovePluginReference(const FString& PluginName, FText& OutFailReason) override;
39 virtual bool UpdateAdditionalPluginDirectory(const FString& Dir, const bool bAddOrRemove) override;
40 virtual const TArray<FString>& GetAdditionalPluginDirectories() const override;
41 virtual bool IsCurrentProjectDirty() const override;
42 virtual bool SaveCurrentProjectToDisk(FText& OutFailReason) override;
43 virtual bool IsEnterpriseProject() override;
44 virtual void SetIsEnterpriseProject(bool bValue) override;
46 virtual bool IsSuppressingProjectFileWrite() const override;
47 virtual void AddSuppressProjectFileWrite(const FName InName) override;
48 virtual void RemoveSuppressProjectFileWrite(const FName InName) override;
49
50private:
51 static void QueryStatusForProjectImpl(const FProjectDescriptor& Project, const FString& FilePath, FProjectStatus& OutProjectStatus);
52
54 static void GetDefaultEnabledPlugins(TArray<FString>& PluginNames, bool bIncludeInstalledPlugins, bool bAllowEnginePluginsEnabledByDefault);
55
58
60 TArray<FModuleContextInfo> CurrentProjectModuleContextInfos;
61
63 bool bIsCurrentProjectDirty;
64
66 FOnTargetPlatformsForCurrentProjectChangedEvent OnTargetPlatformsForCurrentProjectChangedEvent;
67
69 FLoadingModulesForPhaseEvent OnLoadingPhaseCompleteEvent;
70
72 TArray<FName> SuppressProjectFileWriteList;
73};
74
75
UE_FORCEINLINE_HINT TSharedRef< CastToType, Mode > StaticCastSharedRef(TSharedRef< CastFromType, Mode > const &InSharedRef)
Definition SharedPointer.h:127
Definition NameTypes.h:617
Definition ProjectManager.h:14
virtual FOnTargetPlatformsForCurrentProjectChangedEvent & OnTargetPlatformsForCurrentProjectChanged() override
Definition ProjectManager.h:35
virtual bool SaveCurrentProjectToDisk(FText &OutFailReason) override
Definition ProjectManager.cpp:487
virtual const TArray< FString > & GetAdditionalPluginDirectories() const override
Definition ProjectManager.cpp:472
virtual bool RemovePluginReference(const FString &PluginName, FText &OutFailReason) override
Definition ProjectManager.cpp:408
virtual void ClearSupportedTargetPlatformsForProject(const FString &FilePath) override
Definition ProjectManager.cpp:234
virtual void AddSuppressProjectFileWrite(const FName InName) override
Definition ProjectManager.cpp:526
virtual FLoadingModulesForPhaseEvent & OnLoadingPhaseComplete() override
Definition ProjectManager.h:22
virtual bool SubstituteModule(const FString &OriginalModuleName, const FString &NewModuleName) override
Definition ProjectManager.cpp:109
virtual const FProjectDescriptor * GetCurrentProject() const override
Definition ProjectManager.cpp:23
virtual void SetIsEnterpriseProject(bool bValue) override
Definition ProjectManager.cpp:508
virtual void RemoveSuppressProjectFileWrite(const FName InName) override
Definition ProjectManager.cpp:531
virtual bool QueryStatusForCurrentProject(FProjectStatus &OutProjectStatus) const override
Definition ProjectManager.cpp:167
FProjectManager()
Definition ProjectManager.cpp:18
virtual bool CheckModuleCompatibility(TArray< FString > &OutIncompatibleModules) override
Definition ProjectManager.cpp:129
virtual bool SetPluginEnabled(const FString &PluginName, bool bEnabled, FText &OutFailReason) override
Definition ProjectManager.cpp:317
virtual void ClearSupportedTargetPlatformsForCurrentProject() override
Definition ProjectManager.cpp:256
virtual bool LoadProjectFile(const FString &ProjectFile) override
Definition ProjectManager.cpp:28
virtual bool SignSampleProject(const FString &FilePath, const FString &Category, FText &OutFailReason) override
Definition ProjectManager.cpp:141
virtual bool LoadModulesForProject(const ELoadingPhase::Type LoadingPhase) override
Definition ProjectManager.cpp:51
virtual bool IsEnterpriseProject() override
Definition ProjectManager.cpp:497
virtual bool IsSuppressingProjectFileWrite() const override
Definition ProjectManager.cpp:521
virtual void UpdateSupportedTargetPlatformsForProject(const FString &FilePath, const FName &InPlatformName, const bool bIsSupported) override
Definition ProjectManager.cpp:189
virtual void UpdateSupportedTargetPlatformsForCurrentProject(const FName &InPlatformName, const bool bIsSupported) override
Definition ProjectManager.cpp:219
virtual bool HasDefaultPluginSettings() const override
Definition ProjectManager.cpp:312
virtual const FString & GetAutoLoadProjectFileName() override
Definition ProjectManager.cpp:135
virtual bool IsCurrentProjectDirty() const override
Definition ProjectManager.cpp:482
virtual bool QueryStatusForProject(const FString &FilePath, FProjectStatus &OutProjectStatus) const override
Definition ProjectManager.cpp:154
virtual TArray< FModuleContextInfo > & GetCurrentProjectModuleContextInfos() override
Definition ProjectManager.cpp:516
virtual bool UpdateAdditionalPluginDirectory(const FString &Dir, const bool bAddOrRemove) override
Definition ProjectManager.cpp:445
Definition IProjectManager.h:15
Definition Text.h:385
Definition IProjectManager.h:71
Definition Array.h:670
Type
Definition ModuleDescriptor.h:27
Definition ProjectDescriptor.h:43