Plop
A simple logging library for PHP
Plop\Handler\RotatingAbstract Class Reference

An abstract class for handlers that must deal with file rotations. More...

+ Inheritance diagram for Plop\Handler\RotatingAbstract:

Protected Member Functions

 doRollover ()
 
 emit (\Plop\RecordInterface $record)
 
 shouldRollover (\Plop\RecordInterface $record)
 
- Protected Member Functions inherited from Plop\Handler\File
 close ()
 
 emit (\Plop\RecordInterface $record)
 
 open ()
 
- Protected Member Functions inherited from Plop\Handler\Stream
 emit (\Plop\RecordInterface $record)
 
 flush ()
 
- Protected Member Functions inherited from Plop\HandlerAbstract
 emit (\Plop\RecordInterface $record)
 
 format (\Plop\RecordInterface $record)
 
 getStderr ()
 

Additional Inherited Members

- Public Member Functions inherited from Plop\Handler\File
 __construct ($filename, $mode= 'at', $delay=false)
 
 __destruct ()
 Free the resources used by this handler.
 
- Public Member Functions inherited from Plop\Handler\Stream
 __construct ($stream=null)
 
- Public Member Functions inherited from Plop\HandlerAbstract
 __construct (\Plop\FormatterInterface $formatter=null,\Plop\FiltersCollectionAbstract $filters=null)
 
 getFilters ()
 
 getFormatter ()
 
 handle (\Plop\RecordInterface $record)
 
 handleError (\Plop\RecordInterface $record,\Exception $exception)
 
 setFilters (\Plop\FiltersCollectionAbstract $filters)
 
 setFormatter (\Plop\FormatterInterface $formatter)
 
- Protected Attributes inherited from Plop\Handler\File
 $baseFilename
 Path to the log file this handler writes to.
 
 $mode
 Opening mode for the log file.
 
- Protected Attributes inherited from Plop\Handler\Stream
 $stream
 The stream where log messages will be write to.
 
- Protected Attributes inherited from Plop\HandlerAbstract
 $filters
 An object handling a collection of filters.
 
 $formatter
 Formatter object to use for this handler.
 
- Static Protected Attributes inherited from Plop\Handler\Stream
static $stderr = null
 A stream referencing STDERR.
 

Detailed Description

An abstract class for handlers that must deal with file rotations.

Definition at line 28 of file RotatingAbstract.php.

Member Function Documentation

Plop\Handler\RotatingAbstract::doRollover ( )
abstractprotected

Do the actual file rotation.

Returns
This method does not return any value.

Referenced by Plop\Handler\RotatingAbstract\emit().

Plop\Handler\RotatingAbstract::emit ( \Plop\RecordInterface  $record)
protected
Plop\Handler\RotatingAbstract::shouldRollover ( \Plop\RecordInterface  $record)
abstractprotected

Decide whether a file rotation is necessary.

Parameters
Plop::RecordInterface$recordThe log record being handled.
Return values
booltrue if a file rotation is required, false otherwise.

Referenced by Plop\Handler\RotatingAbstract\emit().


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