RealtimeStyleTransferRuntime/Plugins/GameSettings/Source/Public/DataSource/GameSettingDataSourceDynamic.h

32 lines
854 B
C
Raw Normal View History

2022-05-23 18:41:30 +00:00
// Copyright Epic Games, Inc. All Rights Reserved.
#pragma once
2022-09-13 07:18:28 +00:00
#include "Containers/Array.h"
#include "Containers/UnrealString.h"
2022-05-23 18:41:30 +00:00
#include "GameSettingDataSource.h"
#include "PropertyPathHelpers.h"
2022-09-13 07:18:28 +00:00
class ULocalPlayer;
2022-05-23 18:41:30 +00:00
//--------------------------------------
// FGameSettingDataSourceDynamic
//--------------------------------------
class GAMESETTINGS_API FGameSettingDataSourceDynamic : public FGameSettingDataSource
{
public:
FGameSettingDataSourceDynamic(const TArray<FString>& InDynamicPath);
virtual bool Resolve(ULocalPlayer* InLocalPlayer) override;
virtual FString GetValueAsString(ULocalPlayer* InLocalPlayer) const override;
virtual void SetValue(ULocalPlayer* InLocalPlayer, const FString& Value) override;
virtual FString ToString() const override;
private:
FCachedPropertyPath DynamicPath;
};