First code examples:
start, stop logging
open log file (if there is one)
open log folder
flag whether logging now
flag whether to log all post messages
flag whether tracing now - tracing means also post all log-ony messages
write a string directly to the log (if on)