Differences between revisions 12 and 13
Revision 12 as of 2008-12-19 07:32:04
Size: 2086
Editor: KaiJaeger
Comment:
Revision 13 as of 2008-12-19 07:32:25
Size: 2084
Editor: KaiJaeger
Comment:
Deletions are marked like this. Additions are marked like this.
Line 3: Line 3:
{{{LogFiles}}} is part of the CategoryAplApl project. {{{Logger}}} is part of the CategoryAplApl project.

Managing Log Files

Logger is part of the CategoryAplApl project.

Overview

This class offers methods useful to write and manage ordinary ANSI log files. In case any non-ANSI chars are part of a message, these characters are replaced by question marks.

By default, the class creates a log file as an ordinary ANSI file with the name "yyyymmdd.txt". When a new day puts in an appearance, this file is closed and a new opened automatically.

Instead of accepting the defaults you can also let the class create "yyyymm.txt" files or even "yyyy.txt".

The main function, Log, creates entries as such:

20080721115636 *** Log File opened
20080721115636 (1) 127.0.0.1:2152 has connected

The number between the brackets (1) is the thread number. The number is not reported for thread number 0.

Note that the class makes intense use of error trapping to make sure that a problem in the Logger class will not effect the hosting application.

Constructors, Methods and Properties

Constructors:
  make1(active_)
  make2(active_ path_)
  make3(active_ path_ type_)
  make4(active_ path_ type_ debug_)
  make5(active_ path_ type_ debug_ refToWinFile_)
  make6(active_ path_ type_ debug_ refToWinFile_ refToUtils_)
  make7(active_ path_ type_ debug_ refToWinFile_ refToUtils_ timestamp_)
Instance Properties:
  active
  autoReOpen
  debug
  errorCounter (ReadOnly)
  errorPrefix
  extension
  filename (ReadOnly)
  filenameDescriptor (ReadOnly)
  filenamePostfix
  filenamePrefix
  filenameType
  path (ReadOnly)
  printToSession
  refToUtils
  refToWinFile
  timestamp
Instance Methods:
  Log
  LogError
Shared Methods:
  Version

History

For a full version history: History

Version Information

Original author:

KaiJaeger

Responsible:

KaiJaeger

Email:

kai@aplteam.com

Current state:

1.0.3

Download

Goto the DownloadPage


CategoryOpenSourceApl CategoryAplApl

Logger (last edited 2018-03-03 11:41:35 by KaiJaeger)