Overview of global_settings.inc

Public Variable Summary

Public variables are intended to be accessed by the code that imports this library.

Name Summary
debug_level
log_verbosity
report_verbosity

Public Function Summary

Public functions are intended to be called by the code that imports this library.

Name Summary
debug_print
log_print

Public Variable Details

debug_level

top

log_verbosity

top

report_verbosity

top

Public Function Details

debug_print

Named Parameters

a0
a1
a2
a3
a4
a5
a6
a7
a8
a9
level

Code

function debug_print(level, a0, a1, a2, a3, a4, a5, a6, a7, a8, a9)
{
 local_var	msg, i, l;

 if (isnull(level)) level = 1;
 if (debug_level < level) return;
 msg = strcat(SCRIPT_NAME, '(', get_host_ip(), '): ');
 foreach i (_FCT_ANON_ARGS) { msg = string(msg, i); }
 l = strlen(msg);
 if (l == 0) return;
 if (msg[l-1] != '\n') msg += '\n';
 display("DEBUG: ", msg);
}

# a0 to a9 parameters are useless. They were added to suppress a warning

		
top

log_print

Named Parameters

a0
a1
a2
a3
a4
a5
a6
a7
a8
a9
level

Code

function log_print(level, a0, a1, a2, a3, a4, a5, a6, a7, a8, a9)
{
 local_var	msg, i, l;

 if (isnull(level)) level = 1;
 if (debug_level <= 0 || log_verbosity < level) return;
 msg = strcat(SCRIPT_NAME, '(', get_host_ip(), '): ');
 foreach i (_FCT_ANON_ARGS) { msg = string(msg, i); }
 l = strlen(msg);
 if (l == 0) return;
 if (msg[l-1] != '\n') msg += '\n';
 display("LOG: ", msg);
}

GLOBAL_SETTINGS_INC = 1;

		
top