|
__init__(self,
active_flags=None,
log_file=sys.stderr,
prefix=' DEBUG: ' ,
sufix=' \n ' ,
time_stamp=0,
flag_show=None,
validate_flags=1,
welcome=-1) |
source code
|
|
|
show(self,
msg,
flag=None,
prefix=None,
sufix=None,
lf=0)
flag can be of folowing types:
None - this msg will always be shown if any debugging is on
flag - will be shown if flag is active
(flag1,flag2,,,) - will be shown if any of the given flags
are active |
source code
|
|
|
active_set(self,
active_flags=None)
returns 1 if any flags where actually set, otherwise 0. |
source code
|
|
|
active_get(self)
returns currently active flags. |
source code
|
|
|
|
|
_append_unique_str(self,
lst,
item)
filter out any dupes. |
source code
|
|
|
_validate_flag(self,
flags)
verify that flag is defined. |
source code
|
|
|
_remove_dupe_flags(self)
if multiple instances of Debug is used in same app, some flags might
be created multiple time, filter out dupes |
source code
|
|
|
|
|
|