DayZ 1.24
Loading...
Searching...
No Matches
LogTemplates Class Reference
Collaboration diagram for LogTemplates:
[legend]

Static Private Member Functions

void RegisterLogTamplate (LogTemplateID template_id, string author, string plugin, string label)
 
static void Init ()
 
static LogTemplate GetTemplate (LogTemplateID template_id)
 

Static Private Attributes

ref map< LogTemplateID, ref LogTemplatem_LogTemplates
 
static LogTemplateID TEMPLATE_UNKNOWN = 0
 
static LogTemplateID TEMPLATE_JANOSIK = 1
 
static LogTemplateID TEMPLATE_PLAYER_WEIGHT = 2
 
static LogTemplateID TEMPLATE_BROADCAST = 3
 

Detailed Description

Definition at line 7 of file LogTemplates.c.

Member Function Documentation

◆ GetTemplate()

static LogTemplate LogTemplates::GetTemplate ( LogTemplateID template_id)
inlinestaticprivate

Definition at line 48 of file LogTemplates.c.

49 {
51 return m_LogTemplates.Get(template_id);
52
53 Debug.Log("Template ID: " + string.ToString(template_id) + " does not exist!", "LogTemplate.h -> GetTemplate()", "System", "Get Log Template", "None");
54 return NULL;
55 }
proto string ToString()
Definition Debug.c:14
static void Log(string message=LOG_DEFAULT, string plugin=LOG_DEFAULT, string author=LOG_DEFAULT, string label=LOG_DEFAULT, string entity=LOG_DEFAULT)
Prints debug message with normal prio.
Definition Debug.c:133
ref map< LogTemplateID, ref LogTemplate > m_LogTemplates
Definition LogTemplates.c:9

References Debug::Log(), m_LogTemplates, and ToString().

Referenced by LogError(), LogInfo(), and LogWarning().

◆ Init()

static void LogTemplates::Init ( )
inlinestaticprivate

Definition at line 36 of file LogTemplates.c.

37 {
40 // | Template Name | author | plugin | label ////
41 RegisterLogTamplate(TEMPLATE_UNKNOWN, "Unknown", "Unknown", "Unknown"); //
42 RegisterLogTamplate(TEMPLATE_JANOSIK, "Janosik", "GUI", "None"); //
43 RegisterLogTamplate(TEMPLATE_PLAYER_WEIGHT, "Unknown", "PlayerBase", "Weight"); //
44 RegisterLogTamplate(TEMPLATE_BROADCAST, "Unknown", "PluginMessageManager", "Broadcast"); //
45
46 }
static LogTemplateID TEMPLATE_BROADCAST
static LogTemplateID TEMPLATE_UNKNOWN
static LogTemplateID TEMPLATE_JANOSIK
static LogTemplateID TEMPLATE_PLAYER_WEIGHT
void RegisterLogTamplate(LogTemplateID template_id, string author, string plugin, string label)

References RegisterLogTamplate(), TEMPLATE_BROADCAST, TEMPLATE_JANOSIK, TEMPLATE_PLAYER_WEIGHT, and TEMPLATE_UNKNOWN.

◆ RegisterLogTamplate()

void LogTemplates::RegisterLogTamplate ( LogTemplateID template_id,
string author,
string plugin,
string label )
inlinestaticprivate

Definition at line 11 of file LogTemplates.c.

12 {
13 if (m_LogTemplates == NULL)
15
16 if (m_LogTemplates.Contains(template_id))
17 Debug.Log("Template ID: " + string.ToString(template_id) + " is alredy exist!", "LogTemplate.h -> OnInit()", "System", "Template Registration", "None");
18 else
19 {
22 }
23 }
Param3< string, string, string > LogTemplate
Definition LogTemplates.c:1

References Debug::Log(), m_LogTemplates, and ToString().

Referenced by Init().

Member Data Documentation

◆ m_LogTemplates

ref map<LogTemplateID, ref LogTemplate> LogTemplates::m_LogTemplates
staticprivate

Definition at line 9 of file LogTemplates.c.

Referenced by GetTemplate(), and RegisterLogTamplate().

◆ TEMPLATE_BROADCAST

LogTemplateID LogTemplates::TEMPLATE_BROADCAST = 3
staticprivate

Definition at line 34 of file LogTemplates.c.

Referenced by Init().

◆ TEMPLATE_JANOSIK

LogTemplateID LogTemplates::TEMPLATE_JANOSIK = 1
staticprivate

Definition at line 32 of file LogTemplates.c.

Referenced by Init().

◆ TEMPLATE_PLAYER_WEIGHT

LogTemplateID LogTemplates::TEMPLATE_PLAYER_WEIGHT = 2
staticprivate

Definition at line 33 of file LogTemplates.c.

Referenced by Init().

◆ TEMPLATE_UNKNOWN

LogTemplateID LogTemplates::TEMPLATE_UNKNOWN = 0
staticprivate

Definition at line 31 of file LogTemplates.c.

Referenced by Init().


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