Hog v9.61.0
Logger.tcl File Reference

Go to the source code of this file.

Namespaces

 Hog::LoggerLib
 

Functions

 setDebugMode mode
 
 getDebugMode
 
 printDebugMode
 
 dictSafeGet d args
 Safely get a value from a dictionary. More...
 
 Msg level fmsg ?title?
 The Hog Printout Msg function. More...
 
 MsgAndLog msg ?severity? ?outFile?
 Prints a message with selected severity and optionally write into a log file. More...
 
 Logo ?repo_path?
 
 PrintFileContent filename
 
 PrintFileTree data repo_path ?indentation?
 
 Hog::LoggerLib::GetUserFilePath filename
 gets the full path to the file in the user home folder More...
 
 Hog::LoggerLib::ParseTOML toml_file
 Parse a TOML format file and return the data as a dictionary. More...
 
 Hog::LoggerLib::ParseTOMLValue value
 Parse a TOML value and convert it to appropriate TCL type. More...
 
 Hog::LoggerLib::GetTOMLValue toml_dict key_path
 Get a value from a TOML dictionary using dot notation. More...
 
 Hog::LoggerLib::PrintTOMLDict toml_dict ?indent?
 Print a TOML dictionary in a readable format. More...
 
 Hog::LoggerLib::GetTOMLDict
 Access the dictionary of the parsed TOML file. More...
 

Function Documentation

◆ dictSafeGet()

dictSafeGet   d args  

Safely get a value from a dictionary.

Parameters
[in]dThe dictionary to search
[in]argsThe keys to look for

Definition at line 44 of file Logger.tcl.

◆ getDebugMode()

getDebugMode

Definition at line 26 of file Logger.tcl.

◆ Logo()

Logo   ?repo_path?  

Definition at line 160 of file Logger.tcl.

◆ Msg()

Msg   level fmsg ?title?  

The Hog Printout Msg function.

Parameters
[in]levelThe severity level (status, info, warning, critical, error, debug)
[in]msgThe message to print
[in]titleThe title string to be included in the header of the message [Hog:$title] (default "")

Definition at line 57 of file Logger.tcl.

◆ MsgAndLog()

MsgAndLog   msg ?severity? ?outFile?  

Prints a message with selected severity and optionally write into a log file.

Parameters
[in]msgThe message to print
[in]severityThe severity of the message
[in]outFileThe path of the output logfile

Definition at line 141 of file Logger.tcl.

◆ printDebugMode()

printDebugMode

Definition at line 31 of file Logger.tcl.

◆ PrintFileContent()

PrintFileContent   filename  

Definition at line 207 of file Logger.tcl.

◆ PrintFileTree()

PrintFileTree   data repo_path ?indentation?  

Print a tree-like structure of Hog list file content

Parameters
[in]datathe list of lines read from a list file
[in]repo_paththe path of the repository
[in]indentationa string containing a number of spaces to indent the tree

Definition at line 228 of file Logger.tcl.

◆ setDebugMode()

setDebugMode   mode  

Definition at line 21 of file Logger.tcl.