mewlo.mpacks.core.eventlog.mlogtarget_file module

logger_filetarget.py This module defines a derived logging hey class that implements file logging.

class mewlo.mpacks.core.eventlog.mlogtarget_file.MewloLogTarget_File(filename=None, filemode='a', logformatter=None)[source]

Bases: mewlo.mpacks.core.eventlog.mlogger.MewloLogTarget

MewloLogTarget_File - target that can write log lines to a file.

closefile_ifopen()[source]

Close the file if it’s already open.

get_nicelabel()[source]
get_openfile()[source]

Open the file if it’s not open. :return: the file reference so to use.

process(logmessage, flag_isfromqueue)[source]

Called by logger parent to actually do the work. We overide this in our subclass to do actual work.

set_fileinfo(filename, filemode)[source]

Set the filename we will open and write to on first write.

shutdown()[source]

Shutdown everything, we are about to exit.

write(logmessage, flag_isfromqueue)[source]

Write out the logmessage to the file.

Table Of Contents

Previous topic

mewlo.mpacks.core.eventlog.mlogtarget_database module

Next topic

mewlo.mpacks.core.eventlog.mlogtarget_python module

This Page