Module EDLogging :: Class EDLogging
[hide private]
[frames] | no frames]

Class EDLogging

source code

       object --+    
                |    
EDObject.EDObject --+
                    |
                   EDLogging
Known Subclasses:

This class loads one of the EDNA loggers: EDLoggingVerbose, EDLoggingClass

Instance Methods [hide private]
 
__init__(self, _strLoggerName='EDVerbose')
Constructor of the main pure virtual class.
source code
 
setLogLevel(self, _logLevel) source code
 
setAllLogLevels(self, _logLevel) source code
 
setTestOn(self)
turn on the test mode: all assertions become verbose (->screen)
source code
 
setTestOff(self)
turn off the test mode: all assertions become silent (->screen)
source code
 
setVerboseOn(self)
This method turns on verbose logging to standard output (stdout)
source code
 
setVerboseOff(self)
This method turns off verbose logging to standard output (stdout)
source code
 
setVerboseDebugOn(self)
This method turns on debug messages to standard output and log file
source code
 
setVerboseDebugOff(self)
This method turns off debug messages to standard output and log file
source code
 
isVerboseDebug(self)
This method returns the current status of debugging
source code
 
log(self, _strMessage='')
This method writes a message only to the log file.
source code
 
screen(self, _strMessage='')
This method writes a message to standard output and to the log file.
source code
 
DEBUG(self, _strDebugMessage='')
This method writes a debug message to standard output and to the log file if debugging is enabled.
source code
 
unitTest(self, _strMessage='')
This method is meant to be used by the testing framework.
source code
 
ERROR(self, _strMessage='')
This method writes a message to standard error and the log file with the prefix [ERROR].
source code
 
error(self, _strMessage='')
This method writes a message to standard error and the log file with the prefix [ERROR].
source code
 
WARNING(self, _strMessage='')
This method writes a warning message to standard output and the log file with the prefix [Warning].
source code
 
warning(self, _strMessage='')
This method writes a warning message to standard output and the log file with the prefix [Warning].
source code
 
ASSERT(self, _strMessage)
This method writes an assert message to standard output and the log file with the prefix [ASSERT].
source code
 
writeErrorTrace(self, _strPrefix=' ')
This method writes an error trace to standard output and the log file.
source code
 
setLogFileName(self, _strLogFileName)
This method can be used for customising the file name of the log file.
source code
 
setLogFileOff(self)
This method truns off output to the log file.
source code

Inherited from EDObject.EDObject: getClassName, getId, getRunTime, getSemaphoreValue, getTimeEnd, getTimeInit, locked, setTimeEnd, setTimeInit, synchronizeOff, synchronizeOn

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __str__, __subclasshook__

Class Variables [hide private]
  _EDObject__iId_class = 1
Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

__init__(self, _strLoggerName='EDVerbose')
(Constructor)

source code 

Constructor of the main pure virtual class.
This constructor implements:
- the creation of the semaphore
- definition of timer object (uninitialized as potentially not used)

Overrides: object.__init__
(inherited documentation)

isVerboseDebug(self)

source code 

This method returns the current status of debugging

Returns:
if debug output to standard output and log file is enabled.

log(self, _strMessage='')

source code 

This method writes a message only to the log file.

Parameters:
  • _strMessage (python string) - The string to be written to the log file

screen(self, _strMessage='')

source code 

This method writes a message to standard output and to the log file.

Parameters:
  • _strMessage (python string) - The string to be written to the log file

DEBUG(self, _strDebugMessage='')

source code 

This method writes a debug message to standard output and to the log file if debugging is enabled. The message will be written with the prefix [DEBUG]

Parameters:
  • _strDebugMessage (python string) - The debug message to be written to standard output and log file

unitTest(self, _strMessage='')

source code 

This method is meant to be used by the testing framework. The message will be written to standard output and the log file with the prefix [UnitTest]

Parameters:
  • _strMessage (python string) - The message to be written to standard output and log file

ERROR(self, _strMessage='')

source code 

This method writes a message to standard error and the log file with the prefix [ERROR].

Parameters:
  • _strMessage (python string) - The error message to be written to standard output and log file

error(self, _strMessage='')

source code 

This method writes a message to standard error and the log file with the prefix [ERROR].

Parameters:
  • _strMessage (python string) - The error message to be written to standard output and log file

WARNING(self, _strMessage='')

source code 

This method writes a warning message to standard output and the log file with the prefix [Warning].

Parameters:
  • _strMessage (python string) - The error message to be written to standard output and log file

warning(self, _strMessage='')

source code 

This method writes a warning message to standard output and the log file with the prefix [Warning].

Parameters:
  • _strMessage (python string) - The error message to be written to standard output and log file

ASSERT(self, _strMessage)

source code 

This method writes an assert message to standard output and the log file with the prefix [ASSERT].

Parameters:
  • _strMessage (python string) - The error message to be written to standard output and log file

writeErrorTrace(self, _strPrefix=' ')

source code 

This method writes an error trace to standard output and the log file. The error trace has the same formatting as normal Python error traces.

Parameters:
  • _strPrefix (python string) - A prefix which can be customized, e.g. the testing framework uses ' [UnitTest]'

setLogFileName(self, _strLogFileName)

source code 

This method can be used for customising the file name of the log file.

Parameters:
  • _strLogFileName (python string) - A file name for the log file.