eZDebugSetting Class Reference

Conditional debug output. More...

List of all members.


Public Methods

 eZDebugSetting ()

Static Public Methods

 isConditionTrue ($conditionName,$messageType)
 changeLabel ($conditionName,$label)
 writeNotice ($conditionName,$string,$label="")
 writeWarning ($conditionName,$string,$label="")
 writeError ($conditionName,$string,$label="")
 writeDebug ($conditionName,$string,$label="")
 addTimingPoint ($conditionName,$label="")
 setDebugINI ($ini)

Detailed Description

Conditional debug output.

This works as a wrapper for the eZDebug class by checking some conditions defined in site.ini before writing the message. The condition must be true for the message to be written.

It will check the debug.ini file and first see if conditions are enabled globally by reading DebugSettings/ConditionDebug. If true if will then see if the condition exists in the GeneralCondition group, if so it will use it for condition check. If it doesn't exists generally it will check it specifically according to the message type for instance ErrorCondition, DebugCondition etc.

Example of debug.ini:

[DebugSettings]
ConditionDebug=enabled

[GeneralCondition]
my-flag=enabled
other-flag=disabled

[ErrorCondition]
bad-name-flag=disabled

Definition at line ezdebugsetting.php.


Constructor & Destructor Documentation

eZDebugSetting::eZDebugSetting  
 

Constructor

Definition at line ezdebugsetting.php.


Member Function Documentation

eZDebugSetting::addTimingPoint   conditionName,
  label = ""
[static]
 

Adds the timing point if the condition $conditionName is enabled.

Definition at line ezdebugsetting.php.

References isConditionTrue().

Referenced by eZURLTranslator::translateNodeTree().

eZDebugSetting::changeLabel   conditionName,
  label
[static]
 

Creates a new debug label from the original and the condition and returns it.

Definition at line ezdebugsetting.php.

Referenced by writeWarning().

eZDebugSetting::isConditionTrue   conditionName,
  messageType
[static]
 

Returns:
true if the condition $conditionName is considered enabled.

Definition at line ezdebugsetting.php.

References eZDebug::messageName().

Referenced by writeWarning().

eZDebugSetting::setDebugINI   ini [static]
 

Sets the INI object

Definition at line ezdebugsetting.php.

eZDebugSetting::writeDebug   conditionName,
  string,
  label = ""
[static]
 

Writes a debug message if the condition $conditionName is enabled.

Definition at line ezdebugsetting.php.

References eZDebug::writeDebug().

Referenced by eZContentObject::relatedContentObjectCount().

eZDebugSetting::writeError   conditionName,
  string,
  label = ""
[static]
 

Writes a debug error if the condition $conditionName is enabled.

Definition at line ezdebugsetting.php.

References eZDebug::writeError().

eZDebugSetting::writeNotice   conditionName,
  string,
  label = ""
[static]
 

Writes a debug notice if the condition $conditionName is enabled.

Definition at line ezdebugsetting.php.

References eZDebug::writeNotice().

eZDebugSetting::writeWarning   conditionName,
  string,
  label = ""
[static]
 

Writes a debug warning if the condition $conditionName is enabled.

Definition at line ezdebugsetting.php.

References eZDebug::writeWarning().


The documentation for this class was generated from the following file:  

Exponential