File indexing completed on 2024-12-22 05:36:50

0001 <?php
0002 /**
0003  * Zend Framework
0004  *
0005  * LICENSE
0006  *
0007  * This source file is subject to the new BSD license that is bundled
0008  * with this package in the file LICENSE.txt.
0009  * It is also available through the world-wide-web at this URL:
0010  * http://framework.zend.com/license/new-bsd
0011  * If you did not receive a copy of the license and are unable to
0012  * obtain it through the world-wide-web, please send an email
0013  * to license@zend.com so we can send you a copy immediately.
0014  *
0015  * @category   Zend
0016  * @package    Zend_Log
0017  * @subpackage Formatter
0018  * @copyright  Copyright (c) 2005-2015 Zend Technologies USA Inc. (http://www.zend.com)
0019  * @license    http://framework.zend.com/license/new-bsd     New BSD License
0020  * @version    $Id$
0021  */
0022 
0023 /** Zend_Log_Formatter_Abstract */
0024 // require_once 'Zend/Log/Formatter/Abstract.php';
0025 
0026 /**
0027  * @category   Zend
0028  * @package    Zend_Log
0029  * @subpackage Formatter
0030  * @copyright  Copyright (c) 2005-2015 Zend Technologies USA Inc. (http://www.zend.com)
0031  * @license    http://framework.zend.com/license/new-bsd     New BSD License
0032  */
0033 class Zend_Log_Formatter_Firebug extends Zend_Log_Formatter_Abstract
0034 {
0035     /**
0036    * Factory for Zend_Log_Formatter_Firebug classe
0037    *
0038      * @param array|Zend_Config $options useless
0039    * @return Zend_Log_Formatter_Firebug
0040      */
0041     public static function factory($options)
0042     {
0043         return new self;
0044     }
0045 
0046     /**
0047      * This method formats the event for the firebug writer.
0048      *
0049      * The default is to just send the message parameter, but through
0050      * extension of this class and calling the
0051      * {@see Zend_Log_Writer_Firebug::setFormatter()} method you can
0052      * pass as much of the event data as you are interested in.
0053      *
0054      * @param  array    $event    event data
0055      * @return mixed              event message
0056      */
0057     public function format($event)
0058     {
0059         return $event['message'];
0060     }
0061 }