TYPO3  7.6
Public Member Functions | Public Attributes | Protected Member Functions | Protected Attributes | List of all members
HTTP_Request2_Observer_Log Class Reference
Inheritance diagram for HTTP_Request2_Observer_Log:

Public Member Functions

 __construct ($target= 'php://output', array $events=array())
 
 update (SplSubject $subject)
 

Public Attributes

 $events
 

Protected Member Functions

 log ($message)
 

Protected Attributes

 $target = null
 

Detailed Description

Definition at line 70 of file Log.php.

Constructor & Destructor Documentation

__construct (   $target = 'php://output',
array  $events = array() 
)

Constructor.

Parameters
mixed$targetCan be a file path (default: php://output), a resource, or an instance of the PEAR Log class.
array$eventsArray of events to listen to (default: all events)
Returns
void

Definition at line 107 of file Log.php.

References $events, $target, and elseif.

Member Function Documentation

log (   $message)
protected

Logs the given message to the configured target.

Parameters
string$messageMessage to display
Returns
void

Definition at line 180 of file Log.php.

References elseif.

Referenced by update().

update ( SplSubject  $subject)

Called when the request notifies us of an event.

Parameters
HTTP_Request2$subjectThe HTTP_Request2 instance
Returns
void

Definition at line 129 of file Log.php.

References log().

Member Data Documentation

array $events
Initial value:
= array(
'connect',
'sentHeaders',
'sentBody',
'receivedHeaders',
'receivedBody',
'disconnect',
)

The events to log.

Definition at line 86 of file Log.php.

Referenced by __construct().

resource Log $target = null
protected

The log target, it can be a a resource or a PEAR Log instance.

Definition at line 79 of file Log.php.

Referenced by __construct().