DayZ 1.24
Loading...
Searching...
No Matches
EnumTools Class Reference

Private Member Functions

void EnumTools ()
 
void ~EnumTools ()
 

Static Private Member Functions

static string EnumToString (typename e, int enumValue)
 Return string name of enum value.
 
static int StringToEnum (typename e, string enumName)
 Return enum value from string name.
 
static int GetEnumSize (typename e)
 Return amount of values in enum.
 
static int GetEnumValue (typename e, int idx)
 Return the nth value in the enum.
 
static int GetLastEnumValue (typename e)
 Return amount of values in enum.
 

Detailed Description

Definition at line 586 of file EnConvert.c.

Constructor & Destructor Documentation

◆ EnumTools()

void EnumTools::EnumTools ( )
private

◆ ~EnumTools()

void EnumTools::~EnumTools ( )
private

Member Function Documentation

◆ EnumToString()

static string EnumTools::EnumToString ( typename e ,
int enumValue )
inlinestaticprivate

Return string name of enum value.

static string EnumToString(typename e, int enumValue)
Return string name of enum value.
Definition EnConvert.c:598
proto void Print(void var)
Prints content of variable to console/log.

Definition at line 598 of file EnConvert.c.

599 {
600 return typename.EnumToString(e, enumValue);
601 }

Referenced by Hud::Debug().

◆ GetEnumSize()

static int EnumTools::GetEnumSize ( typename e )
inlinestaticprivate

Return amount of values in enum.

static int GetEnumSize(typename e)
Return amount of values in enum.
Definition EnConvert.c:620

Definition at line 620 of file EnConvert.c.

621 {
622 return e.GetVariableCount();
623 }

Referenced by AnniversaryMusicSource(), UIScriptedMenu::DrawConnectingLines(), ContentDLC::OwnsAllDLC(), Hud::RefreshVehicleHud(), RemoteDetonatorTrigger::RemoteDetonatorTrigger(), and EnProfilerTests::TestSetFlags().

◆ GetEnumValue()

static int EnumTools::GetEnumValue ( typename e ,
int idx )
inlinestaticprivate

Return the nth value in the enum.

static int GetEnumValue(typename e, int idx)
Return the nth value in the enum.
Definition EnConvert.c:631

Definition at line 631 of file EnConvert.c.

632 {
633 int value;
634 e.GetVariableValue(null, idx, value);
635 return value;
636 }

Referenced by ContentDLC::OwnsAllDLC(), and EnProfilerTests::TestSetFlags().

◆ GetLastEnumValue()

static int EnumTools::GetLastEnumValue ( typename e )
inlinestaticprivate

Return amount of values in enum.

static int GetLastEnumValue(typename e)
Return amount of values in enum.
Definition EnConvert.c:644

Definition at line 644 of file EnConvert.c.

645 {
646 int lastValue;
647 e.GetVariableValue(null, e.GetVariableCount() - 1, lastValue);
648 return lastValue;
649 }

Referenced by FireworksLauncher::FireworksLauncher(), and Land_Underground_EntranceBase::Land_Underground_EntranceBase().

◆ StringToEnum()

static int EnumTools::StringToEnum ( typename e ,
string enumName )
inlinestaticprivate

Return enum value from string name.

static int StringToEnum(typename e, string enumName)
Return enum value from string name.
Definition EnConvert.c:609

Definition at line 609 of file EnConvert.c.

610 {
611 return typename.StringToEnum(e, enumName);
612 }

Referenced by EnProfilerTests::TestModule().


The documentation for this class was generated from the following file: