Loading...
Searching...
No Matches
TOnlineSubsystemAccelByteConfigEntry< T > Class Template Reference

Represents a single configuration field for the AccelByte OSS. More...

#include <OnlineSubsystemAccelByteConfig.h>

Public Types

using FValidatorFunction = TFunction<bool(const T&)>

Public Member Functions

bool Load ()
 Load the given configuration entry from the configuration file. Will overwrite previously set value.
void SetValue (const T &InValue)
 Set value of this configuration entry to a copy of the given value.
void SetValue (T &&InValue)
 Set the value of this configuration by moving the given value.
bool SetValueFromString (const FString &InStringValue)
 Set the value of this configuration entry from the given string.
bool SetValueFromStringArray (const TArray< FString > &InStringArray)
 Set the value of this configuration entry from the given string array.
const T & GetValue () const
 Get the value stored in this configuration entry.
const T & GetDefaultValue () const
 Get the default value stored in this configuration entry.
const bool IsDefault () const
 Check whether this configuration entry is set to the default.
void Reset ()
 Reset the configuration entry to its default value.
void Init (TSharedRef< class FOnlineSubsystemAccelByteConfig, ESPMode::ThreadSafe > InConfig, const FString &InSection, const FString &InKey, const T &InDefaultValue, const FValidatorFunction &InValidator={})
 Initialize this configuration entry with all necessary values. Only should be called from the FOnlineSubsystemAccelByteConfig::Init method.
 TOnlineSubsystemAccelByteConfigEntry (const TOnlineSubsystemAccelByteConfigEntry &)=delete
 TOnlineSubsystemAccelByteConfigEntry (TOnlineSubsystemAccelByteConfigEntry &&)=delete
TOnlineSubsystemAccelByteConfigEntryoperator= (const TOnlineSubsystemAccelByteConfigEntry &)=delete
TOnlineSubsystemAccelByteConfigEntryoperator= (TOnlineSubsystemAccelByteConfigEntry &&)=delete

Public Attributes

PACKAGE_SCOPE : TOnlineSubsystemAccelByteConfigEntry() = default

Detailed Description

template<typename T>
class TOnlineSubsystemAccelByteConfigEntry< T >

Represents a single configuration field for the AccelByte OSS.

Member Function Documentation

◆ Load()

template<typename T>
bool TOnlineSubsystemAccelByteConfigEntry< T >::Load ( )
inline

Load the given configuration entry from the configuration file. Will overwrite previously set value.

Returns
bool that is true if the load was successful, false otherwise

◆ SetValue() [1/2]

template<typename T>
void TOnlineSubsystemAccelByteConfigEntry< T >::SetValue ( const T & InValue)
inline

Set value of this configuration entry to a copy of the given value.

Parameters
InValueValue to set the configuration to

◆ SetValue() [2/2]

template<typename T>
void TOnlineSubsystemAccelByteConfigEntry< T >::SetValue ( T && InValue)
inline

Set the value of this configuration by moving the given value.

Parameters
InValueValue to set the configuration to